net: ethernet: renesas: rcar_gen4_ptp: Remove bool conversion
Subsystems (4)
PATCH 1/1 net: ethernet: renesas: rcar_gen4_ptp: Remove bool conversion
Remove the unnecessary bool conversion and simplify the code.
Signed-off-by Thorsten Blum <[email protected]>
--- drivers/net/ethernet/renesas/rcar_gen4_ptp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/renesas/rcar_gen4_ptp.c +1 -1
@@ -29,8 +29,8 @@ static const struct rcar_gen4_ptp_reg_offset gen4_offs = {static int rcar_gen4_ptp_adjfine (struct ptp_clock_info *ptp,long scaled_ppm) {struct rcar_gen4_ptp_private *ptp_priv =ptp_to_priv (ptp); -bool neg_adj = scaled_ppm <0 ? true : false;s64 addend = ptp_priv->default_addend; +bool neg_adj = scaled_ppm <0 ;s64 diff;if (neg_adj)
Signature · 1 line
2.48.1
Quoted 3 lines · Thorsten Blum
Remove the unnecessary bool conversion and simplify the code.
Signed-off-by Thorsten Blum <[email protected]>
Reviewed-by Geert Uytterhoeven <[email protected]>
Gr{oetje,eeting}s,
Geert
Signature · 5 lines
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected] In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds
Hi Thorsten,
Thanks for your work.
Quoted 3 lines · Thorsten Blum
Remove the unnecessary bool conversion and simplify the code.
Signed-off-by Thorsten Blum <[email protected]>
Reviewed-by Niklas Söderlund <[email protected]>
Quoted 22 lines
--- drivers/net/ethernet/renesas/rcar_gen4_ptp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/net/ethernet/renesas/rcar_gen4_ptp.c +1
-1@@ -29,8 +29,8 @@ static const struct rcar_gen4_ptp_reg_offset gen4_offs = {static int rcar_gen4_ptp_adjfine (struct ptp_clock_info *ptp,long scaled_ppm) {struct rcar_gen4_ptp_private *ptp_priv =ptp_to_priv (ptp); -bool neg_adj = scaled_ppm <0 ? true : false;s64 addend = ptp_priv->default_addend; +bool neg_adj = scaled_ppm <0 ;s64 diff;if (neg_adj)Signature · 1 line
2.48.1
Signature · 2 lines
Kind Regards, Niklas Söderlund
This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:
Hello:
This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:
Quoted 6 lines · On Mon, 24 Feb 2025 00:36:11 +0100 you wrote:
Remove the unnecessary bool conversion and simplify the code.
Signed-off-by Thorsten Blum <[email protected]>--- drivers/net/ethernet/renesas/rcar_gen4_ptp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Here is the summary with links:
- [net-next] net: ethernet: renesas: rcar_gen4_ptp: Remove bool conversion
https://git.kernel.org/netdev/net-next/c/6538c8ca8ee1
You are awesome, thank you!
Signature · 2 lines
Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html