Commit 2790a70c authored by Andy Shevchenko's avatar Andy Shevchenko Committed by Lee Jones

mfd: intel_soc_pmic_bxtwc: Convert to use platform_get/set_drvdata()

We have the specific helpers for platform device to set and get
its driver data. Convert driver to use them instead of open coded
variants.
Signed-off-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
Link: https://lore.kernel.org/r/20220628221747.33956-3-andriy.shevchenko@linux.intel.com
parent 929a4d28
......@@ -457,7 +457,7 @@ static int bxtwc_probe(struct platform_device *pdev)
return ret;
pmic->irq = ret;
dev_set_drvdata(&pdev->dev, pmic);
platform_set_drvdata(pdev, pmic);
pmic->dev = &pdev->dev;
pmic->scu = devm_intel_scu_ipc_dev_get(&pdev->dev);
......@@ -574,7 +574,7 @@ static int bxtwc_probe(struct platform_device *pdev)
static void bxtwc_shutdown(struct platform_device *pdev)
{
struct intel_soc_pmic *pmic = dev_get_drvdata(&pdev->dev);
struct intel_soc_pmic *pmic = platform_get_drvdata(pdev);
disable_irq(pmic->irq);
}
......
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