Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 197369
b: refs/heads/master
c: 202cfe1
h: refs/heads/master
i:
  197367: 35988a1
v: v3
  • Loading branch information
Sven Eckelmann authored and Greg Kroah-Hartman committed May 11, 2010
1 parent cb2171a commit 2049d08
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 7 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: 7d02d777d4a7eb551999a35f52480c9ddac3d874
refs/heads/master: 202cfe106012c3917543ed8792be1affc37f107b
18 changes: 12 additions & 6 deletions trunk/drivers/staging/batman-adv/routing.c
Original file line number Diff line number Diff line change
Expand Up @@ -614,6 +614,7 @@ int recv_bat_packet(struct sk_buff *skb,
skb = skb_copy(skb, GFP_ATOMIC);
if (!skb)
return NET_RX_DROP;
ethhdr = (struct ethhdr *)skb_mac_header(skb);
kfree_skb(skb_old);
}

Expand All @@ -639,8 +640,8 @@ static int recv_my_icmp_packet(struct sk_buff *skb)
unsigned long flags;
uint8_t dstaddr[ETH_ALEN];

icmp_packet = (struct icmp_packet *) skb->data;
ethhdr = (struct ethhdr *) skb_mac_header(skb);
icmp_packet = (struct icmp_packet *)skb->data;
ethhdr = (struct ethhdr *)skb_mac_header(skb);

/* add data to device queue */
if (icmp_packet->msg_type != ECHO_REQUEST) {
Expand Down Expand Up @@ -671,7 +672,9 @@ static int recv_my_icmp_packet(struct sk_buff *skb)
skb = skb_copy(skb, GFP_ATOMIC);
if (!skb)
return NET_RX_DROP;
icmp_packet = (struct icmp_packet *) skb->data;

icmp_packet = (struct icmp_packet *)skb->data;
ethhdr = (struct ethhdr *)skb_mac_header(skb);
kfree_skb(skb_old);
}

Expand Down Expand Up @@ -732,6 +735,7 @@ static int recv_icmp_ttl_exceeded(struct sk_buff *skb)
if (!skb)
return NET_RX_DROP;
icmp_packet = (struct icmp_packet *) skb->data;
ethhdr = (struct ethhdr *)skb_mac_header(skb);
kfree_skb(skb_old);
}

Expand Down Expand Up @@ -780,7 +784,7 @@ int recv_icmp_packet(struct sk_buff *skb)
if (!is_my_mac(ethhdr->h_dest))
return NET_RX_DROP;

icmp_packet = (struct icmp_packet *) skb->data;
icmp_packet = (struct icmp_packet *)skb->data;

/* packet for me */
if (is_my_mac(icmp_packet->dst))
Expand Down Expand Up @@ -812,7 +816,8 @@ int recv_icmp_packet(struct sk_buff *skb)
skb = skb_copy(skb, GFP_ATOMIC);
if (!skb)
return NET_RX_DROP;
icmp_packet = (struct icmp_packet *) skb->data;
icmp_packet = (struct icmp_packet *)skb->data;
ethhdr = (struct ethhdr *)skb_mac_header(skb);
kfree_skb(skb_old);
}

Expand Down Expand Up @@ -895,7 +900,8 @@ int recv_unicast_packet(struct sk_buff *skb)
skb = skb_copy(skb, GFP_ATOMIC);
if (!skb)
return NET_RX_DROP;
unicast_packet = (struct unicast_packet *) skb->data;
unicast_packet = (struct unicast_packet *)skb->data;
ethhdr = (struct ethhdr *)skb_mac_header(skb);
kfree_skb(skb_old);
}
/* decrement ttl */
Expand Down

0 comments on commit 2049d08

Please sign in to comment.