From: "Niklas Söderlund" <niklas.soderlund@ragnatech.se>
To: Thorsten Blum <thorsten.blum@linux.dev>
Cc: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>,
Andrew Lunn <andrew+netdev@lunn.ch>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Richard Cochran <richardcochran@gmail.com>,
netdev@vger.kernel.org, linux-renesas-soc@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH net-next] net: ethernet: renesas: rcar_gen4_ptp: Remove bool conversion
Date: Mon, 24 Feb 2025 12:13:45 +0100 [thread overview]
Message-ID: <20250224111345.GG515486@ragnatech.se> (raw)
In-Reply-To: <20250223233613.100518-2-thorsten.blum@linux.dev>
Hi Thorsten,
Thanks for your work.
On 2025-02-24 00:36:11 +0100, Thorsten Blum wrote:
> Remove the unnecessary bool conversion and simplify the code.
>
> Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
> ---
> drivers/net/ethernet/renesas/rcar_gen4_ptp.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/ethernet/renesas/rcar_gen4_ptp.c b/drivers/net/ethernet/renesas/rcar_gen4_ptp.c
> index 72e7fcc56693..4c3e8cc5046f 100644
> --- a/drivers/net/ethernet/renesas/rcar_gen4_ptp.c
> +++ b/drivers/net/ethernet/renesas/rcar_gen4_ptp.c
> @@ -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)
> --
> 2.48.1
>
>
--
Kind Regards,
Niklas Söderlund
next prev parent reply other threads:[~2025-02-24 11:13 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-23 23:36 [PATCH net-next] net: ethernet: renesas: rcar_gen4_ptp: Remove bool conversion Thorsten Blum
2025-02-24 9:49 ` Geert Uytterhoeven
2025-02-24 11:13 ` Niklas Söderlund [this message]
2025-02-25 2:20 ` patchwork-bot+netdevbpf
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250224111345.GG515486@ragnatech.se \
--to=niklas.soderlund@ragnatech.se \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-renesas-soc@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=richardcochran@gmail.com \
--cc=thorsten.blum@linux.dev \
--cc=yoshihiro.shimoda.uh@renesas.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox