0001
0002 #ifndef _I8042_IP22_H
0003 #define _I8042_IP22_H
0004
0005 #include <asm/sgi/ioc.h>
0006 #include <asm/sgi/ip22.h>
0007
0008
0009
0010
0011
0012
0013 #define I8042_KBD_PHYS_DESC "hpc3ps2/serio0"
0014 #define I8042_AUX_PHYS_DESC "hpc3ps2/serio1"
0015 #define I8042_MUX_PHYS_DESC "hpc3ps2/serio%d"
0016
0017
0018
0019
0020
0021 #define I8042_KBD_IRQ SGI_KEYBD_IRQ
0022 #define I8042_AUX_IRQ SGI_KEYBD_IRQ
0023
0024
0025
0026
0027
0028 #define I8042_COMMAND_REG ((unsigned long)&sgioc->kbdmouse.command)
0029 #define I8042_STATUS_REG ((unsigned long)&sgioc->kbdmouse.command)
0030 #define I8042_DATA_REG ((unsigned long)&sgioc->kbdmouse.data)
0031
0032 static inline int i8042_read_data(void)
0033 {
0034 return sgioc->kbdmouse.data;
0035 }
0036
0037 static inline int i8042_read_status(void)
0038 {
0039 return sgioc->kbdmouse.command;
0040 }
0041
0042 static inline void i8042_write_data(int val)
0043 {
0044 sgioc->kbdmouse.data = val;
0045 }
0046
0047 static inline void i8042_write_command(int val)
0048 {
0049 sgioc->kbdmouse.command = val;
0050 }
0051
0052 static inline int i8042_platform_init(void)
0053 {
0054 #if 0
0055
0056 if (!request_mem_region(sgi_kh, sizeof(struct hpc_keyb), "i8042"))
0057 return -EBUSY;
0058 #endif
0059
0060 i8042_reset = I8042_RESET_ALWAYS;
0061
0062 return 0;
0063 }
0064
0065 static inline void i8042_platform_exit(void)
0066 {
0067 #if 0
0068 release_mem_region(JAZZ_KEYBOARD_ADDRESS, sizeof(struct hpc_keyb));
0069 #endif
0070 }
0071
0072 #endif