From: Ruan Jinjie <ruanjinjie@huawei.com>
To: Ping-Ke Shih <pkshih@realtek.com>,
"sgoutham@marvell.com" <sgoutham@marvell.com>,
"davem@davemloft.net" <davem@davemloft.net>,
"edumazet@google.com" <edumazet@google.com>,
"kuba@kernel.org" <kuba@kernel.org>,
"pabeni@redhat.com" <pabeni@redhat.com>,
"jesse.brandeburg@intel.com" <jesse.brandeburg@intel.com>,
"anthony.l.nguyen@intel.com" <anthony.l.nguyen@intel.com>,
"tariqt@nvidia.com" <tariqt@nvidia.com>,
"s.shtylyov@omp.ru" <s.shtylyov@omp.ru>,
"aspriel@gmail.com" <aspriel@gmail.com>,
"franky.lin@broadcom.com" <franky.lin@broadcom.com>,
"hante.meuleman@broadcom.com" <hante.meuleman@broadcom.com>,
"kvalo@kernel.org" <kvalo@kernel.org>,
"richardcochran@gmail.com" <richardcochran@gmail.com>,
"yoshihiro.shimoda.uh@renesas.com"
<yoshihiro.shimoda.uh@renesas.com>,
"u.kleine-koenig@pengutronix.de" <u.kleine-koenig@pengutronix.de>,
"mkl@pengutronix.de" <mkl@pengutronix.de>,
"lee@kernel.org" <lee@kernel.org>,
"set_pte_at@outlook.com" <set_pte_at@outlook.com>,
"linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
"intel-wired-lan@lists.osuosl.org"
<intel-wired-lan@lists.osuosl.org>,
"linux-rdma@vger.kernel.org" <linux-rdma@vger.kernel.org>,
"linux-renesas-soc@vger.kernel.org"
<linux-renesas-soc@vger.kernel.org>,
"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>,
"brcm80211-dev-list.pdl@broadcom.com"
<brcm80211-dev-list.pdl@broadcom.com>,
"SHA-cyfmac-dev-list@infineon.com"
<SHA-cyfmac-dev-list@infineon.com>
Subject: Re: [PATCH -next 6/6] brcm80211: Remove an unnecessary ternary operator
Date: Mon, 7 Aug 2023 13:00:35 +0800 [thread overview]
Message-ID: <e4d0e004-e436-6a43-17d2-96c0fe4dd551@huawei.com> (raw)
In-Reply-To: <f72991b36d6a449ea5cf476d438bcd1d@realtek.com>
On 2023/8/7 9:42, Ping-Ke Shih wrote:
>
>
>> -----Original Message-----
>> From: Ruan Jinjie <ruanjinjie@huawei.com>
>> Sent: Friday, August 4, 2023 11:54 AM
>> To: sgoutham@marvell.com; davem@davemloft.net; edumazet@google.com; kuba@kernel.org; pabeni@redhat.com;
>> jesse.brandeburg@intel.com; anthony.l.nguyen@intel.com; tariqt@nvidia.com; s.shtylyov@omp.ru;
>> aspriel@gmail.com; franky.lin@broadcom.com; hante.meuleman@broadcom.com; kvalo@kernel.org;
>> richardcochran@gmail.com; yoshihiro.shimoda.uh@renesas.com; ruanjinjie@huawei.com;
>> u.kleine-koenig@pengutronix.de; mkl@pengutronix.de; lee@kernel.org; set_pte_at@outlook.com;
>> linux-arm-kernel@lists.infradead.org; netdev@vger.kernel.org; intel-wired-lan@lists.osuosl.org;
>> linux-rdma@vger.kernel.org; linux-renesas-soc@vger.kernel.org; linux-wireless@vger.kernel.org;
>> brcm80211-dev-list.pdl@broadcom.com; SHA-cyfmac-dev-list@infineon.com
>> Subject: [PATCH -next 6/6] brcm80211: Remove an unnecessary ternary operator
>>
>> There is a ternary operator, the true or false judgement of which
>> is unnecessary in C language semantics.
>>
>> Signed-off-by: Ruan Jinjie <ruanjinjie@huawei.com>
>> ---
>> drivers/net/wireless/broadcom/brcm80211/brcmsmac/phy/phy_n.c | 3 +--
>> 1 file changed, 1 insertion(+), 2 deletions(-)
>>
>> diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmsmac/phy/phy_n.c
>> b/drivers/net/wireless/broadcom/brcm80211/brcmsmac/phy/phy_n.c
>> index 8580a2754789..8328b22829c5 100644
>> --- a/drivers/net/wireless/broadcom/brcm80211/brcmsmac/phy/phy_n.c
>> +++ b/drivers/net/wireless/broadcom/brcm80211/brcmsmac/phy/phy_n.c
>> @@ -27351,8 +27351,7 @@ static int wlc_phy_cal_rxiq_nphy_rev3(struct brcms_phy *pi,
>>
>> for (rx_core = 0; rx_core < pi->pubpi.phy_corenum; rx_core++) {
>>
>> - skip_rxiqcal =
>> - ((rxcore_state & (1 << rx_core)) == 0) ? true : false;
>> + skip_rxiqcal = (rxcore_state & (1 << rx_core)) == 0;
>
> skip_rxiqcal = !(rxcore_state & (1 << rx_core));
Thank you! I'll improve it sooner.
>
>>
>> wlc_phy_rxcal_physetup_nphy(pi, rx_core);
>>
>> --
>> 2.34.1
>>
>>
>> ------Please consider the environment before printing this e-mail.
>
next prev parent reply other threads:[~2023-08-07 5:00 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-04 3:53 [PATCH -next 0/6] net: Remove unnecessary ternary operators Ruan Jinjie
2023-08-04 3:53 ` [PATCH -next 1/6] net: thunderx: " Ruan Jinjie
2023-08-07 1:39 ` Ping-Ke Shih
2023-08-07 4:59 ` Ruan Jinjie
2023-08-07 17:34 ` Jacob Keller
2023-08-04 3:53 ` [PATCH -next 2/6] ethernet/intel: " Ruan Jinjie
2023-08-07 17:35 ` Jacob Keller
2023-08-04 3:53 ` [PATCH -next 3/6] net/mlx4: Remove an unnecessary ternary operator Ruan Jinjie
2023-08-07 1:41 ` Ping-Ke Shih
2023-08-07 5:00 ` Ruan Jinjie
2023-08-04 3:53 ` [PATCH -next 4/6] net: ethernet: renesas: rswitch: " Ruan Jinjie
2023-08-04 3:53 ` [PATCH -next 5/6] net: fjes: " Ruan Jinjie
2023-08-04 3:53 ` [PATCH -next 6/6] brcm80211: " Ruan Jinjie
2023-08-07 1:42 ` Ping-Ke Shih
2023-08-07 5:00 ` Ruan Jinjie [this message]
2023-08-04 20:17 ` [PATCH -next 0/6] net: Remove unnecessary ternary operators Jakub Kicinski
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=e4d0e004-e436-6a43-17d2-96c0fe4dd551@huawei.com \
--to=ruanjinjie@huawei.com \
--cc=SHA-cyfmac-dev-list@infineon.com \
--cc=anthony.l.nguyen@intel.com \
--cc=aspriel@gmail.com \
--cc=brcm80211-dev-list.pdl@broadcom.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=franky.lin@broadcom.com \
--cc=hante.meuleman@broadcom.com \
--cc=intel-wired-lan@lists.osuosl.org \
--cc=jesse.brandeburg@intel.com \
--cc=kuba@kernel.org \
--cc=kvalo@kernel.org \
--cc=lee@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-rdma@vger.kernel.org \
--cc=linux-renesas-soc@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=mkl@pengutronix.de \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=pkshih@realtek.com \
--cc=richardcochran@gmail.com \
--cc=s.shtylyov@omp.ru \
--cc=set_pte_at@outlook.com \
--cc=sgoutham@marvell.com \
--cc=tariqt@nvidia.com \
--cc=u.kleine-koenig@pengutronix.de \
--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;
as well as URLs for NNTP newsgroup(s).