summaryrefslogtreecommitdiffstats
path: root/drivers/soc/bcm
diff options
context:
space:
mode:
authorCai Huoqing <caihuoqing@baidu.com>2021-09-08 15:14:16 +0800
committerFlorian Fainelli <f.fainelli@gmail.com>2021-09-14 14:37:42 -0700
commit9787ab5833054500201b980a58ababa3a3ae193c (patch)
treea4650b47eb69c3a20c81766540b0d960b175dfc6 /drivers/soc/bcm
parentdc3401c83f950bfecb7cdffff2b78ac3e09ef505 (diff)
downloadlinux-9787ab5833054500201b980a58ababa3a3ae193c.tar.gz
linux-9787ab5833054500201b980a58ababa3a3ae193c.tar.bz2
linux-9787ab5833054500201b980a58ababa3a3ae193c.zip
soc: bcm63xx-power: Make use of the helper function devm_platform_ioremap_resource()
Use the devm_platform_ioremap_resource() helper instead of calling platform_get_resource() and devm_ioremap_resource() separately Signed-off-by: Cai Huoqing <caihuoqing@baidu.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Diffstat (limited to 'drivers/soc/bcm')
-rw-r--r--drivers/soc/bcm/bcm63xx/bcm63xx-power.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/soc/bcm/bcm63xx/bcm63xx-power.c b/drivers/soc/bcm/bcm63xx/bcm63xx-power.c
index 515fe182dc34..aa72e13d5d0e 100644
--- a/drivers/soc/bcm/bcm63xx/bcm63xx-power.c
+++ b/drivers/soc/bcm/bcm63xx/bcm63xx-power.c
@@ -91,7 +91,6 @@ static int bcm63xx_power_probe(struct platform_device *pdev)
{
struct device *dev = &pdev->dev;
struct device_node *np = dev->of_node;
- struct resource *res;
const struct bcm63xx_power_data *entry, *table;
struct bcm63xx_power *power;
unsigned int ndom;
@@ -102,8 +101,7 @@ static int bcm63xx_power_probe(struct platform_device *pdev)
if (!power)
return -ENOMEM;
- res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- power->base = devm_ioremap_resource(&pdev->dev, res);
+ power->base = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(power->base))
return PTR_ERR(power->base);