* [PATCH] ath10k: fix aggregated 4addr Rx
@ 2014-07-24 12:36 ` Michal Kazior
0 siblings, 0 replies; 6+ messages in thread
From: Michal Kazior @ 2014-07-24 12:36 UTC (permalink / raw)
To: ath10k; +Cc: Vu Hai NGUYEN, linux-wireless, Michal Kazior
A-MSDU 4addr frames weren't reconstructed properly
and in some cases this resulted in a warning:
br0: received packet on wlan0.sta1 with own address as source address
Since this was only related to A-MSDU it would
trigger when more intense traffic was generated.
Reported-by: Vu Hai NGUYEN <vh.nguyen@actiasodielec.fr>
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
---
drivers/net/wireless/ath/ath10k/htt_rx.c | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git a/drivers/net/wireless/ath/ath10k/htt_rx.c b/drivers/net/wireless/ath/ath10k/htt_rx.c
index 318efc3..a8328f9 100644
--- a/drivers/net/wireless/ath/ath10k/htt_rx.c
+++ b/drivers/net/wireless/ath/ath10k/htt_rx.c
@@ -859,7 +859,7 @@ static void ath10k_htt_rx_amsdu(struct ath10k_htt *htt,
enum rx_msdu_decap_format fmt;
enum htt_rx_mpdu_encrypt_type enctype;
struct ieee80211_hdr *hdr;
- u8 hdr_buf[64], addr[ETH_ALEN], *qos;
+ u8 hdr_buf[64], da[ETH_ALEN], sa[ETH_ALEN], *qos;
unsigned int hdr_len;
rxd = (void *)skb->data - sizeof(*rxd);
@@ -897,10 +897,11 @@ static void ath10k_htt_rx_amsdu(struct ath10k_htt *htt,
skb_trim(skb, skb->len - FCS_LEN);
break;
case RX_MSDU_DECAP_NATIVE_WIFI:
- /* pull decapped header and copy DA */
+ /* pull decapped header and copy SA & DA */
hdr = (struct ieee80211_hdr *)skb->data;
hdr_len = ath10k_htt_rx_nwifi_hdrlen(hdr);
- memcpy(addr, ieee80211_get_DA(hdr), ETH_ALEN);
+ memcpy(da, ieee80211_get_DA(hdr), ETH_ALEN);
+ memcpy(sa, ieee80211_get_SA(hdr), ETH_ALEN);
skb_pull(skb, hdr_len);
/* push original 802.11 header */
@@ -914,8 +915,11 @@ static void ath10k_htt_rx_amsdu(struct ath10k_htt *htt,
qos = ieee80211_get_qos_ctl(hdr);
qos[0] &= ~IEEE80211_QOS_CTL_A_MSDU_PRESENT;
- /* original 802.11 header has a different DA */
- memcpy(ieee80211_get_DA(hdr), addr, ETH_ALEN);
+ /* original 802.11 header has a different DA and in
+ * case of 4addr it may also have different SA
+ */
+ memcpy(ieee80211_get_DA(hdr), da, ETH_ALEN);
+ memcpy(ieee80211_get_SA(hdr), sa, ETH_ALEN);
break;
case RX_MSDU_DECAP_ETHERNET2_DIX:
/* strip ethernet header and insert decapped 802.11
--
1.8.5.3
_______________________________________________
ath10k mailing list
ath10k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath10k
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH] ath10k: fix aggregated 4addr Rx
@ 2014-07-24 12:36 ` Michal Kazior
0 siblings, 0 replies; 6+ messages in thread
From: Michal Kazior @ 2014-07-24 12:36 UTC (permalink / raw)
To: ath10k; +Cc: linux-wireless, Vu Hai NGUYEN, Michal Kazior
A-MSDU 4addr frames weren't reconstructed properly
and in some cases this resulted in a warning:
br0: received packet on wlan0.sta1 with own address as source address
Since this was only related to A-MSDU it would
trigger when more intense traffic was generated.
Reported-by: Vu Hai NGUYEN <vh.nguyen@actiasodielec.fr>
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
---
drivers/net/wireless/ath/ath10k/htt_rx.c | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git a/drivers/net/wireless/ath/ath10k/htt_rx.c b/drivers/net/wireless/ath/ath10k/htt_rx.c
index 318efc3..a8328f9 100644
--- a/drivers/net/wireless/ath/ath10k/htt_rx.c
+++ b/drivers/net/wireless/ath/ath10k/htt_rx.c
@@ -859,7 +859,7 @@ static void ath10k_htt_rx_amsdu(struct ath10k_htt *htt,
enum rx_msdu_decap_format fmt;
enum htt_rx_mpdu_encrypt_type enctype;
struct ieee80211_hdr *hdr;
- u8 hdr_buf[64], addr[ETH_ALEN], *qos;
+ u8 hdr_buf[64], da[ETH_ALEN], sa[ETH_ALEN], *qos;
unsigned int hdr_len;
rxd = (void *)skb->data - sizeof(*rxd);
@@ -897,10 +897,11 @@ static void ath10k_htt_rx_amsdu(struct ath10k_htt *htt,
skb_trim(skb, skb->len - FCS_LEN);
break;
case RX_MSDU_DECAP_NATIVE_WIFI:
- /* pull decapped header and copy DA */
+ /* pull decapped header and copy SA & DA */
hdr = (struct ieee80211_hdr *)skb->data;
hdr_len = ath10k_htt_rx_nwifi_hdrlen(hdr);
- memcpy(addr, ieee80211_get_DA(hdr), ETH_ALEN);
+ memcpy(da, ieee80211_get_DA(hdr), ETH_ALEN);
+ memcpy(sa, ieee80211_get_SA(hdr), ETH_ALEN);
skb_pull(skb, hdr_len);
/* push original 802.11 header */
@@ -914,8 +915,11 @@ static void ath10k_htt_rx_amsdu(struct ath10k_htt *htt,
qos = ieee80211_get_qos_ctl(hdr);
qos[0] &= ~IEEE80211_QOS_CTL_A_MSDU_PRESENT;
- /* original 802.11 header has a different DA */
- memcpy(ieee80211_get_DA(hdr), addr, ETH_ALEN);
+ /* original 802.11 header has a different DA and in
+ * case of 4addr it may also have different SA
+ */
+ memcpy(ieee80211_get_DA(hdr), da, ETH_ALEN);
+ memcpy(ieee80211_get_SA(hdr), sa, ETH_ALEN);
break;
case RX_MSDU_DECAP_ETHERNET2_DIX:
/* strip ethernet header and insert decapped 802.11
--
1.8.5.3
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] ath10k: fix aggregated 4addr Rx
2014-07-24 12:36 ` Michal Kazior
@ 2014-07-29 9:44 ` Kalle Valo
-1 siblings, 0 replies; 6+ messages in thread
From: Kalle Valo @ 2014-07-29 9:44 UTC (permalink / raw)
To: Michal Kazior; +Cc: Vu Hai NGUYEN, linux-wireless, ath10k
Michal Kazior <michal.kazior@tieto.com> writes:
> A-MSDU 4addr frames weren't reconstructed properly
> and in some cases this resulted in a warning:
>
> br0: received packet on wlan0.sta1 with own address as source address
>
> Since this was only related to A-MSDU it would
> trigger when more intense traffic was generated.
>
> Reported-by: Vu Hai NGUYEN <vh.nguyen@actiasodielec.fr>
> Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Thanks, applied.
--
Kalle Valo
_______________________________________________
ath10k mailing list
ath10k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath10k
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] ath10k: fix aggregated 4addr Rx
@ 2014-07-29 9:44 ` Kalle Valo
0 siblings, 0 replies; 6+ messages in thread
From: Kalle Valo @ 2014-07-29 9:44 UTC (permalink / raw)
To: Michal Kazior; +Cc: ath10k, Vu Hai NGUYEN, linux-wireless
Michal Kazior <michal.kazior@tieto.com> writes:
> A-MSDU 4addr frames weren't reconstructed properly
> and in some cases this resulted in a warning:
>
> br0: received packet on wlan0.sta1 with own address as source address
>
> Since this was only related to A-MSDU it would
> trigger when more intense traffic was generated.
>
> Reported-by: Vu Hai NGUYEN <vh.nguyen@actiasodielec.fr>
> Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Thanks, applied.
--
Kalle Valo
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE : [PATCH] ath10k: fix aggregated 4addr Rx
2014-07-24 12:36 ` Michal Kazior
(?)
(?)
@ 2014-07-31 15:49 ` Vu Hai NGUYEN
2014-07-31 17:22 ` Ben Greear
-1 siblings, 1 reply; 6+ messages in thread
From: Vu Hai NGUYEN @ 2014-07-31 15:49 UTC (permalink / raw)
To: Michal Kazior, ath10k@lists.infradead.org
Cc: Patrick CARNEIRO RODRIGUEZ, greearb@candelatech.com
Thank you for the patch. I applied it (manually not automatically, the patch is not based on ath-master branch?)
The warning msg: br0: received packet on wlan0.sta1 with own address as source address disappeared on the console of my AP.
But the performance of my bridged STA (using CT firmware) is still lower than non-bridged STA (10.1-467 firmware).
(520 vs 550 Mbps)
The processor of my AP is not exhausted (about 15-20% idle) but perf top on my bridged STA show that there is this thread: br_fdb_update.
I didn't see it on non-bridged STA, it takes 5% resource of the processor
I look for it on google and this thread is related to the warning message br0:received packet on wlan0.sta1 with own address as source address
Do you guy have any suggestion?
Thanks,
NGUYEN Vu Hai
Acita-Sodielec
Route de Mayres - B.P. 9
12100 St GEORGES DE LUZENCON
FRANCE
________________________________________
De : Michal Kazior [michal.kazior@tieto.com]
Date d'envoi : jeudi 24 juillet 2014 14:36
À : ath10k@lists.infradead.org
Cc : linux-wireless@vger.kernel.org; Vu Hai NGUYEN; Michal Kazior
Objet : [PATCH] ath10k: fix aggregated 4addr Rx
A-MSDU 4addr frames weren't reconstructed properly
and in some cases this resulted in a warning:
br0: received packet on wlan0.sta1 with own address as source address
Since this was only related to A-MSDU it would
trigger when more intense traffic was generated.
Reported-by: Vu Hai NGUYEN <vh.nguyen@actiasodielec.fr>
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
---
drivers/net/wireless/ath/ath10k/htt_rx.c | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git a/drivers/net/wireless/ath/ath10k/htt_rx.c b/drivers/net/wireless/ath/ath10k/htt_rx.c
index 318efc3..a8328f9 100644
--- a/drivers/net/wireless/ath/ath10k/htt_rx.c
+++ b/drivers/net/wireless/ath/ath10k/htt_rx.c
@@ -859,7 +859,7 @@ static void ath10k_htt_rx_amsdu(struct ath10k_htt *htt,
enum rx_msdu_decap_format fmt;
enum htt_rx_mpdu_encrypt_type enctype;
struct ieee80211_hdr *hdr;
- u8 hdr_buf[64], addr[ETH_ALEN], *qos;
+ u8 hdr_buf[64], da[ETH_ALEN], sa[ETH_ALEN], *qos;
unsigned int hdr_len;
rxd = (void *)skb->data - sizeof(*rxd);
@@ -897,10 +897,11 @@ static void ath10k_htt_rx_amsdu(struct ath10k_htt *htt,
skb_trim(skb, skb->len - FCS_LEN);
break;
case RX_MSDU_DECAP_NATIVE_WIFI:
- /* pull decapped header and copy DA */
+ /* pull decapped header and copy SA & DA */
hdr = (struct ieee80211_hdr *)skb->data;
hdr_len = ath10k_htt_rx_nwifi_hdrlen(hdr);
- memcpy(addr, ieee80211_get_DA(hdr), ETH_ALEN);
+ memcpy(da, ieee80211_get_DA(hdr), ETH_ALEN);
+ memcpy(sa, ieee80211_get_SA(hdr), ETH_ALEN);
skb_pull(skb, hdr_len);
/* push original 802.11 header */
@@ -914,8 +915,11 @@ static void ath10k_htt_rx_amsdu(struct ath10k_htt *htt,
qos = ieee80211_get_qos_ctl(hdr);
qos[0] &= ~IEEE80211_QOS_CTL_A_MSDU_PRESENT;
- /* original 802.11 header has a different DA */
- memcpy(ieee80211_get_DA(hdr), addr, ETH_ALEN);
+ /* original 802.11 header has a different DA and in
+ * case of 4addr it may also have different SA
+ */
+ memcpy(ieee80211_get_DA(hdr), da, ETH_ALEN);
+ memcpy(ieee80211_get_SA(hdr), sa, ETH_ALEN);
break;
case RX_MSDU_DECAP_ETHERNET2_DIX:
/* strip ethernet header and insert decapped 802.11
--
1.8.5.3
_______________________________________________
ath10k mailing list
ath10k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath10k
^ permalink raw reply related [flat|nested] 6+ messages in thread* Re: RE : [PATCH] ath10k: fix aggregated 4addr Rx
2014-07-31 15:49 ` RE : " Vu Hai NGUYEN
@ 2014-07-31 17:22 ` Ben Greear
0 siblings, 0 replies; 6+ messages in thread
From: Ben Greear @ 2014-07-31 17:22 UTC (permalink / raw)
To: Vu Hai NGUYEN
Cc: Patrick CARNEIRO RODRIGUEZ, Michal Kazior,
ath10k@lists.infradead.org
On 07/31/2014 08:49 AM, Vu Hai NGUYEN wrote:
> Thank you for the patch. I applied it (manually not automatically, the patch is not based on ath-master branch?)
> The warning msg: br0: received packet on wlan0.sta1 with own address as source address disappeared on the console of my AP.
> But the performance of my bridged STA (using CT firmware) is still lower than non-bridged STA (10.1-467 firmware).
> (520 vs 550 Mbps)
>
> The processor of my AP is not exhausted (about 15-20% idle) but perf top on my bridged STA show that there is this thread: br_fdb_update.
> I didn't see it on non-bridged STA, it takes 5% resource of the processor
> I look for it on google and this thread is related to the warning message br0:received packet on wlan0.sta1 with own address as source address
> Do you guy have any suggestion?
Is there any way at all to make the standard firmware do bridged mode? I am curious if
the slow-down is due to my firmware or to bridging in general...
Thanks,
Ben
--
Ben Greear <greearb@candelatech.com>
Candela Technologies Inc http://www.candelatech.com
_______________________________________________
ath10k mailing list
ath10k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath10k
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2014-07-31 17:22 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-07-24 12:36 [PATCH] ath10k: fix aggregated 4addr Rx Michal Kazior
2014-07-24 12:36 ` Michal Kazior
2014-07-29 9:44 ` Kalle Valo
2014-07-29 9:44 ` Kalle Valo
2014-07-31 15:49 ` RE : " Vu Hai NGUYEN
2014-07-31 17:22 ` Ben Greear
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.