diff options
author | Vignesh Raghavendra <vigneshr@ti.com> | 2020-09-24 13:42:13 +0530 |
---|---|---|
committer | Vignesh Raghavendra <vigneshr@ti.com> | 2020-09-30 13:35:18 +0530 |
commit | 992df3bb35a1004f86126d2f80c83450b383f7f4 (patch) | |
tree | 3d50c8f3ae0fd575a0444292da20d5ce6509cd90 /drivers/mtd | |
parent | aca31ce96814c84d1a41aaa109c15abe61005af7 (diff) | |
download | linux-992df3bb35a1004f86126d2f80c83450b383f7f4.tar.gz linux-992df3bb35a1004f86126d2f80c83450b383f7f4.tar.bz2 linux-992df3bb35a1004f86126d2f80c83450b383f7f4.zip |
mtd: hyperbus: hbmc-am654: Drop pm_runtime* calls from probe
Recent genpd changes for K3 platform ensure device is ON before driver
probe is called. Therefore, drop redundant pm_runtime_* calls from
driver to simplify the code.
Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
Link: https://lore.kernel.org/r/20200924081214.16934-4-vigneshr@ti.com
Diffstat (limited to 'drivers/mtd')
-rw-r--r-- | drivers/mtd/hyperbus/hbmc-am654.c | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/drivers/mtd/hyperbus/hbmc-am654.c b/drivers/mtd/hyperbus/hbmc-am654.c index 1e70ecfffa39..b6a2400fcaa9 100644 --- a/drivers/mtd/hyperbus/hbmc-am654.c +++ b/drivers/mtd/hyperbus/hbmc-am654.c @@ -13,7 +13,6 @@ #include <linux/of.h> #include <linux/of_address.h> #include <linux/platform_device.h> -#include <linux/pm_runtime.h> #include <linux/types.h> #define AM654_HBMC_CALIB_COUNT 25 @@ -89,13 +88,6 @@ static int am654_hbmc_probe(struct platform_device *pdev) priv->mux_ctrl = control; } - pm_runtime_enable(dev); - ret = pm_runtime_get_sync(dev); - if (ret < 0) { - pm_runtime_put_noidle(dev); - goto disable_pm; - } - priv->hbdev.map.size = resource_size(&res); priv->hbdev.map.virt = devm_ioremap_resource(dev, &res); if (IS_ERR(priv->hbdev.map.virt)) @@ -107,13 +99,11 @@ static int am654_hbmc_probe(struct platform_device *pdev) ret = hyperbus_register_device(&priv->hbdev); if (ret) { dev_err(dev, "failed to register controller\n"); - pm_runtime_put_sync(&pdev->dev); - goto disable_pm; + goto disable_mux; } return 0; -disable_pm: - pm_runtime_disable(dev); +disable_mux: if (priv->mux_ctrl) mux_control_deselect(priv->mux_ctrl); return ret; @@ -127,8 +117,6 @@ static int am654_hbmc_remove(struct platform_device *pdev) ret = hyperbus_unregister_device(&priv->hbdev); if (priv->mux_ctrl) mux_control_deselect(priv->mux_ctrl); - pm_runtime_put_sync(&pdev->dev); - pm_runtime_disable(&pdev->dev); return ret; } |