Skip to content

Commit

Permalink
fsi: aspeed: convert to devm_platform_ioremap_resource
Browse files Browse the repository at this point in the history
Use devm_platform_ioremap_resource() to simplify code.

Signed-off-by: Yangtao Li <[email protected]>
Reviewed-by: Andrew Jeffery <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Joel Stanley <[email protected]>
  • Loading branch information
TinyWindzz authored and shenki committed Jun 4, 2021
1 parent 38483e8 commit a346991
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions drivers/fsi/fsi-master-aspeed.c
Original file line number Diff line number Diff line change
Expand Up @@ -533,7 +533,6 @@ static int tacoma_cabled_fsi_fixup(struct device *dev)
static int fsi_master_aspeed_probe(struct platform_device *pdev)
{
struct fsi_master_aspeed *aspeed;
struct resource *res;
int rc, links, reg;
__be32 raw;

Expand All @@ -549,8 +548,7 @@ static int fsi_master_aspeed_probe(struct platform_device *pdev)

aspeed->dev = &pdev->dev;

res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
aspeed->base = devm_ioremap_resource(&pdev->dev, res);
aspeed->base = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(aspeed->base))
return PTR_ERR(aspeed->base);

Expand Down

0 comments on commit a346991

Please sign in to comment.