aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input
diff options
context:
space:
mode:
authorAlexander Beregalov <a.beregalov@gmail.com>2008-08-06 05:43:24 -0400
committerDavid S. Miller <davem@davemloft.net>2008-08-06 05:43:24 -0400
commit8c6a5cad1eec38c2bf3af94eb2d4350be29fa208 (patch)
tree193220b1190264d534fb25c7cd11ba24de227d46 /drivers/input
parent0967d61ea0d8e8a7826bd8949cd93dd1e829ac55 (diff)
sparc: i8042-sparcio.h: fix warning
drivers/input/serio/i8042-sparcio.h:95: warning: 'sparc_i8042_driver' defined but not used Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/input')
-rw-r--r--drivers/input/serio/i8042-sparcio.h19
1 files changed, 13 insertions, 6 deletions
diff --git a/drivers/input/serio/i8042-sparcio.h b/drivers/input/serio/i8042-sparcio.h
index d9ca55891cd..66bafe308b0 100644
--- a/drivers/input/serio/i8042-sparcio.h
+++ b/drivers/input/serio/i8042-sparcio.h
@@ -41,6 +41,8 @@ static inline void i8042_write_command(int val)
41 writeb(val, kbd_iobase + 0x64UL); 41 writeb(val, kbd_iobase + 0x64UL);
42} 42}
43 43
44#ifdef CONFIG_PCI
45
44#define OBP_PS2KBD_NAME1 "kb_ps2" 46#define OBP_PS2KBD_NAME1 "kb_ps2"
45#define OBP_PS2KBD_NAME2 "keyboard" 47#define OBP_PS2KBD_NAME2 "keyboard"
46#define OBP_PS2MS_NAME1 "kdmouse" 48#define OBP_PS2MS_NAME1 "kdmouse"
@@ -101,9 +103,6 @@ static struct of_platform_driver sparc_i8042_driver = {
101 103
102static int __init i8042_platform_init(void) 104static int __init i8042_platform_init(void)
103{ 105{
104#ifndef CONFIG_PCI
105 return -ENODEV;
106#else
107 struct device_node *root = of_find_node_by_path("/"); 106 struct device_node *root = of_find_node_by_path("/");
108 107
109 if (!strcmp(root->name, "SUNW,JavaStation-1")) { 108 if (!strcmp(root->name, "SUNW,JavaStation-1")) {
@@ -131,17 +130,25 @@ static int __init i8042_platform_init(void)
131 i8042_reset = 1; 130 i8042_reset = 1;
132 131
133 return 0; 132 return 0;
134#endif /* CONFIG_PCI */
135} 133}
136 134
137static inline void i8042_platform_exit(void) 135static inline void i8042_platform_exit(void)
138{ 136{
139#ifdef CONFIG_PCI
140 struct device_node *root = of_find_node_by_path("/"); 137 struct device_node *root = of_find_node_by_path("/");
141 138
142 if (strcmp(root->name, "SUNW,JavaStation-1")) 139 if (strcmp(root->name, "SUNW,JavaStation-1"))
143 of_unregister_driver(&sparc_i8042_driver); 140 of_unregister_driver(&sparc_i8042_driver);
144#endif
145} 141}
146 142
143#else /* !CONFIG_PCI */
144static int __init i8042_platform_init(void)
145{
146 return -ENODEV;
147}
148
149static inline void i8042_platform_exit(void)
150{
151}
152#endif /* !CONFIG_PCI */
153
147#endif /* _I8042_SPARCIO_H */ 154#endif /* _I8042_SPARCIO_H */