diff options
Diffstat (limited to 'net/batman-adv/network-coding.c')
-rw-r--r-- | net/batman-adv/network-coding.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/net/batman-adv/network-coding.c b/net/batman-adv/network-coding.c index e84629ece9b7..0787a34609b9 100644 --- a/net/batman-adv/network-coding.c +++ b/net/batman-adv/network-coding.c | |||
@@ -1245,7 +1245,7 @@ static void batadv_nc_skb_store_before_coding(struct batadv_priv *bat_priv, | |||
1245 | return; | 1245 | return; |
1246 | 1246 | ||
1247 | /* Set the mac header as if we actually sent the packet uncoded */ | 1247 | /* Set the mac header as if we actually sent the packet uncoded */ |
1248 | ethhdr = (struct ethhdr *)skb_mac_header(skb); | 1248 | ethhdr = eth_hdr(skb); |
1249 | memcpy(ethhdr->h_source, ethhdr->h_dest, ETH_ALEN); | 1249 | memcpy(ethhdr->h_source, ethhdr->h_dest, ETH_ALEN); |
1250 | memcpy(ethhdr->h_dest, eth_dst_new, ETH_ALEN); | 1250 | memcpy(ethhdr->h_dest, eth_dst_new, ETH_ALEN); |
1251 | 1251 | ||
@@ -1423,7 +1423,7 @@ void batadv_nc_skb_store_for_decoding(struct batadv_priv *bat_priv, | |||
1423 | { | 1423 | { |
1424 | struct batadv_unicast_packet *packet; | 1424 | struct batadv_unicast_packet *packet; |
1425 | struct batadv_nc_path *nc_path; | 1425 | struct batadv_nc_path *nc_path; |
1426 | struct ethhdr *ethhdr = (struct ethhdr *)skb_mac_header(skb); | 1426 | struct ethhdr *ethhdr = eth_hdr(skb); |
1427 | __be32 packet_id; | 1427 | __be32 packet_id; |
1428 | u8 *payload; | 1428 | u8 *payload; |
1429 | 1429 | ||
@@ -1482,7 +1482,7 @@ out: | |||
1482 | void batadv_nc_skb_store_sniffed_unicast(struct batadv_priv *bat_priv, | 1482 | void batadv_nc_skb_store_sniffed_unicast(struct batadv_priv *bat_priv, |
1483 | struct sk_buff *skb) | 1483 | struct sk_buff *skb) |
1484 | { | 1484 | { |
1485 | struct ethhdr *ethhdr = (struct ethhdr *)skb_mac_header(skb); | 1485 | struct ethhdr *ethhdr = eth_hdr(skb); |
1486 | 1486 | ||
1487 | if (batadv_is_my_mac(bat_priv, ethhdr->h_dest)) | 1487 | if (batadv_is_my_mac(bat_priv, ethhdr->h_dest)) |
1488 | return; | 1488 | return; |
@@ -1533,7 +1533,7 @@ batadv_nc_skb_decode_packet(struct batadv_priv *bat_priv, struct sk_buff *skb, | |||
1533 | skb_reset_network_header(skb); | 1533 | skb_reset_network_header(skb); |
1534 | 1534 | ||
1535 | /* Reconstruct original mac header */ | 1535 | /* Reconstruct original mac header */ |
1536 | ethhdr = (struct ethhdr *)skb_mac_header(skb); | 1536 | ethhdr = eth_hdr(skb); |
1537 | memcpy(ethhdr, ðhdr_tmp, sizeof(*ethhdr)); | 1537 | memcpy(ethhdr, ðhdr_tmp, sizeof(*ethhdr)); |
1538 | 1538 | ||
1539 | /* Select the correct unicast header information based on the location | 1539 | /* Select the correct unicast header information based on the location |
@@ -1677,7 +1677,7 @@ static int batadv_nc_recv_coded_packet(struct sk_buff *skb, | |||
1677 | return NET_RX_DROP; | 1677 | return NET_RX_DROP; |
1678 | 1678 | ||
1679 | coded_packet = (struct batadv_coded_packet *)skb->data; | 1679 | coded_packet = (struct batadv_coded_packet *)skb->data; |
1680 | ethhdr = (struct ethhdr *)skb_mac_header(skb); | 1680 | ethhdr = eth_hdr(skb); |
1681 | 1681 | ||
1682 | /* Verify frame is destined for us */ | 1682 | /* Verify frame is destined for us */ |
1683 | if (!batadv_is_my_mac(bat_priv, ethhdr->h_dest) && | 1683 | if (!batadv_is_my_mac(bat_priv, ethhdr->h_dest) && |