diff options
author | Jesper Juhl <juhl-lkml@dif.dk> | 2005-06-02 13:04:07 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2005-06-02 13:04:07 -0700 |
commit | a2c1aa54746bace5d03cc66521fbf3bb6fb2f916 (patch) | |
tree | 9f9e535060b9a9690c432845a9c6ee3929bef9b2 /drivers/atm/zatm.c | |
parent | 3087e1ff8d64da7b6b527e89d0c0864ab36294b8 (diff) | |
download | op-kernel-dev-a2c1aa54746bace5d03cc66521fbf3bb6fb2f916.zip op-kernel-dev-a2c1aa54746bace5d03cc66521fbf3bb6fb2f916.tar.gz |
[ATM]: [drivers] kill pointless NULL checks and casts before kfree()
Signed-off-by: Jesper Juhl <juhl-lkml@dif.dk>
Signed-off-by: Chas Williams <chas@cmf.nrl.navy.mil>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/atm/zatm.c')
-rw-r--r-- | drivers/atm/zatm.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/drivers/atm/zatm.c b/drivers/atm/zatm.c index 47a8005..8d5e65c 100644 --- a/drivers/atm/zatm.c +++ b/drivers/atm/zatm.c @@ -902,7 +902,7 @@ static void close_tx(struct atm_vcc *vcc) zatm_dev->tx_bw += vcc->qos.txtp.min_pcr; dealloc_shaper(vcc->dev,zatm_vcc->shaper); } - if (zatm_vcc->ring) kfree(zatm_vcc->ring); + kfree(zatm_vcc->ring); } @@ -1339,12 +1339,9 @@ static int __init zatm_start(struct atm_dev *dev) return 0; out: for (i = 0; i < NR_MBX; i++) - if (zatm_dev->mbx_start[i] != 0) - kfree((void *) zatm_dev->mbx_start[i]); - if (zatm_dev->rx_map != NULL) - kfree(zatm_dev->rx_map); - if (zatm_dev->tx_map != NULL) - kfree(zatm_dev->tx_map); + kfree(zatm_dev->mbx_start[i]); + kfree(zatm_dev->rx_map); + kfree(zatm_dev->tx_map); free_irq(zatm_dev->irq, dev); return error; } |