aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/eepro100.c
diff options
context:
space:
mode:
authorLen Brown <len.brown@intel.com>2005-08-29 17:02:17 -0400
committerLen Brown <len.brown@intel.com>2005-08-29 17:02:17 -0400
commit27a639a92d3289c4851105efcbc2f8b88969194f (patch)
tree09ee327d3ed3e2c40d5dc3b0f6b283477282deec /drivers/net/eepro100.c
parentd395bf12d1ba61437e546eb642f0d7ea666123ff (diff)
parentbf4e70e54cf31dcca48d279c7f7e71328eebe749 (diff)
Auto-update from upstream
Diffstat (limited to 'drivers/net/eepro100.c')
-rw-r--r--drivers/net/eepro100.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/eepro100.c b/drivers/net/eepro100.c
index 1795425f512..8c62ced2c9b 100644
--- a/drivers/net/eepro100.c
+++ b/drivers/net/eepro100.c
@@ -1263,8 +1263,8 @@ speedo_init_rx_ring(struct net_device *dev)
for (i = 0; i < RX_RING_SIZE; i++) {
struct sk_buff *skb;
skb = dev_alloc_skb(PKT_BUF_SZ + sizeof(struct RxFD));
- /* XXX: do we really want to call this before the NULL check? --hch */
- rx_align(skb); /* Align IP on 16 byte boundary */
+ if (skb)
+ rx_align(skb); /* Align IP on 16 byte boundary */
sp->rx_skbuff[i] = skb;
if (skb == NULL)
break; /* OK. Just initially short of Rx bufs. */
@@ -1654,8 +1654,8 @@ static inline struct RxFD *speedo_rx_alloc(struct net_device *dev, int entry)
struct sk_buff *skb;
/* Get a fresh skbuff to replace the consumed one. */
skb = dev_alloc_skb(PKT_BUF_SZ + sizeof(struct RxFD));
- /* XXX: do we really want to call this before the NULL check? --hch */
- rx_align(skb); /* Align IP on 16 byte boundary */
+ if (skb)
+ rx_align(skb); /* Align IP on 16 byte boundary */
sp->rx_skbuff[entry] = skb;
if (skb == NULL) {
sp->rx_ringp[entry] = NULL;