2011-06-13 15:39:47

by Mohammed Shafi Shajakhan

[permalink] [raw]
Subject: [RFC] cfg80211: skip checking of SSID for maintaining scan list

From: Mohammed Shafi Shajakhan <[email protected]>

when we connect to hidden SSID AP's we maintain two entries
for the same AP and we update all the parameters for the hidden
SSID entry rather than the associated entry, this is because we
have the SSID check in updating/adding new entries in scanlist.
by skipping the SSID check we will maintain a single entry for
the hidden SSID and also update the associated entry for the
same.
will this break something if I skip SSID check for the sake
of hidden SSID AP's or is there someother IE's I can check for.

Signed-off-by: Mohammed Shafi Shajakhan <[email protected]>
---
net/wireless/scan.c | 11 ++---------
1 files changed, 2 insertions(+), 9 deletions(-)

diff --git a/net/wireless/scan.c b/net/wireless/scan.c
index 7a6c676..eace508 100644
--- a/net/wireless/scan.c
+++ b/net/wireless/scan.c
@@ -348,15 +348,8 @@ static int cmp_bss(struct cfg80211_bss *a,
b->len_information_elements);
}

- r = memcmp(a->bssid, b->bssid, ETH_ALEN);
- if (r)
- return r;
-
- return cmp_ies(WLAN_EID_SSID,
- a->information_elements,
- a->len_information_elements,
- b->information_elements,
- b->len_information_elements);
+ return memcmp(a->bssid, b->bssid, ETH_ALEN);
+
}

struct cfg80211_bss *cfg80211_get_bss(struct wiphy *wiphy,
--
1.7.0.4



2011-06-20 04:53:34

by Mohammed Shafi Shajakhan

[permalink] [raw]
Subject: RE: [RFC] cfg80211: skip checking of SSID for maintaining scan list


________________________________________
From: Johannes Berg [[email protected]]
Sent: 19 June 2011 13:38:49
To: Shajakhan, Mohammed Shafi
Cc: [email protected]
Subject: Re: [RFC] cfg80211: skip checking of SSID for maintaining scan list

On Mon, 2011-06-13 at 21:09 +0530, Mohammed Shafi Shajakhan wrote:
> From: Mohammed Shafi Shajakhan <[email protected]>
>
> when we connect to hidden SSID AP's we maintain two entries
> for the same AP and we update all the parameters for the hidden
> SSID entry rather than the associated entry, this is because we
> have the SSID check in updating/adding new entries in scanlist.
> by skipping the SSID check we will maintain a single entry for
> the hidden SSID and also update the associated entry for the
> same.
> will this break something if I skip SSID check for the sake
> of hidden SSID AP's or is there someother IE's I can check for.

I think this will break the case where there are multiple SSIDs all
hidden on the same BSSID, which is a configuration that some people use.

thanks for your kind review, let me try to find if there is some other way to fix this. if you have any ideas please tell me.

thanks,
shafi


johannes


2011-06-20 06:45:46

by Johannes Berg

[permalink] [raw]
Subject: RE: [RFC] cfg80211: skip checking of SSID for maintaining scan list

On Mon, 2011-06-20 at 04:50 +0000, Shajakhan, Mohammed Shafi wrote:

> > when we connect to hidden SSID AP's we maintain two entries
> > for the same AP and we update all the parameters for the hidden
> > SSID entry rather than the associated entry, this is because we
> > have the SSID check in updating/adding new entries in scanlist.
> > by skipping the SSID check we will maintain a single entry for
> > the hidden SSID and also update the associated entry for the
> > same.
> > will this break something if I skip SSID check for the sake
> > of hidden SSID AP's or is there someother IE's I can check for.
>
> I think this will break the case where there are multiple SSIDs all
> hidden on the same BSSID, which is a configuration that some people use.
>
> thanks for your kind review, let me try to find if there is some other way to fix this. if you have any ideas please tell me.

I'm not sure; I think maybe we need to treat the associated case
differently? In that case, we know what the SSID is we're supposedly
connected to, so we could update that entry.

johannes


2011-06-20 13:43:34

by Mohammed Shafi Shajakhan

[permalink] [raw]
Subject: RE: [RFC] cfg80211: skip checking of SSID for maintaining scan list


________________________________________
From: Johannes Berg [[email protected]]
Sent: 20 June 2011 12:15:41
To: Shajakhan, Mohammed Shafi
Cc: [email protected]
Subject: RE: [RFC] cfg80211: skip checking of SSID for maintaining scan list

On Mon, 2011-06-20 at 04:50 +0000, Shajakhan, Mohammed Shafi wrote:

> > when we connect to hidden SSID AP's we maintain two entries
> > for the same AP and we update all the parameters for the hidden
> > SSID entry rather than the associated entry, this is because we
> > have the SSID check in updating/adding new entries in scanlist.
> > by skipping the SSID check we will maintain a single entry for
> > the hidden SSID and also update the associated entry for the
> > same.
> > will this break something if I skip SSID check for the sake
> > of hidden SSID AP's or is there someother IE's I can check for.
>
> I think this will break the case where there are multiple SSIDs all
> hidden on the same BSSID, which is a configuration that some people use.
>
> thanks for your kind review, let me try to find if there is some other way to fix this. if you have any ideas please tell me.

I'm not sure; I think maybe we need to treat the associated case
differently? In that case, we know what the SSID is we're supposedly
connected to, so we could update that entry.

thanks for your inputs, i will try do that. I can update the parameters not only based on whether the BSS is found, also based on if its an associated entry, however still we maintain an additional entry for the hidden-SSID AP .

thanks,
shafi

johannes


2011-06-19 08:08:51

by Johannes Berg

[permalink] [raw]
Subject: Re: [RFC] cfg80211: skip checking of SSID for maintaining scan list

On Mon, 2011-06-13 at 21:09 +0530, Mohammed Shafi Shajakhan wrote:
> From: Mohammed Shafi Shajakhan <[email protected]>
>
> when we connect to hidden SSID AP's we maintain two entries
> for the same AP and we update all the parameters for the hidden
> SSID entry rather than the associated entry, this is because we
> have the SSID check in updating/adding new entries in scanlist.
> by skipping the SSID check we will maintain a single entry for
> the hidden SSID and also update the associated entry for the
> same.
> will this break something if I skip SSID check for the sake
> of hidden SSID AP's or is there someother IE's I can check for.

I think this will break the case where there are multiple SSIDs all
hidden on the same BSSID, which is a configuration that some people use.

johannes