diff options
Diffstat (limited to 'drivers/net/macb.c')
-rw-r--r-- | drivers/net/macb.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/net/macb.c b/drivers/net/macb.c index 9e233f8216a7..0e04f7ac3f2e 100644 --- a/drivers/net/macb.c +++ b/drivers/net/macb.c | |||
@@ -367,9 +367,10 @@ static int macb_rx_frame(struct macb *bp, unsigned int first_frag, | |||
367 | BUG_ON(frag != last_frag); | 367 | BUG_ON(frag != last_frag); |
368 | frag_len = len - offset; | 368 | frag_len = len - offset; |
369 | } | 369 | } |
370 | memcpy(skb->data + offset, | 370 | skb_copy_to_linear_data_offset(skb, offset, |
371 | bp->rx_buffers + (RX_BUFFER_SIZE * frag), | 371 | (bp->rx_buffers + |
372 | frag_len); | 372 | (RX_BUFFER_SIZE * frag)), |
373 | frag_len); | ||
373 | offset += RX_BUFFER_SIZE; | 374 | offset += RX_BUFFER_SIZE; |
374 | bp->rx_ring[frag].addr &= ~MACB_BIT(RX_USED); | 375 | bp->rx_ring[frag].addr &= ~MACB_BIT(RX_USED); |
375 | wmb(); | 376 | wmb(); |