aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/tokenring/smctr.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/tokenring/smctr.c')
-rw-r--r--drivers/net/tokenring/smctr.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/net/tokenring/smctr.c b/drivers/net/tokenring/smctr.c
index cec282a6f62d..9bbea5c8acf4 100644
--- a/drivers/net/tokenring/smctr.c
+++ b/drivers/net/tokenring/smctr.c
@@ -3889,14 +3889,13 @@ static int smctr_process_rx_packet(MAC_HEADER *rmf, __u16 size,
3889 3889
3890 /* Slide data into a sleek skb. */ 3890 /* Slide data into a sleek skb. */
3891 skb_put(skb, skb->len); 3891 skb_put(skb, skb->len);
3892 memcpy(skb->data, rmf, skb->len); 3892 skb_copy_to_linear_data(skb, rmf, skb->len);
3893 3893
3894 /* Update Counters */ 3894 /* Update Counters */
3895 tp->MacStat.rx_packets++; 3895 tp->MacStat.rx_packets++;
3896 tp->MacStat.rx_bytes += skb->len; 3896 tp->MacStat.rx_bytes += skb->len;
3897 3897
3898 /* Kick the packet on up. */ 3898 /* Kick the packet on up. */
3899 skb->dev = dev;
3900 skb->protocol = tr_type_trans(skb, dev); 3899 skb->protocol = tr_type_trans(skb, dev);
3901 netif_rx(skb); 3900 netif_rx(skb);
3902 dev->last_rx = jiffies; 3901 dev->last_rx = jiffies;
@@ -4476,14 +4475,13 @@ static int smctr_rx_frame(struct net_device *dev)
4476 if (skb) { 4475 if (skb) {
4477 skb_put(skb, rx_size); 4476 skb_put(skb, rx_size);
4478 4477
4479 memcpy(skb->data, pbuff, rx_size); 4478 skb_copy_to_linear_data(skb, pbuff, rx_size);
4480 4479
4481 /* Update Counters */ 4480 /* Update Counters */
4482 tp->MacStat.rx_packets++; 4481 tp->MacStat.rx_packets++;
4483 tp->MacStat.rx_bytes += skb->len; 4482 tp->MacStat.rx_bytes += skb->len;
4484 4483
4485 /* Kick the packet on up. */ 4484 /* Kick the packet on up. */
4486 skb->dev = dev;
4487 skb->protocol = tr_type_trans(skb, dev); 4485 skb->protocol = tr_type_trans(skb, dev);
4488 netif_rx(skb); 4486 netif_rx(skb);
4489 dev->last_rx = jiffies; 4487 dev->last_rx = jiffies;