diff options
Diffstat (limited to 'drivers/input/misc/cobalt_btns.c')
-rw-r--r-- | drivers/input/misc/cobalt_btns.c | 24 |
1 files changed, 1 insertions, 23 deletions
diff --git a/drivers/input/misc/cobalt_btns.c b/drivers/input/misc/cobalt_btns.c index b14f49e768cc..b9b2d7764e73 100644 --- a/drivers/input/misc/cobalt_btns.c +++ b/drivers/input/misc/cobalt_btns.c | |||
@@ -50,14 +50,6 @@ static struct buttons_map buttons_map[] = { | |||
50 | { 0x80000000, KEY_SELECT, }, | 50 | { 0x80000000, KEY_SELECT, }, |
51 | }; | 51 | }; |
52 | 52 | ||
53 | static struct resource cobalt_buttons_resource __initdata = { | ||
54 | .start = 0x1d000000, | ||
55 | .end = 0x1d000003, | ||
56 | .flags = IORESOURCE_MEM, | ||
57 | }; | ||
58 | |||
59 | static struct platform_device *cobalt_buttons_device; | ||
60 | |||
61 | static struct timer_list buttons_timer; | 53 | static struct timer_list buttons_timer; |
62 | 54 | ||
63 | static void handle_buttons(unsigned long data) | 55 | static void handle_buttons(unsigned long data) |
@@ -183,26 +175,12 @@ static struct platform_driver cobalt_buttons_driver = { | |||
183 | 175 | ||
184 | static int __init cobalt_buttons_init(void) | 176 | static int __init cobalt_buttons_init(void) |
185 | { | 177 | { |
186 | int retval; | 178 | return platform_driver_register(&cobalt_buttons_driver); |
187 | |||
188 | cobalt_buttons_device = platform_device_register_simple("Cobalt buttons", -1, | ||
189 | &cobalt_buttons_resource, 1); | ||
190 | if (IS_ERR(cobalt_buttons_device)) { | ||
191 | retval = PTR_ERR(cobalt_buttons_device); | ||
192 | return retval; | ||
193 | } | ||
194 | |||
195 | retval = platform_driver_register(&cobalt_buttons_driver); | ||
196 | if (retval < 0) | ||
197 | platform_device_unregister(cobalt_buttons_device); | ||
198 | |||
199 | return retval; | ||
200 | } | 179 | } |
201 | 180 | ||
202 | static void __exit cobalt_buttons_exit(void) | 181 | static void __exit cobalt_buttons_exit(void) |
203 | { | 182 | { |
204 | platform_driver_unregister(&cobalt_buttons_driver); | 183 | platform_driver_unregister(&cobalt_buttons_driver); |
205 | platform_device_unregister(cobalt_buttons_device); | ||
206 | } | 184 | } |
207 | 185 | ||
208 | module_init(cobalt_buttons_init); | 186 | module_init(cobalt_buttons_init); |