diff options
author | Fabio Estevam <festevam@gmail.com> | 2019-06-05 19:37:37 +0200 |
---|---|---|
committer | Peter Chen <peter.chen@nxp.com> | 2019-06-14 11:40:20 +0200 |
commit | 8fbd06e592304a121c61b0a01f0b85e7b5a9a05d (patch) | |
tree | 37615309510e1360a2e5c3e0ec41cffbc9f6e838 /drivers/usb | |
parent | usb: chipidea: Use dev_err() instead of pr_err() (diff) | |
download | linux-8fbd06e592304a121c61b0a01f0b85e7b5a9a05d.tar.xz linux-8fbd06e592304a121c61b0a01f0b85e7b5a9a05d.zip |
usb: chipidea: imx: Use devm_platform_ioremap_resource()
Use devm_platform_ioremap_resource() to simplify the code a bit.
Signed-off-by: Fabio Estevam <festevam@gmail.com>
Signed-off-by: Peter Chen <peter.chen@nxp.com>
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/chipidea/usbmisc_imx.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/usb/chipidea/usbmisc_imx.c b/drivers/usb/chipidea/usbmisc_imx.c index b7a5727d0c8a..078c1fdce493 100644 --- a/drivers/usb/chipidea/usbmisc_imx.c +++ b/drivers/usb/chipidea/usbmisc_imx.c @@ -773,7 +773,6 @@ MODULE_DEVICE_TABLE(of, usbmisc_imx_dt_ids); static int usbmisc_imx_probe(struct platform_device *pdev) { - struct resource *res; struct imx_usbmisc *data; const struct of_device_id *of_id; @@ -787,8 +786,7 @@ static int usbmisc_imx_probe(struct platform_device *pdev) spin_lock_init(&data->lock); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - data->base = devm_ioremap_resource(&pdev->dev, res); + data->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(data->base)) return PTR_ERR(data->base); |