diff options
author | Len Brown <len.brown@intel.com> | 2005-12-06 17:31:30 -0500 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2005-12-06 17:31:30 -0500 |
commit | 3d5271f9883cba7b54762bc4fe027d4172f06db7 (patch) | |
tree | ab8a881a14478598a0c8bda0d26c62cdccfffd6d /drivers/usb/host/ohci-pxa27x.c | |
parent | 378b2556f4e09fa6f87ff0cb5c4395ff28257d02 (diff) | |
parent | 9115a6c787596e687df03010d97fccc5e0762506 (diff) |
Pull release into acpica branch
Diffstat (limited to 'drivers/usb/host/ohci-pxa27x.c')
-rw-r--r-- | drivers/usb/host/ohci-pxa27x.c | 41 |
1 files changed, 21 insertions, 20 deletions
diff --git a/drivers/usb/host/ohci-pxa27x.c b/drivers/usb/host/ohci-pxa27x.c index 2fdb262d4726..9d65ec307990 100644 --- a/drivers/usb/host/ohci-pxa27x.c +++ b/drivers/usb/host/ohci-pxa27x.c | |||
@@ -20,6 +20,9 @@ | |||
20 | */ | 20 | */ |
21 | 21 | ||
22 | #include <linux/device.h> | 22 | #include <linux/device.h> |
23 | #include <linux/signal.h> | ||
24 | #include <linux/platform_device.h> | ||
25 | |||
23 | #include <asm/mach-types.h> | 26 | #include <asm/mach-types.h> |
24 | #include <asm/hardware.h> | 27 | #include <asm/hardware.h> |
25 | #include <asm/arch/pxa-regs.h> | 28 | #include <asm/arch/pxa-regs.h> |
@@ -278,17 +281,17 @@ static const struct hc_driver ohci_pxa27x_hc_driver = { | |||
278 | */ | 281 | */ |
279 | .hub_status_data = ohci_hub_status_data, | 282 | .hub_status_data = ohci_hub_status_data, |
280 | .hub_control = ohci_hub_control, | 283 | .hub_control = ohci_hub_control, |
281 | #ifdef CONFIG_USB_SUSPEND | 284 | #ifdef CONFIG_PM |
282 | .hub_suspend = ohci_hub_suspend, | 285 | .bus_suspend = ohci_bus_suspend, |
283 | .hub_resume = ohci_hub_resume, | 286 | .bus_resume = ohci_bus_resume, |
284 | #endif | 287 | #endif |
288 | .start_port_reset = ohci_start_port_reset, | ||
285 | }; | 289 | }; |
286 | 290 | ||
287 | /*-------------------------------------------------------------------------*/ | 291 | /*-------------------------------------------------------------------------*/ |
288 | 292 | ||
289 | static int ohci_hcd_pxa27x_drv_probe(struct device *dev) | 293 | static int ohci_hcd_pxa27x_drv_probe(struct platform_device *pdev) |
290 | { | 294 | { |
291 | struct platform_device *pdev = to_platform_device(dev); | ||
292 | int ret; | 295 | int ret; |
293 | 296 | ||
294 | pr_debug ("In ohci_hcd_pxa27x_drv_probe"); | 297 | pr_debug ("In ohci_hcd_pxa27x_drv_probe"); |
@@ -300,41 +303,39 @@ static int ohci_hcd_pxa27x_drv_probe(struct device *dev) | |||
300 | return ret; | 303 | return ret; |
301 | } | 304 | } |
302 | 305 | ||
303 | static int ohci_hcd_pxa27x_drv_remove(struct device *dev) | 306 | static int ohci_hcd_pxa27x_drv_remove(struct platform_device *pdev) |
304 | { | 307 | { |
305 | struct platform_device *pdev = to_platform_device(dev); | 308 | struct usb_hcd *hcd = platform_get_drvdata(pdev); |
306 | struct usb_hcd *hcd = dev_get_drvdata(dev); | ||
307 | 309 | ||
308 | usb_hcd_pxa27x_remove(hcd, pdev); | 310 | usb_hcd_pxa27x_remove(hcd, pdev); |
309 | return 0; | 311 | return 0; |
310 | } | 312 | } |
311 | 313 | ||
312 | static int ohci_hcd_pxa27x_drv_suspend(struct device *dev, pm_message_t state, u32 level) | 314 | static int ohci_hcd_pxa27x_drv_suspend(struct platform_device *dev, pm_message_t state) |
313 | { | 315 | { |
314 | // struct platform_device *pdev = to_platform_device(dev); | 316 | // struct usb_hcd *hcd = platform_get_drvdata(dev); |
315 | // struct usb_hcd *hcd = dev_get_drvdata(dev); | ||
316 | printk("%s: not implemented yet\n", __FUNCTION__); | 317 | printk("%s: not implemented yet\n", __FUNCTION__); |
317 | 318 | ||
318 | return 0; | 319 | return 0; |
319 | } | 320 | } |
320 | 321 | ||
321 | static int ohci_hcd_pxa27x_drv_resume(struct device *dev, u32 level) | 322 | static int ohci_hcd_pxa27x_drv_resume(struct platform_device *dev) |
322 | { | 323 | { |
323 | // struct platform_device *pdev = to_platform_device(dev); | 324 | // struct usb_hcd *hcd = platform_get_drvdata(dev); |
324 | // struct usb_hcd *hcd = dev_get_drvdata(dev); | ||
325 | printk("%s: not implemented yet\n", __FUNCTION__); | 325 | printk("%s: not implemented yet\n", __FUNCTION__); |
326 | 326 | ||
327 | return 0; | 327 | return 0; |
328 | } | 328 | } |
329 | 329 | ||
330 | 330 | ||
331 | static struct device_driver ohci_hcd_pxa27x_driver = { | 331 | static struct platform_driver ohci_hcd_pxa27x_driver = { |
332 | .name = "pxa27x-ohci", | ||
333 | .bus = &platform_bus_type, | ||
334 | .probe = ohci_hcd_pxa27x_drv_probe, | 332 | .probe = ohci_hcd_pxa27x_drv_probe, |
335 | .remove = ohci_hcd_pxa27x_drv_remove, | 333 | .remove = ohci_hcd_pxa27x_drv_remove, |
336 | .suspend = ohci_hcd_pxa27x_drv_suspend, | 334 | .suspend = ohci_hcd_pxa27x_drv_suspend, |
337 | .resume = ohci_hcd_pxa27x_drv_resume, | 335 | .resume = ohci_hcd_pxa27x_drv_resume, |
336 | .driver = { | ||
337 | .name = "pxa27x-ohci", | ||
338 | }, | ||
338 | }; | 339 | }; |
339 | 340 | ||
340 | static int __init ohci_hcd_pxa27x_init (void) | 341 | static int __init ohci_hcd_pxa27x_init (void) |
@@ -343,12 +344,12 @@ static int __init ohci_hcd_pxa27x_init (void) | |||
343 | pr_debug ("block sizes: ed %d td %d\n", | 344 | pr_debug ("block sizes: ed %d td %d\n", |
344 | sizeof (struct ed), sizeof (struct td)); | 345 | sizeof (struct ed), sizeof (struct td)); |
345 | 346 | ||
346 | return driver_register(&ohci_hcd_pxa27x_driver); | 347 | return platform_driver_register(&ohci_hcd_pxa27x_driver); |
347 | } | 348 | } |
348 | 349 | ||
349 | static void __exit ohci_hcd_pxa27x_cleanup (void) | 350 | static void __exit ohci_hcd_pxa27x_cleanup (void) |
350 | { | 351 | { |
351 | driver_unregister(&ohci_hcd_pxa27x_driver); | 352 | platform_driver_unregister(&ohci_hcd_pxa27x_driver); |
352 | } | 353 | } |
353 | 354 | ||
354 | module_init (ohci_hcd_pxa27x_init); | 355 | module_init (ohci_hcd_pxa27x_init); |