plan 9 kernel history: overview | file list | diff list

2000/0401/alphapc/vgas3.c (diff list | history)

1999/0512/sys/src/9/alphapc/vgas3.c:19,252000/0401/sys/src/9/alphapc/vgas3.c:19,25 (short | long | prev | next)
1999/0415    
	int opage; 
 
	crt35 = vgaxi(Crtx, 0x35); 
	if(scr->gscreen->ldepth == 3){ 
2000/0401    
	if(scr->gscreen->depth >= 8){ 
1999/0415    
		/* 
		 * The S3 registers need to be unlocked for this. 
		 * Let's hope they are already: 
1999/0512/sys/src/9/alphapc/vgas3.c:127,1332000/0401/sys/src/9/alphapc/vgas3.c:127,133
1999/0415    
static void 
s3enable(VGAscr* scr) 
{ 
	int i, id; 
2000/0401    
	int i; 
1999/0415    
	ulong storage; 
 
	s3disable(scr); 
1999/0512/sys/src/9/alphapc/vgas3.c:135,1652000/0401/sys/src/9/alphapc/vgas3.c:135,151
1999/0415    
	/* 
	 * Cursor colours. Set both the CR0[EF] and the colour 
	 * stack in case we are using a 16-bit RAMDAC. 
	 * This stuff is just a mystery for the ViRGE/GX2. 
	 */ 
	vgaxo(Crtx, 0x0E, Pwhite); 
	vgaxo(Crtx, 0x0F, Pblack); 
	vgaxi(Crtx, 0x45); 
	id = (vgaxi(Crtx, 0x30)<<8)|vgaxi(Crtx, 0x2E); 
	switch(id){ 
 
	case 0xE110:				/* ViRGE/GX2 */ 
		for(i = 0; i < 3; i++) 
			vgaxo(Crtx, 0x4A, Pblack); 
		vgaxi(Crtx, 0x45); 
		for(i = 0; i < 3; i++) 
			vgaxo(Crtx, 0x4B, Pwhite); 
		break; 
2000/0401    
	for(i = 0; i < 3; i++) 
		vgaxo(Crtx, 0x4A, Pblack); 
	vgaxi(Crtx, 0x45); 
	for(i = 0; i < 3; i++) 
		vgaxo(Crtx, 0x4B, Pwhite); 
1999/0415    
 
	default: 
		for(i = 0; i < 3; i++) 
			vgaxo(Crtx, 0x4A, Pwhite); 
		vgaxi(Crtx, 0x45); 
		for(i = 0; i < 3; i++) 
			vgaxo(Crtx, 0x4B, Pblack); 
		break; 
	} 
                 
	/* 
	 * Find a place for the cursor data in display memory. 
	 * Must be on a 1024-byte boundary. 
1999/0512/sys/src/9/alphapc/vgas3.c:195,2012000/0401/sys/src/9/alphapc/vgas3.c:181,190
1999/0415    
	id = (vgaxi(Crtx, 0x30)<<8)|vgaxi(Crtx, 0x2E); 
	switch(id){ 
 
2000/0401    
	case 0xE131:				/* ViRGE */ 
	case 0xE18A:				/* ViRGE/[DG]X */ 
1999/0415    
	case 0xE110:				/* ViRGE/GX2 */ 
2000/0401    
	case 0xE13D:				/* ViRGE/VX */ 
1999/0415    
		p += scr->storage; 
		break; 
 
1999/0512/sys/src/9/alphapc/vgas3.c:238,2442000/0401/sys/src/9/alphapc/vgas3.c:227,236
1999/0415    
 
	switch(id){ 
 
2000/0401    
	case 0xE131:				/* ViRGE */ 
	case 0xE18A:				/* ViRGE/[DG]X */ 
1999/0415    
	case 0xE110:				/* ViRGE/GX2 */ 
2000/0401    
	case 0xE13D:				/* ViRGE/VX */ 
1999/0415    
		break; 
 
	default: 


source code copyright © 1990-2005 Lucent Technologies; see license
Plan 9 distribution
comments to russ cox (rsc@swtch.com)