* [PATCH] net: ethernet: ti: am65-cpsw-ethtool: use pm_runtime_resume_and_get
@ 2022-04-19 11:03 cgel.zte
2022-04-22 10:00 ` patchwork-bot+netdevbpf
0 siblings, 1 reply; 2+ messages in thread
From: cgel.zte @ 2022-04-19 11:03 UTC (permalink / raw)
To: davem; +Cc: kuba, netdev, linux-kernel, Minghao Chi, Zeal Robot
From: Minghao Chi <chi.minghao@zte.com.cn>
Using pm_runtime_resume_and_get() to replace pm_runtime_get_sync and
pm_runtime_put_noidle. This change is just to simplify the code, no
actual functional changes.
Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Minghao Chi <chi.minghao@zte.com.cn>
---
drivers/net/ethernet/ti/am65-cpsw-ethtool.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/net/ethernet/ti/am65-cpsw-ethtool.c b/drivers/net/ethernet/ti/am65-cpsw-ethtool.c
index 72acdf802258..abc1e4276cf0 100644
--- a/drivers/net/ethernet/ti/am65-cpsw-ethtool.c
+++ b/drivers/net/ethernet/ti/am65-cpsw-ethtool.c
@@ -380,11 +380,9 @@ static int am65_cpsw_ethtool_op_begin(struct net_device *ndev)
struct am65_cpsw_common *common = am65_ndev_to_common(ndev);
int ret;
- ret = pm_runtime_get_sync(common->dev);
- if (ret < 0) {
+ ret = pm_runtime_resume_and_get(common->dev);
+ if (ret < 0)
dev_err(common->dev, "ethtool begin failed %d\n", ret);
- pm_runtime_put_noidle(common->dev);
- }
return ret;
}
--
2.25.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] net: ethernet: ti: am65-cpsw-ethtool: use pm_runtime_resume_and_get
2022-04-19 11:03 [PATCH] net: ethernet: ti: am65-cpsw-ethtool: use pm_runtime_resume_and_get cgel.zte
@ 2022-04-22 10:00 ` patchwork-bot+netdevbpf
0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2022-04-22 10:00 UTC (permalink / raw)
To: Lv Ruyi; +Cc: davem, kuba, netdev, linux-kernel, chi.minghao, zealci
Hello:
This patch was applied to netdev/net-next.git (master)
by David S. Miller <davem@davemloft.net>:
On Tue, 19 Apr 2022 11:03:52 +0000 you wrote:
> From: Minghao Chi <chi.minghao@zte.com.cn>
>
> Using pm_runtime_resume_and_get() to replace pm_runtime_get_sync and
> pm_runtime_put_noidle. This change is just to simplify the code, no
> actual functional changes.
>
> Reported-by: Zeal Robot <zealci@zte.com.cn>
> Signed-off-by: Minghao Chi <chi.minghao@zte.com.cn>
>
> [...]
Here is the summary with links:
- net: ethernet: ti: am65-cpsw-ethtool: use pm_runtime_resume_and_get
https://git.kernel.org/netdev/net-next/c/e350dbac3c09
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-04-22 10:00 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-19 11:03 [PATCH] net: ethernet: ti: am65-cpsw-ethtool: use pm_runtime_resume_and_get cgel.zte
2022-04-22 10:00 ` patchwork-bot+netdevbpf
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.