diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2008-01-24 02:06:46 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-28 15:07:12 -0800 |
commit | 79ea13ce07c951bb4d95471e7300baa0f1be9e78 (patch) | |
tree | c0ea320464201854c5d3a222e2dd0d10ae22c95f /drivers/net/mace.c | |
parent | 3e18826c73735eee5fca92584137824d9a387008 (diff) |
NULL noise in drivers/net
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/mace.c')
-rw-r--r-- | drivers/net/mace.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/net/mace.c b/drivers/net/mace.c index 95ebe72f320f..451acdca2a21 100644 --- a/drivers/net/mace.c +++ b/drivers/net/mace.c @@ -409,7 +409,7 @@ static inline void mace_clean_rings(struct mace_data *mp) /* free some skb's */ for (i = 0; i < N_RX_RING; ++i) { - if (mp->rx_bufs[i] != 0) { + if (mp->rx_bufs[i] != NULL) { dev_kfree_skb(mp->rx_bufs[i]); mp->rx_bufs[i] = NULL; } @@ -441,7 +441,7 @@ static int mace_open(struct net_device *dev) cp = mp->rx_cmds; for (i = 0; i < N_RX_RING - 1; ++i) { skb = dev_alloc_skb(RX_BUFLEN + 2); - if (skb == 0) { + if (!skb) { data = dummy_buf; } else { skb_reserve(skb, 2); /* so IP header lands on 4-byte bdry */ @@ -903,7 +903,7 @@ static irqreturn_t mace_rxdma_intr(int irq, void *dev_id) out_le16(&cp->command, DBDMA_STOP); /* got a packet, have a look at it */ skb = mp->rx_bufs[i]; - if (skb == 0) { + if (!skb) { ++dev->stats.rx_dropped; } else if (nb > 8) { data = skb->data; @@ -953,9 +953,9 @@ static irqreturn_t mace_rxdma_intr(int irq, void *dev_id) break; cp = mp->rx_cmds + i; skb = mp->rx_bufs[i]; - if (skb == 0) { + if (!skb) { skb = dev_alloc_skb(RX_BUFLEN + 2); - if (skb != 0) { + if (skb) { skb_reserve(skb, 2); mp->rx_bufs[i] = skb; } |