2011-09-15 09:14:13

by Rajkumar Manoharan

[permalink] [raw]
Subject: [RFC] wireless: Fix rate mask for scan request

The scan request received from cfg80211_connect do not
have proper rate mast. So the probe request sent on each
channel do not have proper the supported rates ie.

Cc: [email protected]
Signed-off-by: Rajkumar Manoharan <[email protected]>
---
net/wireless/sme.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/net/wireless/sme.c b/net/wireless/sme.c
index b7b6ff8..8b6ef34 100644
--- a/net/wireless/sme.c
+++ b/net/wireless/sme.c
@@ -118,6 +118,7 @@ static int cfg80211_conn_scan(struct wireless_dev *wdev)
i++, j++)
request->channels[i] =
&wdev->wiphy->bands[band]->channels[j];
+ request->rates[band] = (u32) -1;
}
}
request->n_channels = n_channels;
--
1.7.6.1



2011-09-15 09:19:21

by Johannes Berg

[permalink] [raw]
Subject: Re: [RFC] wireless: Fix rate mask for scan request

On Thu, 2011-09-15 at 14:44 +0530, Rajkumar Manoharan wrote:
> The scan request received from cfg80211_connect do not
> have proper rate mast. So the probe request sent on each
> channel do not have proper the supported rates ie.
>
> Cc: [email protected]
> Signed-off-by: Rajkumar Manoharan <[email protected]>
> ---
> net/wireless/sme.c | 1 +
> 1 files changed, 1 insertions(+), 0 deletions(-)
>
> diff --git a/net/wireless/sme.c b/net/wireless/sme.c
> index b7b6ff8..8b6ef34 100644
> --- a/net/wireless/sme.c
> +++ b/net/wireless/sme.c
> @@ -118,6 +118,7 @@ static int cfg80211_conn_scan(struct wireless_dev *wdev)
> i++, j++)
> request->channels[i] =
> &wdev->wiphy->bands[band]->channels[j];
> + request->rates[band] = (u32) -1;

Please use
(1 << wiphy->bands[band]->n_bitrates) - 1;

so we don't have invalid bits set.

Also, CC stable doesn't work that way -- you don't CC them, you just
write into it "Cc: [email protected]". This makes them pick out the
patch later once it got applied.

johannes


2011-09-15 09:19:56

by Johannes Berg

[permalink] [raw]
Subject: Re: [RFC] wireless: Fix rate mask for scan request

On Thu, 2011-09-15 at 11:19 +0200, Johannes Berg wrote:

> Also, CC stable doesn't work that way -- you don't CC them, you just
> write into it "Cc: [email protected]". This makes them pick out the
> patch later once it got applied.

Never mind, I see you did do it that way, I guess git just picked it up
and sent a copy too.

johannes