Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 265742
b: refs/heads/master
c: dcef115
h: refs/heads/master
v: v3
  • Loading branch information
alex.bluesman.smirnov@gmail.com authored and David S. Miller committed Sep 15, 2011
1 parent 9b3e77f commit 7a70822
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 9 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: fa3df928e0878350ab0ddd1453bb85b056c726da
refs/heads/master: dcef1151804257684f65c779fc1c19836ee0196a
17 changes: 9 additions & 8 deletions trunk/net/ieee802154/6lowpan.c
Original file line number Diff line number Diff line change
Expand Up @@ -479,10 +479,10 @@ static int lowpan_skb_deliver(struct sk_buff *skb, struct ipv6hdr *hdr)
int stat = NET_RX_SUCCESS;

new = skb_copy_expand(skb, sizeof(struct ipv6hdr), skb_tailroom(skb),
GFP_KERNEL);
GFP_ATOMIC);
kfree_skb(skb);

if (NULL == new)
if (!new)
return -ENOMEM;

skb_push(new, sizeof(struct ipv6hdr));
Expand All @@ -495,13 +495,14 @@ static int lowpan_skb_deliver(struct sk_buff *skb, struct ipv6hdr *hdr)
rcu_read_lock();
list_for_each_entry_rcu(entry, &lowpan_devices, list)
if (lowpan_dev_info(entry->ldev)->real_dev == new->dev) {
skb = skb_copy(new, GFP_KERNEL);
skb->dev = entry->ldev;
skb = skb_copy(new, GFP_ATOMIC);
if (!skb) {
stat = -ENOMEM;
break;
}

if (in_interrupt())
stat = netif_rx(skb);
else
stat = netif_rx_ni(skb);
skb->dev = entry->ldev;
stat = netif_rx(skb);
}
rcu_read_unlock();

Expand Down

0 comments on commit 7a70822

Please sign in to comment.