~kris/9p

9hist

e01e998d17f5ce59528429d44b50119f99e03288 — David du Colombier 33 years ago 045493b
Plan 9 from Bell Labs 1992-11-21
3 files changed, 9 insertions(+), 9 deletions(-)

M pc/devvga.c
M pc/l.s
M pc/main.c
M pc/devvga.c => pc/devvga.c +6 -4
@@ 647,20 647,21 @@ vgaupdate(void)

	switch(gscreen.ldepth){
	case 0:
		r.min.x &= ~15;		/* 16 bit allignment for l0update() */
		r.min.x &= ~15;		/* 16 pixel allignment for l0update() */
		f = l0update;
		len = (r.max.x + 7)/8 - r.min.x/8;
		if(len & 1)
			len++;		/* 16 bit allignment for l0update() */
		break;
	case 1:
		r.min.x &= ~15;		/* 16 bit allignment for l1update() */
		r.min.x &= ~15;		/* 8 pixel allignment for l1update() */
		f = l1update;
		len = (r.max.x + 7)/8 - r.min.x/8;
		if(len & 1)
			len++;		/* 16 bit allignment for l1update() */
			len++;		/* 8 pixel allignment for l1update() */
		break;
	case 2:
		r.min.x &= ~7;		/* 8 pixel allignment for l2update() */
		f = l2update;
		len = (r.max.x + 7)/8 - r.min.x/8;
		break;


@@ 678,7 679,8 @@ vgaupdate(void)
	page = off>>16;
	off &= (1<<16)-1;
	hp = ((uchar*)vgascreen.base) + off;
	off = r.min.y * gscreen.width * BY2WD + (r.min.x>>(3 - gscreen.ldepth));
	off = r.min.y * gscreen.width * BY2WD
		+ (r.min.x>>(3 - gscreen.ldepth));
	sp = ((uchar*)gscreen.base) + off;

	edisp = ((uchar*)vgascreen.base) + 64*1024;

M pc/l.s => pc/l.s +1 -3
@@ 696,9 696,7 @@ l10:
	MOVB	$0xA,AL
	OUTB
	MOVW	BX,-2(DI)(CX*1)
	LOOP	l11
	RET
l11:	LOOP	l10
	LOOP	l10
	RET

/*

M pc/main.c => pc/main.c +2 -2
@@ 275,8 275,8 @@ confinit(void)
	pcnt = (1<<conf.ldepth)-1;		/* Calculate % of memory for page pool */
	pcnt = 70 - (pcnt*10);
	conf.upages = (conf.npage*pcnt)/100;
	if(conf.npage - conf.upages < 1572864/BY2PG)
		conf.upages = conf.npage - 1572864/BY2PG;
	if(conf.npage - conf.upages < (2*MB)/BY2PG)
		conf.upages = conf.npage - (2*MB)/BY2PG;

	ktop = PGROUND((ulong)end);
	ktop = PADDR(ktop);