summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAishwarya Ramakrishnan <aishwaryarj100@gmail.com>2020-04-27 16:02:30 +0530
committerDavid S. Miller <davem@davemloft.net>2020-04-30 20:26:30 -0700
commit7ae9a4f483eccfd46f40ede8d2bd28fd2f7a9c5f (patch)
treef79bb88240381a256ffc11d2701a225b742eb3f8
parentf256356f65e6449a9fcf6089ea25882c91768665 (diff)
downloadlinux-7ae9a4f483eccfd46f40ede8d2bd28fd2f7a9c5f.tar.gz
linux-7ae9a4f483eccfd46f40ede8d2bd28fd2f7a9c5f.tar.bz2
linux-7ae9a4f483eccfd46f40ede8d2bd28fd2f7a9c5f.zip
dpaa_eth: Fix comparing pointer to 0
Fixes coccicheck warning: ./drivers/net/ethernet/freescale/dpaa/dpaa_eth.c:2110:30-31: WARNING comparing pointer to 0 Avoid pointer type value compared to 0. Signed-off-by: Aishwarya Ramakrishnan <aishwaryarj100@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/ethernet/freescale/dpaa/dpaa_eth.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c b/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
index 2cd1f8efdfa3..c4416a5f8816 100644
--- a/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
+++ b/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
@@ -2107,7 +2107,7 @@ workaround:
/* Workaround for DPAA_A050385 requires data start to be aligned */
start = PTR_ALIGN(new_skb->data, DPAA_A050385_ALIGN);
- if (start - new_skb->data != 0)
+ if (start - new_skb->data)
skb_reserve(new_skb, start - new_skb->data);
skb_put(new_skb, skb->len);