usb: renesas: use dev_get_platdata()
authorJingoo Han <jg1.han@samsung.com>
Tue, 30 Jul 2013 08:06:20 +0000 (17:06 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 1 Aug 2013 00:28:45 +0000 (17:28 -0700)
Use the wrapper function for retrieving the platform data instead of
accessing dev->platform_data directly.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/renesas_usbhs/common.c

index cfd205036aba66303736baa5643f60e988eabb17..3b39757c13bc8961d95a321aacd8db9f230fab1e 100644 (file)
@@ -416,7 +416,7 @@ static int usbhsc_drvcllbck_notify_hotplug(struct platform_device *pdev)
  */
 static int usbhs_probe(struct platform_device *pdev)
 {
-       struct renesas_usbhs_platform_info *info = pdev->dev.platform_data;
+       struct renesas_usbhs_platform_info *info = dev_get_platdata(&pdev->dev);
        struct renesas_usbhs_driver_callback *dfunc;
        struct usbhs_priv *priv;
        struct resource *res, *irq_res;
@@ -558,7 +558,7 @@ probe_end_pipe_exit:
 static int usbhs_remove(struct platform_device *pdev)
 {
        struct usbhs_priv *priv = usbhs_pdev_to_priv(pdev);
-       struct renesas_usbhs_platform_info *info = pdev->dev.platform_data;
+       struct renesas_usbhs_platform_info *info = dev_get_platdata(&pdev->dev);
        struct renesas_usbhs_driver_callback *dfunc = &info->driver_callback;
 
        dev_dbg(&pdev->dev, "usb remove\n");