Subversion Repositories shark

Compare Revisions

Ignore whitespace Rev 155 → Rev 228

/shark/trunk/drivers/oldchar/8042.c
20,11 → 20,11
 
/**
------------
CVS : $Id: 8042.c,v 1.3 2003-04-30 14:40:14 pj Exp $
CVS : $Id: 8042.c,v 1.4 2003-09-12 10:09:55 giacomo Exp $
 
File: $File$
Revision: $Revision: 1.3 $
Last update: $Date: 2003-04-30 14:40:14 $
Revision: $Revision: 1.4 $
Last update: $Date: 2003-09-12 10:09:55 $
------------
 
8042.h
433,10 → 433,16
/* Set keyboard typematic rate */
trace("Sending keyboard rate command...");
c=C8042_keyboardhandshake(KBD_CMD_SET_RATE);
if (c) return;
if (c) {
kern_frestore(f);
return;
}
trace("Sending rate...");
c=C8042_keyboardhandshake(DEFAULT_KEYBRATE);
if (c) return;
if (c) {
kern_frestore(f);
return;
}
 
/* restore interrupts status */
kern_frestore(f);
1071,7 → 1077,10
/* Disable keyboard (for the following phase) */
trace("disabling keyboard");
c=C8042_keyboardhandshake(KBD_CMD_DISABLE);
if (c) return -5;
if (c) {
kern_frestore(f);
return -5;
}
 
/* Disable PS/2 mouse port */
trace("disabling PS/2 mouse port");
1112,7 → 1121,10
/* Disable keyboard (for the following phase) */
trace("disabling keyboard");
c=C8042_keyboardhandshake(KBD_CMD_DISABLE);
if (c) return -5;
if (c) {
kern_frestore(f);
return -5;
}
/* Initialize controller "command register" */
trace("senfing WRITE_MODE command");
1123,12 → 1135,18
/* Enable PS/2 mouse port */
trace("enabling ps/2 mouse port");
c=C8042_sendctrldata(KBD_CCMD_MOUSE_ENABLE);
if (c) return -18;
if (c) {
kern_frestore(f);
return -18;
}
 
/* Enable keyboard */
trace("enabling keyboard");
c=C8042_keyboardhandshake(KBD_CMD_ENABLE);
if (c) return -37;
if (c) {
kern_frestore(f);
return -37;
}
 
/* restore interrupt mask */
trace("enabling interrupts");