mirror of https://gitee.com/openkylin/linux.git
pinctrl: merrifield: Use devm_platform_ioremap_resource()
Use the new helper that wraps the calls to platform_get_resource() and devm_ioremap_resource() together. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com>
This commit is contained in:
parent
9d5b6a9520
commit
fa01aff976
|
@ -885,7 +885,6 @@ static int mrfld_pinctrl_probe(struct platform_device *pdev)
|
|||
{
|
||||
struct mrfld_family *families;
|
||||
struct mrfld_pinctrl *mp;
|
||||
struct resource *mem;
|
||||
void __iomem *regs;
|
||||
size_t nfamilies;
|
||||
unsigned int i;
|
||||
|
@ -897,8 +896,7 @@ static int mrfld_pinctrl_probe(struct platform_device *pdev)
|
|||
mp->dev = &pdev->dev;
|
||||
raw_spin_lock_init(&mp->lock);
|
||||
|
||||
mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
|
||||
regs = devm_ioremap_resource(&pdev->dev, mem);
|
||||
regs = devm_platform_ioremap_resource(pdev, 0);
|
||||
if (IS_ERR(regs))
|
||||
return PTR_ERR(regs);
|
||||
|
||||
|
|
Loading…
Reference in New Issue