Commit 1bf947a7 authored by Amitkumar Karwar's avatar Amitkumar Karwar Committed by John W. Linville

mwifiex: remove rfc1042_eth_hdr variable

Use 'rfc1042_header' available in net/wireless/util.c
Signed-off-by: default avatarAmitkumar Karwar <akarwar@marvell.com>
Signed-off-by: default avatarBing Zhao <bzhao@marvell.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent a6efc5b7
...@@ -88,15 +88,14 @@ int mwifiex_process_rx_packet(struct mwifiex_private *priv, ...@@ -88,15 +88,14 @@ int mwifiex_process_rx_packet(struct mwifiex_private *priv,
struct rxpd *local_rx_pd; struct rxpd *local_rx_pd;
int hdr_chop; int hdr_chop;
struct ethhdr *eth_hdr; struct ethhdr *eth_hdr;
u8 rfc1042_eth_hdr[ETH_ALEN] = { 0xaa, 0xaa, 0x03, 0x00, 0x00, 0x00 };
local_rx_pd = (struct rxpd *) (skb->data); local_rx_pd = (struct rxpd *) (skb->data);
rx_pkt_hdr = (void *)local_rx_pd + rx_pkt_hdr = (void *)local_rx_pd +
le16_to_cpu(local_rx_pd->rx_pkt_offset); le16_to_cpu(local_rx_pd->rx_pkt_offset);
if (!memcmp(&rx_pkt_hdr->rfc1042_hdr, if (!memcmp(&rx_pkt_hdr->rfc1042_hdr, rfc1042_header,
rfc1042_eth_hdr, sizeof(rfc1042_eth_hdr))) { sizeof(rfc1042_header))) {
/* /*
* Replace the 803 header and rfc1042 header (llc/snap) with an * Replace the 803 header and rfc1042 header (llc/snap) with an
* EthernetII header, keep the src/dst and snap_type * EthernetII header, keep the src/dst and snap_type
......
...@@ -98,7 +98,6 @@ static void mwifiex_uap_queue_bridged_pkt(struct mwifiex_private *priv, ...@@ -98,7 +98,6 @@ static void mwifiex_uap_queue_bridged_pkt(struct mwifiex_private *priv,
int hdr_chop; int hdr_chop;
struct timeval tv; struct timeval tv;
struct ethhdr *p_ethhdr; struct ethhdr *p_ethhdr;
u8 rfc1042_eth_hdr[ETH_ALEN] = { 0xaa, 0xaa, 0x03, 0x00, 0x00, 0x00 };
uap_rx_pd = (struct uap_rxpd *)(skb->data); uap_rx_pd = (struct uap_rxpd *)(skb->data);
rx_pkt_hdr = (void *)uap_rx_pd + le16_to_cpu(uap_rx_pd->rx_pkt_offset); rx_pkt_hdr = (void *)uap_rx_pd + le16_to_cpu(uap_rx_pd->rx_pkt_offset);
...@@ -112,8 +111,8 @@ static void mwifiex_uap_queue_bridged_pkt(struct mwifiex_private *priv, ...@@ -112,8 +111,8 @@ static void mwifiex_uap_queue_bridged_pkt(struct mwifiex_private *priv,
return; return;
} }
if (!memcmp(&rx_pkt_hdr->rfc1042_hdr, if (!memcmp(&rx_pkt_hdr->rfc1042_hdr, rfc1042_header,
rfc1042_eth_hdr, sizeof(rfc1042_eth_hdr))) { sizeof(rfc1042_header))) {
/* Replace the 803 header and rfc1042 header (llc/snap) with /* Replace the 803 header and rfc1042 header (llc/snap) with
* an Ethernet II header, keep the src/dst and snap_type * an Ethernet II header, keep the src/dst and snap_type
* (ethertype). * (ethertype).
......
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