summaryrefslogtreecommitdiffstats
path: root/drivers/net/ks8851.c
diff options
context:
space:
mode:
authorJens Axboe <jens.axboe@oracle.com>2010-04-29 09:36:24 +0200
committerJens Axboe <jens.axboe@oracle.com>2010-04-29 09:36:24 +0200
commit7407cf355fdf5500430be966dbbde84a27293bad (patch)
tree922861288ff38558ed721a79653f52b17b13bb95 /drivers/net/ks8851.c
parent6a47dc1418682c83d603b491df1d048f73aa973e (diff)
parent79dba2eaa771c3173957eccfd288e0e0d12e4d3f (diff)
downloadblackbird-obmc-linux-7407cf355fdf5500430be966dbbde84a27293bad.tar.gz
blackbird-obmc-linux-7407cf355fdf5500430be966dbbde84a27293bad.zip
Merge branch 'master' into for-2.6.35
Conflicts: fs/block_dev.c Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'drivers/net/ks8851.c')
-rw-r--r--drivers/net/ks8851.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/drivers/net/ks8851.c b/drivers/net/ks8851.c
index 13cc1ca261d9..9e9f9b349766 100644
--- a/drivers/net/ks8851.c
+++ b/drivers/net/ks8851.c
@@ -722,12 +722,14 @@ static void ks8851_tx_work(struct work_struct *work)
txb = skb_dequeue(&ks->txq);
last = skb_queue_empty(&ks->txq);
- ks8851_wrreg16(ks, KS_RXQCR, ks->rc_rxqcr | RXQCR_SDA);
- ks8851_wrpkt(ks, txb, last);
- ks8851_wrreg16(ks, KS_RXQCR, ks->rc_rxqcr);
- ks8851_wrreg16(ks, KS_TXQCR, TXQCR_METFE);
+ if (txb != NULL) {
+ ks8851_wrreg16(ks, KS_RXQCR, ks->rc_rxqcr | RXQCR_SDA);
+ ks8851_wrpkt(ks, txb, last);
+ ks8851_wrreg16(ks, KS_RXQCR, ks->rc_rxqcr);
+ ks8851_wrreg16(ks, KS_TXQCR, TXQCR_METFE);
- ks8851_done_tx(ks, txb);
+ ks8851_done_tx(ks, txb);
+ }
}
mutex_unlock(&ks->lock);
OpenPOWER on IntegriCloud