linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ben Greear <greearb@candelatech.com>
To: Vasanthakumar Thiagarajan <vasanth@atheros.com>
Cc: "linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>,
	"ath9k-devel@lists.ath9k.org" <ath9k-devel@venema.h4ckr.net>
Subject: Re: RFC:  v3: Support multiple STA on same AP with ath9k
Date: Mon, 13 Sep 2010 07:36:30 -0700	[thread overview]
Message-ID: <4C8E36EE.7010007@candelatech.com> (raw)
In-Reply-To: <20100913121428.GA15567@vasanth-laptop>

On 09/13/2010 05:14 AM, Vasanthakumar Thiagarajan wrote:
>>   	/* configure operational mode */
>> diff --git a/drivers/net/wireless/ath/ath9k/recv.c b/drivers/net/wireless/ath/ath9k/recv.c
>> index b32c8f0..4ce4029 100644
>> --- a/drivers/net/wireless/ath/ath9k/recv.c
>> +++ b/drivers/net/wireless/ath/ath9k/recv.c
>> @@ -110,7 +110,6 @@ static void ath_setdefantenna(struct ath_softc *sc, u32 antenna)
>>   static void ath_opmode_init(struct ath_softc *sc)
>>   {
>>   	struct ath_hw *ah = sc->sc_ah;
>> -	struct ath_common *common = ath9k_hw_common(ah);
>>
>>   	u32 rfilt, mfilt[2];
>>
>> @@ -118,9 +117,15 @@ static void ath_opmode_init(struct ath_softc *sc)
>>   	rfilt = ath_calcrxfilter(sc);
>>   	ath9k_hw_setrxfilter(ah, rfilt);
>>
>> -	/* configure bssid mask */
>> -	if (ah->caps.hw_caps&  ATH9K_HW_CAP_BSSIDMASK)
>> -		ath_hw_setbssidmask(common);
>> +	/* configure bssid mask, if ah->hw is configured.
>> +	 * it is NOT configured when mac80211 is calling
>> +	 * ieee80211_do_open, but probably just as well since
>> +	 * this STA isn't in the list yet.
>> +	 */
>> +	if (ah->hw) {
>
> This seems bogus. why a check for hw at this point??. IIRS hw of
> ah is not initialized at all, in that case this would fail always.
> Did you test with these code?

I did test it, and it worked for me.  Maybe we just shouldn't configure
the bssid mask in that method?  When using multiple VIFs, we need to do
the mask properly, and from what I can tell, when this method is called,
we do not have enough information to do that properly.

>
>> +	int avifs = ieee80211_count_sta_atomic(sc->hw);
>
> If your aim here is to get the number of virtual interfaces
> associated to a hw, sc->nvifs should work.

I'll check to see if this will work.

Thanks,
Ben

> --
> 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


-- 
Ben Greear <greearb@candelatech.com>
Candela Technologies Inc  http://www.candelatech.com

  reply	other threads:[~2010-09-13 14:36 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-10 20:07 RFC: v3: Support multiple STA on same AP with ath9k Ben Greear
2010-09-10 21:12 ` Johannes Berg
2010-09-10 21:23   ` Ben Greear
2010-09-10 21:27     ` Johannes Berg
2010-09-13 12:14 ` Vasanthakumar Thiagarajan
2010-09-13 14:36   ` Ben Greear [this message]
2010-09-13 19:23   ` Ben Greear
2010-09-14 13:46     ` Vasanthakumar Thiagarajan
2010-09-14 14:39       ` Ben Greear
2010-09-14 14:44         ` Vasanthakumar Thiagarajan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4C8E36EE.7010007@candelatech.com \
    --to=greearb@candelatech.com \
    --cc=ath9k-devel@venema.h4ckr.net \
    --cc=linux-wireless@vger.kernel.org \
    --cc=vasanth@atheros.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).