Message ID | 1304467039-7730-14-git-send-email-javier@cozybit.com (mailing list archive) |
---|---|
State | Not Applicable, archived |
Headers | show |
On 2011-05-04 1:57 AM, Javier Cardona wrote: > Mesh beaconing on ath9k was broken by this commit: > > commit 4801416c76a3a355076d6d371c00270dfe332e1c > Author: Ben Greear<greearb@candelatech.com> > Date: Sat Jan 15 19:13:48 2011 +0000 > > This patch assigns the right opmode when the device is used in mesh > mode. > > Reported-by: Fabrice Deyber fabricedeyber@agilemesh.com > Signed-off-by: Javier Cardona<javier@cozybit.com> Any idea why exactly ath9k needs to use this opmode? If I understand the specs correctly, 802.11s does not use distributed beacons like ad-hoc mode, so theoretically it should be fine with using the AP iftype. If beacons don't work at all in this opmode for 802.11s then this patch may just be covering up an underlying bug rather than fixing the real issue. - Felix -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Wed, 2011-05-04 at 16:42 +0200, Felix Fietkau wrote: > On 2011-05-04 1:57 AM, Javier Cardona wrote: > > Mesh beaconing on ath9k was broken by this commit: > > > > commit 4801416c76a3a355076d6d371c00270dfe332e1c > > Author: Ben Greear<greearb@candelatech.com> > > Date: Sat Jan 15 19:13:48 2011 +0000 > > > > This patch assigns the right opmode when the device is used in mesh > > mode. > > > > Reported-by: Fabrice Deyber fabricedeyber@agilemesh.com > > Signed-off-by: Javier Cardona<javier@cozybit.com> > Any idea why exactly ath9k needs to use this opmode? If I understand the > specs correctly, 802.11s does not use distributed beacons like ad-hoc > mode, so theoretically it should be fine with using the AP iftype. > If beacons don't work at all in this opmode for 802.11s then this patch > may just be covering up an underlying bug rather than fixing the real issue. > > - Felix > -- I'd tend to agree. I think the problem is in ath9k_allow_beacon_config with the test about not configuring station vif's when in AP mode. I think it's too restrictive. Maybe something like: * Can not configure station vif's beacon config * while on AP opmode */ if ((sc->sc_ah->opmode == NL80211_IFTYPE_AP) && - (vif->type != NL80211_IFTYPE_AP)) { + ((vif->type == NL80211_IFTYPE_STATION) || + (vif->type == NL80211_IFTYPE_ADHOC))) { Steve -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Wed, May 4, 2011 at 7:42 AM, Felix Fietkau <nbd@openwrt.org> wrote: > On 2011-05-04 1:57 AM, Javier Cardona wrote: >> >> Mesh beaconing on ath9k was broken by this commit: >> >> commit 4801416c76a3a355076d6d371c00270dfe332e1c >> Author: Ben Greear<greearb@candelatech.com> >> Date: Sat Jan 15 19:13:48 2011 +0000 >> >> This patch assigns the right opmode when the device is used in mesh >> mode. >> >> Reported-by: Fabrice Deyber fabricedeyber@agilemesh.com >> Signed-off-by: Javier Cardona<javier@cozybit.com> > > Any idea why exactly ath9k needs to use this opmode? If I understand the > specs correctly, 802.11s does not use distributed beacons like ad-hoc mode, > so theoretically it should be fine with using the AP iftype. > If beacons don't work at all in this opmode for 802.11s then this patch may > just be covering up an underlying bug rather than fixing the real issue. Older versions of the 11s draft let implementers decide whether mesh nodes would beacon in ad-hoc or AP mode. Apparently on ath9k ad-hoc mode was chosen when the earlier mesh draft was implemented. The current version of the draft defines a different beaconing mode specific for mesh. This is very unlikely to change since 11s has already passed sponsor ballot. My suggestion would be to keep using ad-hoc style beaconing in ath9k for mesh and to leave the opmode around for when mesh-specific beaconing is implemented in the driver. But I know little about ath9k. If someone can suggest a better way to "unbreak" mesh beaconing I'll be equally happy. Thanks! Javier -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Wed, 2011-05-04 at 10:13 -0700, Javier Cardona wrote: > The current version of the draft defines a different beaconing mode > specific for mesh. Out of curiosity, what does that mode look like? johannes -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Wed, May 4, 2011 at 10:25 AM, Johannes Berg <johannes@sipsolutions.net> wrote: > On Wed, 2011-05-04 at 10:13 -0700, Javier Cardona wrote: > >> The current version of the draft defines a different beaconing mode >> specific for mesh. > > Out of curiosity, what does that mode look like? Similar to AP mode (fixed beaconing period) but with a mechanism to avoid collisions (Mesh Beaconing Collision Avoidance). Javier -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c index c3dbf26..8fa07aa 100644 --- a/drivers/net/wireless/ath/ath9k/main.c +++ b/drivers/net/wireless/ath/ath9k/main.c @@ -1384,7 +1384,9 @@ static void ath9k_calculate_summary_state(struct ieee80211_hw *hw, ath9k_hw_set_tsfadjust(ah, 0); sc->sc_flags &= ~SC_OP_TSF_RESET; - if (iter_data.nwds + iter_data.nmeshes) + if (iter_data.nmeshes) + ah->opmode = NL80211_IFTYPE_MESH_POINT; + else if (iter_data.nwds) ah->opmode = NL80211_IFTYPE_AP; else if (iter_data.nadhocs) ah->opmode = NL80211_IFTYPE_ADHOC;
Mesh beaconing on ath9k was broken by this commit: commit 4801416c76a3a355076d6d371c00270dfe332e1c Author: Ben Greear <greearb@candelatech.com> Date: Sat Jan 15 19:13:48 2011 +0000 This patch assigns the right opmode when the device is used in mesh mode. Reported-by: Fabrice Deyber fabricedeyber@agilemesh.com Signed-off-by: Javier Cardona <javier@cozybit.com> --- drivers/net/wireless/ath/ath9k/main.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-)