diff options
author | Joe Perches <joe@perches.com> | 2015-05-05 19:06:00 +0200 |
---|---|---|
committer | Michael Grzeschik <m.grzeschik@pengutronix.de> | 2015-09-23 08:44:25 +0200 |
commit | d8101e7bec352b7b6a154ec2e428d01bddb7e5b4 (patch) | |
tree | 31d7cf87d1b3ded4ab5754fa9662fdd9641ea656 /drivers/net/arcnet/rfc1201.c | |
parent | arcnet: Remove assignments from ifs (diff) | |
download | linux-d8101e7bec352b7b6a154ec2e428d01bddb7e5b4.tar.xz linux-d8101e7bec352b7b6a154ec2e428d01bddb7e5b4.zip |
arcnet: Remove pointer comparisons to NULL
Use direct tests of pointer instead.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de>
Diffstat (limited to '')
-rw-r--r-- | drivers/net/arcnet/rfc1201.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/arcnet/rfc1201.c b/drivers/net/arcnet/rfc1201.c index 9040a8be155c..1d777c1e8383 100644 --- a/drivers/net/arcnet/rfc1201.c +++ b/drivers/net/arcnet/rfc1201.c @@ -178,7 +178,7 @@ static void rx(struct net_device *dev, int bufnum, in->sequence = soft->sequence; skb = alloc_skb(length + ARC_HDR_SIZE, GFP_ATOMIC); - if (skb == NULL) { + if (!skb) { dev->stats.rx_dropped++; return; } @@ -286,7 +286,7 @@ static void rx(struct net_device *dev, int bufnum, } in->skb = skb = alloc_skb(508 * in->numpackets + ARC_HDR_SIZE, GFP_ATOMIC); - if (skb == NULL) { + if (!skb) { arc_printk(D_NORMAL, dev, "(split) memory squeeze, dropping packet.\n"); lp->rfc1201.aborted_seq = soft->sequence; dev->stats.rx_dropped++; |