aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/irda/irda-usb.c
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2007-03-27 17:55:52 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2007-04-26 01:28:23 -0400
commitd626f62b11e00c16e81e4308ab93d3f13551812a (patch)
treefac4af6ced853755e12fc709d55f0c2bec51265d /drivers/net/irda/irda-usb.c
parent2a123b86e2b242a4a6db990d2851d45e192f88e5 (diff)
[SK_BUFF]: Introduce skb_copy_from_linear_data{_offset}
To clearly state the intent of copying from linear sk_buffs, _offset being a overly long variant but interesting for the sake of saving some bytes. Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'drivers/net/irda/irda-usb.c')
-rw-r--r--drivers/net/irda/irda-usb.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/irda/irda-usb.c b/drivers/net/irda/irda-usb.c
index 6ef375a095f4..0ac240ca905b 100644
--- a/drivers/net/irda/irda-usb.c
+++ b/drivers/net/irda/irda-usb.c
@@ -441,7 +441,7 @@ static int irda_usb_hard_xmit(struct sk_buff *skb, struct net_device *netdev)
441 goto drop; 441 goto drop;
442 } 442 }
443 443
444 memcpy(self->tx_buff + self->header_length, skb->data, skb->len); 444 skb_copy_from_linear_data(skb, self->tx_buff + self->header_length, skb->len);
445 445
446 /* Change setting for next frame */ 446 /* Change setting for next frame */
447 if (self->capability & IUC_STIR421X) { 447 if (self->capability & IUC_STIR421X) {
@@ -902,7 +902,7 @@ static void irda_usb_receive(struct urb *urb)
902 902
903 if(docopy) { 903 if(docopy) {
904 /* Copy packet, so we can recycle the original */ 904 /* Copy packet, so we can recycle the original */
905 memcpy(newskb->data, skb->data, urb->actual_length); 905 skb_copy_from_linear_data(skb, newskb->data, urb->actual_length);
906 /* Deliver this new skb */ 906 /* Deliver this new skb */
907 dataskb = newskb; 907 dataskb = newskb;
908 /* And hook the old skb to the URB 908 /* And hook the old skb to the URB