~kris/9p

9hist

b1913c0415eac25f689bc927096c754744c2a517 — David du Colombier 32 years ago 1a7f3cb
Plan 9 from Bell Labs 1994-05-21
5 files changed, 22 insertions(+), 41 deletions(-)

M carrera/screen.c
M pc/devvga.c
M pc/fault386.c
M pc/main.c
M port/devmouse.c
M carrera/screen.c => carrera/screen.c +0 -19
@@ 76,26 76,9 @@ Bitmap bgrnd =
	0
};

Cursor fatarrow = {
	{ -1, -1 },
	{
		0xff, 0xff, 0x80, 0x01, 0x80, 0x02, 0x80, 0x0c, 
		0x80, 0x10, 0x80, 0x10, 0x80, 0x08, 0x80, 0x04, 
		0x80, 0x02, 0x80, 0x01, 0x80, 0x02, 0x8c, 0x04, 
		0x92, 0x08, 0x91, 0x10, 0xa0, 0xa0, 0xc0, 0x40, 
	},
	{
		0x00, 0x00, 0x7f, 0xfe, 0x7f, 0xfc, 0x7f, 0xf0, 
		0x7f, 0xe0, 0x7f, 0xe0, 0x7f, 0xf0, 0x7f, 0xf8, 
		0x7f, 0xfc, 0x7f, 0xfe, 0x7f, 0xfc, 0x73, 0xf8, 
		0x61, 0xf0, 0x60, 0xe0, 0x40, 0x40, 0x00, 0x00, 
	},
};

static Rectangle window;
static Point curpos;
static int h, w;
extern Cursor arrow;

void
screenwin(void)


@@ 221,8 204,6 @@ screeninit(void)

	dacinit();

	memmove(&arrow, &fatarrow, sizeof(fatarrow));

	bitblt(&gscreen, Pt(0, 0), &gscreen, gscreen.r, 0);
	out.pos.x = MINX;
	out.pos.y = 0;

M pc/devvga.c => pc/devvga.c +5 -7
@@ 1268,7 1268,9 @@ setcolor(ulong p, ulong r, ulong g, ulong b)
/*
 *  area to store the bits that are behind the cursor
 */
ulong backbits[16*4];
static ulong backbits[16*4];
static ulong clrbits[16];
static ulong setbits[16];

/*
 *  the white border around the cursor


@@ 1278,7 1280,7 @@ Bitmap	clr =
	{0, 0, 16, 16},
	{0, 0, 16, 16},
	0,
	0,
	clrbits,
	0,
	1,
};


@@ 1291,7 1293,7 @@ Bitmap	set =
	{0, 0, 16, 16},
	{0, 0, 16, 16},
	0,
	0,
	setbits,
	0,
	1,
};


@@ 1307,10 1309,6 @@ cursorinit(void)
	cursor.l = cursorwork.width*BY2WD;

	if(!already){
		set.base = malloc(16*sizeof(ulong));
		clr.base = malloc(16*sizeof(ulong));
		if(set.base == 0 || clr.base == 0)
			panic("cursorinit");
		cursor.disable--;
		already = 1;
	}

M pc/fault386.c => pc/fault386.c +5 -2
@@ 18,13 18,17 @@ fault386(Ureg *ur, void *arg)

	USED(arg);

	if(up == 0){
		dumpregs(ur);
		for(;;);
	}

	insyscall = up->insyscall;
	up->insyscall = 1;
	addr = getcr2();
	read = !(ur->ecode & 2);
	user = (ur->cs&0xffff) == UESEL;
	spllo();
/*print("F%d:A#%lux:U%d:R%d|", up->pid, addr, user, read);/**/
	n = fault(addr, read);
	if(n < 0){
		if(user){


@@ 33,7 37,6 @@ fault386(Ureg *ur, void *arg)
			postnote(up, 1, buf, NDebug);
			return;
		}
print("fault: 0x%lux", addr);
		dumpregs(ur);
		panic("fault: 0x%lux", addr);
	}

M pc/main.c => pc/main.c +1 -1
@@ 67,7 67,7 @@ main(void)

/*
 *  This tries to capture architecture dependencies since things
 *  like power management/reseting/mouse are outside the hardware
 *  like power management/resetting/mouse are outside the hardware
 *  model.
 */
void

M port/devmouse.c => port/devmouse.c +11 -12
@@ 36,19 36,18 @@ int		mousetype;
int		mouseswap;
Cursor		curs;

Cursor	arrow =
{
	{-1, -1},
	{0xFF, 0xE0, 0xFF, 0xE0, 0xFF, 0xC0, 0xFF, 0x00,
	 0xFF, 0x00, 0xFF, 0x80, 0xFF, 0xC0, 0xFF, 0xE0,
	 0xE7, 0xF0, 0xE3, 0xF8, 0xC1, 0xFC, 0x00, 0xFE,
	 0x00, 0x7F, 0x00, 0x3E, 0x00, 0x1C, 0x00, 0x08,
Cursor	arrow = {
	{ -1, -1 },
	{ 0xFF, 0xFF, 0x80, 0x01, 0x80, 0x02, 0x80, 0x0C, 
	  0x80, 0x10, 0x80, 0x10, 0x80, 0x08, 0x80, 0x04, 
	  0x80, 0x02, 0x80, 0x01, 0x80, 0x02, 0x8C, 0x04, 
	  0x92, 0x08, 0x91, 0x10, 0xA0, 0xA0, 0xC0, 0x40, 
	},
	{ 0x00, 0x00, 0x7F, 0xFE, 0x7F, 0xFC, 0x7F, 0xF0, 
	  0x7F, 0xE0, 0x7F, 0xE0, 0x7F, 0xF0, 0x7F, 0xF8, 
	  0x7F, 0xFC, 0x7F, 0xFE, 0x7F, 0xFC, 0x73, 0xF8, 
	  0x61, 0xF0, 0x60, 0xE0, 0x40, 0x40, 0x00, 0x00, 
	},
	{0x00, 0x00, 0x7F, 0xC0, 0x7F, 0x00, 0x7C, 0x00,
	 0x7E, 0x00, 0x7F, 0x00, 0x6F, 0x80, 0x67, 0xC0,
	 0x43, 0xE0, 0x41, 0xF0, 0x00, 0xF8, 0x00, 0x7C,
	 0x00, 0x3E, 0x00, 0x1C, 0x00, 0x08, 0x00, 0x00,
	}
};

void	Cursortocursor(Cursor*);