linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ben Greear <greearb@candelatech.com>
To: Johannes Berg <johannes@sipsolutions.net>
Cc: linux-wireless@vger.kernel.org
Subject: Re: [PATCH v4 1/2] wireless:  Support ht-capabilities over-rides.
Date: Mon, 07 Nov 2011 09:40:39 -0800	[thread overview]
Message-ID: <4EB81817.9060300@candelatech.com> (raw)
In-Reply-To: <1320656776.3993.21.camel@jlt3.sipsolutions.net>

On 11/07/2011 01:06 AM, Johannes Berg wrote:

>> @@ -537,6 +539,12 @@ int __cfg80211_mlme_assoc(struct cfg80211_registered_device *rdev,
>>   	memcpy(&req.crypto, crypt, sizeof(req.crypto));
>>   	req.use_mfp = use_mfp;
>>   	req.prev_bssid = prev_bssid;
>> +	req.flags = assoc_flags;
>> +	if (ht_capa)
>> +		memcpy(&req.ht_capa, ht_capa, sizeof(req.ht_capa));
>> +	if (ht_capa_mask)
>> +		memcpy(&req.ht_capa_mask, ht_capa_mask,
>> +		       sizeof(req.ht_capa_mask));
>
> I think somewhere here you should mask this mask with the
> ht_capa_mod_mask. That way, you force drivers to advertise a correct
> ht_capa_mod_mask, if you don't do that we will certainly see drivers use
> more of ht_capa than contained in ht_capa_mod_mask. Probably should be a
> helper function since I think you might need it in more places.

This goes back to how hard we want to be on user-space.  If we are lax,
and just ignore settings that are not (yet?) supported by the kernel,
then user-space becomes much easier to make backwards/forwards
compat.  That is my preferred approach.

In order for drivers (I assume you mean mac80211 as a driver)
to support more stuff, then we will have to explicitly add
more code there.  At that point, the ht-capa-mod-mask
will need to be updated to stay in sync.  The mod-mask is going
to live in mac80211 as far as I can tell, it seems valid
to just keep them up to date in that manner and let user-space
be oblivious to the mask *if it prefers*.

If you feel strongly that we need to be very strict with
user-space in this case, then please say so, and I'll quite arguing
and code it up.  It is going to make the hostapd code
more complex, however.


Thanks,
Ben

>
> johannes


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


  parent reply	other threads:[~2011-11-07 17:40 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-04 20:10 [PATCH v4 1/2] wireless: Support ht-capabilities over-rides greearb
2011-11-04 20:10 ` [PATCH v4 2/2] mac80211: Support ht-cap over-rides greearb
2011-11-07  9:13   ` Johannes Berg
2011-11-07 16:19     ` Ben Greear
2011-11-07 17:06       ` Johannes Berg
2011-11-04 21:03 ` [PATCH v4 1/2] wireless: Support ht-capabilities over-rides Johannes Berg
2011-11-07  9:06 ` Johannes Berg
2011-11-07 16:27   ` Ben Greear
2011-11-07 17:02     ` Johannes Berg
2011-11-07 17:40   ` Ben Greear [this message]
2011-11-07 17:42     ` Johannes Berg
2011-11-07 17:45       ` Ben Greear

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=4EB81817.9060300@candelatech.com \
    --to=greearb@candelatech.com \
    --cc=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    /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).