6 * Copyright (c) 1999-2002 Vojtech Pavlik
8 * This program is free software; you can redistribute it and/or modify it
9 * under the terms of the GNU General Public License version 2 as published by
10 * the Free Software Foundation.
14 * Arch-dependent inline functions and defines.
17 #if defined(CONFIG_MACH_JAZZ)
18 #include "i8042-jazzio.h"
19 #elif defined(CONFIG_SGI_HAS_I8042)
20 #include "i8042-ip22io.h"
21 #elif defined(CONFIG_SNI_RM)
22 #include "i8042-snirm.h"
23 #elif defined(CONFIG_PPC)
24 #include "i8042-ppcio.h"
25 #elif defined(CONFIG_SPARC)
26 #include "i8042-sparcio.h"
27 #elif defined(CONFIG_X86) || defined(CONFIG_IA64)
28 #include "i8042-x86ia64io.h"
29 #elif defined(CONFIG_UNICORE32)
30 #include "i8042-unicore32io.h"
36 * This is in 50us units, the time we wait for the i8042 to react. This
37 * has to be long enough for the i8042 itself to timeout on sending a byte
38 * to a non-existent mouse.
41 #define I8042_CTL_TIMEOUT 10000
47 #define I8042_RET_CTL_TEST 0x55
50 * Expected maximum internal i8042 buffer size. This is used for flushing
54 #define I8042_BUFFER_SIZE 16
57 * Number of AUX ports on controllers supporting active multiplexing
61 #define I8042_NUM_MUX_PORTS 4
68 static unsigned long i8042_start_time
;
69 #define dbg_init() do { i8042_start_time = jiffies; } while (0)
70 #define dbg(format, arg...) \
73 printk(KERN_DEBUG KBUILD_MODNAME ": [%d] " format, \
74 (int) (jiffies - i8042_start_time), ##arg); \
77 #define dbg_init() do { } while (0)
78 #define dbg(format, arg...) \
81 printk(KERN_DEBUG pr_fmt(format), ##arg); \