summaryrefslogtreecommitdiff
path: root/drivers/usb/host/ohci-ppc-of.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/host/ohci-ppc-of.c')
-rw-r--r--drivers/usb/host/ohci-ppc-of.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/usb/host/ohci-ppc-of.c b/drivers/usb/host/ohci-ppc-of.c
index 64c2ed9ff95e..8294e2fcc2f6 100644
--- a/drivers/usb/host/ohci-ppc-of.c
+++ b/drivers/usb/host/ohci-ppc-of.c
@@ -185,8 +185,7 @@ err_rmr:
static int ohci_hcd_ppc_of_remove(struct platform_device *op)
{
- struct usb_hcd *hcd = dev_get_drvdata(&op->dev);
- dev_set_drvdata(&op->dev, NULL);
+ struct usb_hcd *hcd = platform_get_drvdata(op);
dev_dbg(&op->dev, "stopping PPC-OF USB Controller\n");
@@ -203,7 +202,7 @@ static int ohci_hcd_ppc_of_remove(struct platform_device *op)
static void ohci_hcd_ppc_of_shutdown(struct platform_device *op)
{
- struct usb_hcd *hcd = dev_get_drvdata(&op->dev);
+ struct usb_hcd *hcd = platform_get_drvdata(op);
if (hcd->driver->shutdown)
hcd->driver->shutdown(hcd);