projects
/
platform
/
kernel
/
linux-starfive.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8e665c9
)
fpga: bridge: Convert to devm_platform_ioremap_resource()
author
Yangtao Li
<frank.li@vivo.com>
Wed, 5 Jul 2023 09:46:48 +0000
(17:46 +0800)
committer
Xu Yilun
<yilun.xu@intel.com>
Mon, 10 Jul 2023 08:41:20 +0000
(16:41 +0800)
Use devm_platform_ioremap_resource() to simplify code.
Signed-off-by: Yangtao Li <frank.li@vivo.com>
Acked-by: Xu Yilun <yilun.xu@intel.com>
Link:
https://lore.kernel.org/r/20230705094655.44753-1-frank.li@vivo.com
Signed-off-by: Xu Yilun <yilun.xu@intel.com>
drivers/fpga/altera-freeze-bridge.c
patch
|
blob
|
history
diff --git
a/drivers/fpga/altera-freeze-bridge.c
b/drivers/fpga/altera-freeze-bridge.c
index
445f4b0
..
bb6b02e
100644
(file)
--- a/
drivers/fpga/altera-freeze-bridge.c
+++ b/
drivers/fpga/altera-freeze-bridge.c
@@
-213,14
+213,12
@@
static int altera_freeze_br_probe(struct platform_device *pdev)
void __iomem *base_addr;
struct altera_freeze_br_data *priv;
struct fpga_bridge *br;
- struct resource *res;
u32 status, revision;
if (!np)
return -ENODEV;
- res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- base_addr = devm_ioremap_resource(dev, res);
+ base_addr = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(base_addr))
return PTR_ERR(base_addr);