Commit a4833c60 authored by Wolfram Sang's avatar Wolfram Sang Committed by Andy Shevchenko

pinctrl: cherryview: simplify getting .driver_data

We should get 'driver_data' from 'struct device' directly. Going via
platform_device is an unneeded step back and forth.
Signed-off-by: default avatarWolfram Sang <wsa+renesas@sang-engineering.com>
Acked-by: default avatarMika Westerberg <mika.westerberg@linux.intel.com>
Acked-by: default avatarLinus Walleij <linus.walleij@linaro.org>
Signed-off-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
parent d481de47
...@@ -1744,8 +1744,7 @@ static int chv_pinctrl_remove(struct platform_device *pdev) ...@@ -1744,8 +1744,7 @@ static int chv_pinctrl_remove(struct platform_device *pdev)
#ifdef CONFIG_PM_SLEEP #ifdef CONFIG_PM_SLEEP
static int chv_pinctrl_suspend_noirq(struct device *dev) static int chv_pinctrl_suspend_noirq(struct device *dev)
{ {
struct platform_device *pdev = to_platform_device(dev); struct chv_pinctrl *pctrl = dev_get_drvdata(dev);
struct chv_pinctrl *pctrl = platform_get_drvdata(pdev);
unsigned long flags; unsigned long flags;
int i; int i;
...@@ -1778,8 +1777,7 @@ static int chv_pinctrl_suspend_noirq(struct device *dev) ...@@ -1778,8 +1777,7 @@ static int chv_pinctrl_suspend_noirq(struct device *dev)
static int chv_pinctrl_resume_noirq(struct device *dev) static int chv_pinctrl_resume_noirq(struct device *dev)
{ {
struct platform_device *pdev = to_platform_device(dev); struct chv_pinctrl *pctrl = dev_get_drvdata(dev);
struct chv_pinctrl *pctrl = platform_get_drvdata(pdev);
unsigned long flags; unsigned long flags;
int i; int i;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment