Commit b5653b15 authored by Vladimir Oltean's avatar Vladimir Oltean Committed by David S. Miller

net: dsa: tag_sja1105: replace skb_mac_header() with vlan_eth_hdr()

This is a cosmetic patch which consolidates the code to use the helper
function offered by if_vlan.h.
Signed-off-by: default avatarVladimir Oltean <vladimir.oltean@nxp.com>
Reviewed-by: default avatarEric Dumazet <edumazet@google.com>
Reviewed-by: default avatarSimon Horman <simon.horman@corigine.com>
Reviewed-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent f9346f00
...@@ -516,7 +516,7 @@ static bool sja1110_skb_has_inband_control_extension(const struct sk_buff *skb) ...@@ -516,7 +516,7 @@ static bool sja1110_skb_has_inband_control_extension(const struct sk_buff *skb)
static void sja1105_vlan_rcv(struct sk_buff *skb, int *source_port, static void sja1105_vlan_rcv(struct sk_buff *skb, int *source_port,
int *switch_id, int *vbid, u16 *vid) int *switch_id, int *vbid, u16 *vid)
{ {
struct vlan_ethhdr *hdr = (struct vlan_ethhdr *)skb_mac_header(skb); struct vlan_ethhdr *hdr = vlan_eth_hdr(skb);
u16 vlan_tci; u16 vlan_tci;
if (skb_vlan_tag_present(skb)) if (skb_vlan_tag_present(skb))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment