linux-phy.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/4] phy: marvell: phy-mvebu-cp110-comphy: Use devm_platform_get_and_ioremap_resource()
@ 2023-07-05  9:01 Yangtao Li
  2023-07-05  9:01 ` [PATCH 2/4] phy: rockchip: phy-rockchip-typec: " Yangtao Li
                   ` (3 more replies)
  0 siblings, 4 replies; 11+ messages in thread
From: Yangtao Li @ 2023-07-05  9:01 UTC (permalink / raw)
  To: Vinod Koul, Kishon Vijay Abraham I; +Cc: Yangtao Li, linux-phy, linux-kernel

Convert platform_get_resource(), devm_ioremap_resource() to a single
call to devm_platform_get_and_ioremap_resource(), as this is exactly
what this function does.

Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 drivers/phy/marvell/phy-mvebu-cp110-comphy.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/phy/marvell/phy-mvebu-cp110-comphy.c b/drivers/phy/marvell/phy-mvebu-cp110-comphy.c
index 34672e868a1e..ddaddb3c498f 100644
--- a/drivers/phy/marvell/phy-mvebu-cp110-comphy.c
+++ b/drivers/phy/marvell/phy-mvebu-cp110-comphy.c
@@ -1011,8 +1011,7 @@ static int mvebu_comphy_probe(struct platform_device *pdev)
 						"marvell,system-controller");
 	if (IS_ERR(priv->regmap))
 		return PTR_ERR(priv->regmap);
-	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-	priv->base = devm_ioremap_resource(&pdev->dev, res);
+	priv->base = devm_platform_get_and_ioremap_resource(pdev, 0, &res);
 	if (IS_ERR(priv->base))
 		return PTR_ERR(priv->base);
 
-- 
2.39.0


-- 
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy

^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2023-07-11 13:39 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-05  9:01 [PATCH 1/4] phy: marvell: phy-mvebu-cp110-comphy: Use devm_platform_get_and_ioremap_resource() Yangtao Li
2023-07-05  9:01 ` [PATCH 2/4] phy: rockchip: phy-rockchip-typec: " Yangtao Li
2023-07-11 13:39   ` Heiko Stuebner
2023-07-05  9:01 ` [PATCH 3/4] phy: renesas: r8a779f0-ether-serdes: Convert to devm_platform_ioremap_resource() Yangtao Li
2023-07-05  9:01 ` [PATCH 4/4] phy: mediatek: tphy: " Yangtao Li
2023-07-05  9:22   ` AngeloGioacchino Del Regno
2023-07-05  9:30     ` Yangtao Li
2023-07-05 10:00       ` AngeloGioacchino Del Regno
2023-07-11  5:07         ` Vinod Koul
2023-07-11  8:57         ` Chunfeng Yun (云春峰)
2023-07-11  5:11 ` (subset) [PATCH 1/4] phy: marvell: phy-mvebu-cp110-comphy: Use devm_platform_get_and_ioremap_resource() Vinod Koul

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).