aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host/ohci-ppc-soc.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/host/ohci-ppc-soc.c')
-rw-r--r--drivers/usb/host/ohci-ppc-soc.c21
1 files changed, 10 insertions, 11 deletions
diff --git a/drivers/usb/host/ohci-ppc-soc.c b/drivers/usb/host/ohci-ppc-soc.c
index 92cf6f4a1374..18755766e406 100644
--- a/drivers/usb/host/ohci-ppc-soc.c
+++ b/drivers/usb/host/ohci-ppc-soc.c
@@ -172,9 +172,8 @@ static const struct hc_driver ohci_ppc_soc_hc_driver = {
172 .start_port_reset = ohci_start_port_reset, 172 .start_port_reset = ohci_start_port_reset,
173}; 173};
174 174
175static int ohci_hcd_ppc_soc_drv_probe(struct device *dev) 175static int ohci_hcd_ppc_soc_drv_probe(struct platform_device *pdev)
176{ 176{
177 struct platform_device *pdev = to_platform_device(dev);
178 int ret; 177 int ret;
179 178
180 if (usb_disabled()) 179 if (usb_disabled())
@@ -184,25 +183,25 @@ static int ohci_hcd_ppc_soc_drv_probe(struct device *dev)
184 return ret; 183 return ret;
185} 184}
186 185
187static int ohci_hcd_ppc_soc_drv_remove(struct device *dev) 186static int ohci_hcd_ppc_soc_drv_remove(struct platform_device *pdev)
188{ 187{
189 struct platform_device *pdev = to_platform_device(dev); 188 struct usb_hcd *hcd = platform_get_drvdata(dev);
190 struct usb_hcd *hcd = dev_get_drvdata(dev);
191 189
192 usb_hcd_ppc_soc_remove(hcd, pdev); 190 usb_hcd_ppc_soc_remove(hcd, pdev);
193 return 0; 191 return 0;
194} 192}
195 193
196static struct device_driver ohci_hcd_ppc_soc_driver = { 194static struct platform_driver ohci_hcd_ppc_soc_driver = {
197 .name = "ppc-soc-ohci",
198 .owner = THIS_MODULE,
199 .bus = &platform_bus_type,
200 .probe = ohci_hcd_ppc_soc_drv_probe, 195 .probe = ohci_hcd_ppc_soc_drv_probe,
201 .remove = ohci_hcd_ppc_soc_drv_remove, 196 .remove = ohci_hcd_ppc_soc_drv_remove,
202#ifdef CONFIG_PM 197#ifdef CONFIG_PM
203 /*.suspend = ohci_hcd_ppc_soc_drv_suspend,*/ 198 /*.suspend = ohci_hcd_ppc_soc_drv_suspend,*/
204 /*.resume = ohci_hcd_ppc_soc_drv_resume,*/ 199 /*.resume = ohci_hcd_ppc_soc_drv_resume,*/
205#endif 200#endif
201 .driver = {
202 .name = "ppc-soc-ohci",
203 .owner = THIS_MODULE,
204 },
206}; 205};
207 206
208static int __init ohci_hcd_ppc_soc_init(void) 207static int __init ohci_hcd_ppc_soc_init(void)
@@ -211,12 +210,12 @@ static int __init ohci_hcd_ppc_soc_init(void)
211 pr_debug("block sizes: ed %d td %d\n", sizeof(struct ed), 210 pr_debug("block sizes: ed %d td %d\n", sizeof(struct ed),
212 sizeof(struct td)); 211 sizeof(struct td));
213 212
214 return driver_register(&ohci_hcd_ppc_soc_driver); 213 return platform_driver_register(&ohci_hcd_ppc_soc_driver);
215} 214}
216 215
217static void __exit ohci_hcd_ppc_soc_cleanup(void) 216static void __exit ohci_hcd_ppc_soc_cleanup(void)
218{ 217{
219 driver_unregister(&ohci_hcd_ppc_soc_driver); 218 platform_driver_unregister(&ohci_hcd_ppc_soc_driver);
220} 219}
221 220
222module_init(ohci_hcd_ppc_soc_init); 221module_init(ohci_hcd_ppc_soc_init);