diff options
author | Jiapeng Chong <jiapeng.chong@linux.alibaba.com> | 2021-02-02 13:02:37 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2021-02-06 21:37:37 +0300 |
commit | b91b3a211542bcd69532a8004452d83f499d23cd (patch) | |
tree | 5d8064685903fa663fc36157124d2b73df2e35b9 /drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c | |
parent | c90597bdebb5ff8d410edd8c556a6b5195503ca5 (diff) | |
download | linux-b91b3a211542bcd69532a8004452d83f499d23cd.tar.xz |
dpaa2-eth: Simplify the calculation of variables
Fix the following coccicheck warnings:
./drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c:1651:36-38: WARNING
!A || A && B is equivalent to !A || B.
Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
Acked-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Link: https://lore.kernel.org/r/1612260157-128026-1-git-send-email-jiapeng.chong@linux.alibaba.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c')
-rw-r--r-- | drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c b/drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c index 41e225baf571..c5ceebca8cae 100644 --- a/drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c +++ b/drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c @@ -1660,7 +1660,7 @@ set_cgtd: * CG taildrop threshold, so it won't interfere with it; we also * want frames in non-PFC enabled traffic classes to be kept in check) */ - td.enable = !tx_pause || (tx_pause && pfc); + td.enable = !tx_pause || pfc; if (priv->rx_cgtd_enabled == td.enable) return; |