Give slow hardware some time to do the TSF sync, to not run into an IBS=
S merging endless loop in some rarely situations.
Version 2 adds a comment.
Version 3: I had forgotten to change the bracket.
diff --git a/net/mac80211/ibss.c b/net/mac80211/ibss.c
index 1bbfc70..ea737bf 100644
--- a/net/mac80211/ibss.c
+++ b/net/mac80211/ibss.c
@@ -332,6 +332,10 @@ static void ieee80211_rx_bss_info(struct ieee80211=
_sub_if_data *sdata,
jiffies);
#endif
=20
+ /* give slow hardware some time to do the TSF sync */
+ if (rx_timestamp < 0x400000)
+ goto put_bss;
+
if (beacon_timestamp > rx_timestamp) {
#ifdef CONFIG_MAC80211_IBSS_DEBUG
printk(KERN_DEBUG "%s: beacon TSF higher than "
--=20
Psssst! Schon vom neuen GMX MultiMessenger geh=F6rt? Der kann`s mit all=
en: http://www.gmx.net/de/go/multimessenger01
On Sun, 2009-02-22 at 00:18 +0100, Alina Friedrichsen wrote:
> Give slow hardware some time to do the TSF sync, to not run into an
> IBSS merging endless loop in some rarely situations.
>
> Version 2 adds a comment.
>
> Version 3: I had forgotten to change the bracket.
>
> diff --git a/net/mac80211/ibss.c b/net/mac80211/ibss.c
> index 1bbfc70..ea737bf 100644
> --- a/net/mac80211/ibss.c
> +++ b/net/mac80211/ibss.c
> @@ -332,6 +332,10 @@ static void ieee80211_rx_bss_info(struct ieee80211_sub_if_data *sdata,
> jiffies);
> #endif
>
> + /* give slow hardware some time to do the TSF sync */
> + if (rx_timestamp < 0x400000)
> + goto put_bss;
Please elaborate on what this does. This uses the assumption that
reset_tsf() makes it start at 0, and that then the hardware won't sync
up until N seconds etc. I'd like that to be spelt out here, rather than
having to think about this when reading the comment.
johannes