~kris/9p

9hist

143fdcf5e2418b2ce78274c21082e0898af2e524 — David du Colombier 24 years ago 7b1dbfc
Plan 9 from Bell Labs 2002-04-24
3 files changed, 10 insertions(+), 7 deletions(-)

M bitsy/l.s
M bitsy/power.c
M ip/ip.c
M bitsy/l.s => bitsy/l.s +4 -4
@@ 688,8 688,8 @@ TEXT power_down(SB), $-4
	MOVW	R2,0x10(R3)
	MOVW	$0,R2
	MOVW	R2,0x18(R3)
/*	MOVW	$power_resume+0(SB),R2	*/
	MOVW	$0,R2
	MOVW	$power_resume+0(SB),R2
/*	MOVW	$0,R2	*/
	MOVW	R2,0x8(R3)
	MOVW	$0,R2
	MOVW	R2,0x4(R6)


@@ 726,9 726,9 @@ l14:	SUB		$1,R0

	MOVW	$1,R2
	MOVW	R4,0x1c(R3)
//	MOVW	R6,0x1c(R3)
	MOVW	R6,0x1c(R3)
	MOVW	R12,0x0(R3)
//	MOVW	R11,0x1c(R3)
	MOVW	R11,0x1c(R3)
	MOVW	R2,0x0(R5)

slloop:

M bitsy/power.c => bitsy/power.c +3 -3
@@ 173,7 173,7 @@ deepsleep(void) {
	screenpower(0);
	µcpower(0);
	iprint("entering suspend mode, sp = 0x%lux, pc = 0x%lux, psw = 0x%ux\n", &xsp, xlink, power_pl);
//	dumpitall();
	dumpitall();
	delay(1000);
	uartpower(0);
	rs232power(0);


@@ 206,10 206,10 @@ deepsleep(void) {
		delay(100);
		xlink = getcallerpc(&xlink);
		iprint("\nresuming execution, sp = 0x%lux, pc = 0x%lux, psw = 0x%ux\n", &xsp, xlink, splhi());
//		dumpitall();
		dumpitall();
		delay(1000);
//		irpower(1);
//		audiopower(1);
		audiopower(1);
		µcpower(1);
		screenpower(1);
		splx(power_pl);

M ip/ip.c => ip/ip.c +3 -0
@@ 354,6 354,7 @@ ipiput(Fs *f, Ipifc *ifc, Block *bp)
	uchar *dp, v6dst[IPaddrlen];
	IP *ip;
	Route *r, *sr;
	int olen;

	ip = f->ip;
	ip->stats[InReceives]++;


@@ 401,11 402,13 @@ ipiput(Fs *f, Ipifc *ifc, Block *bp)
		}
		/* If this is not routed strip off the options */
		if(notforme == 0) {
			olen = nhgets(h->length);
			dp = bp->rp + (hl - (IP_HLEN<<2));
			memmove(dp, h, IP_HLEN<<2);
			bp->rp = dp;
			h = (Iphdr *)(bp->rp);
			h->vihl = (IP_VER|IP_HLEN);
			hnputs(h->length, olen-hl+(IP_HLEN<<2));
		}
	}