diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2008-01-24 05:06:46 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-28 18:07:12 -0500 |
commit | 79ea13ce07c951bb4d95471e7300baa0f1be9e78 (patch) | |
tree | c0ea320464201854c5d3a222e2dd0d10ae22c95f /drivers/net/wan/lmc | |
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/wan/lmc')
-rw-r--r-- | drivers/net/wan/lmc/lmc_main.c | 6 | ||||
-rw-r--r-- | drivers/net/wan/lmc/lmc_media.c | 8 |
2 files changed, 5 insertions, 9 deletions
diff --git a/drivers/net/wan/lmc/lmc_main.c b/drivers/net/wan/lmc/lmc_main.c index 37c52e131750..6635ecef36e5 100644 --- a/drivers/net/wan/lmc/lmc_main.c +++ b/drivers/net/wan/lmc/lmc_main.c | |||
@@ -491,13 +491,13 @@ int lmc_ioctl (struct net_device *dev, struct ifreq *ifr, int cmd) /*fold00*/ | |||
491 | int pos; | 491 | int pos; |
492 | int timeout = 500000; | 492 | int timeout = 500000; |
493 | 493 | ||
494 | if(xc.data == 0x0){ | 494 | if (!xc.data) { |
495 | ret = -EINVAL; | 495 | ret = -EINVAL; |
496 | break; | 496 | break; |
497 | } | 497 | } |
498 | 498 | ||
499 | data = kmalloc(xc.len, GFP_KERNEL); | 499 | data = kmalloc(xc.len, GFP_KERNEL); |
500 | if(data == 0x0){ | 500 | if (!data) { |
501 | printk(KERN_WARNING "%s: Failed to allocate memory for copy\n", dev->name); | 501 | printk(KERN_WARNING "%s: Failed to allocate memory for copy\n", dev->name); |
502 | ret = -ENOMEM; | 502 | ret = -ENOMEM; |
503 | break; | 503 | break; |
@@ -1643,7 +1643,7 @@ static int lmc_rx (struct net_device *dev) /*fold00*/ | |||
1643 | * just allocate an skb buff and continue. | 1643 | * just allocate an skb buff and continue. |
1644 | */ | 1644 | */ |
1645 | 1645 | ||
1646 | if(skb == 0x0){ | 1646 | if (!skb) { |
1647 | nsb = dev_alloc_skb (LMC_PKT_BUF_SZ + 2); | 1647 | nsb = dev_alloc_skb (LMC_PKT_BUF_SZ + 2); |
1648 | if (nsb) { | 1648 | if (nsb) { |
1649 | sc->lmc_rxq[i] = nsb; | 1649 | sc->lmc_rxq[i] = nsb; |
diff --git a/drivers/net/wan/lmc/lmc_media.c b/drivers/net/wan/lmc/lmc_media.c index c9c878cd5c72..8aa461c941ce 100644 --- a/drivers/net/wan/lmc/lmc_media.c +++ b/drivers/net/wan/lmc/lmc_media.c | |||
@@ -1219,10 +1219,6 @@ lmc_t1_watchdog (lmc_softc_t * const sc) | |||
1219 | static void | 1219 | static void |
1220 | lmc_set_protocol (lmc_softc_t * const sc, lmc_ctl_t * ctl) | 1220 | lmc_set_protocol (lmc_softc_t * const sc, lmc_ctl_t * ctl) |
1221 | { | 1221 | { |
1222 | if (ctl == 0) | 1222 | if (!ctl) |
1223 | { | 1223 | sc->ictl.keepalive_onoff = LMC_CTL_ON; |
1224 | sc->ictl.keepalive_onoff = LMC_CTL_ON; | ||
1225 | |||
1226 | return; | ||
1227 | } | ||
1228 | } | 1224 | } |