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 v8 2/2] mac80211:  Support ht-cap over-rides.
Date: Thu, 17 Nov 2011 09:42:27 -0800	[thread overview]
Message-ID: <4EC54783.6070209@candelatech.com> (raw)
In-Reply-To: <1321550703.3997.45.camel@jlt3.sipsolutions.net>

On 11/17/2011 09:25 AM, Johannes Berg wrote:
> On Thu, 2011-11-17 at 09:22 -0800, Ben Greear wrote:
>
>>> We can't, but can't we like assign sdata->ht_caps = sband->ht_caps? Or
>>> maybe even calculate restricted HT caps for both 2.4 and 5 GHz?
>>> Basically what I was thinking is this:
>>
>>> struct sub_if_data {
>>> 	...
>>> 	struct ieee80211_sta_ht_cap ht_cap[num_bands];
>>> 	...
>>> };
>>
>> So we'd have to copy this data from sbands[] upon creation
>> of the interface to make sure it is always initialized?
>> This would allow us to easily support the overrides for
>> non-station interfaces, so I do like that benefit.
>>
>> Can the sbands[] data ever change for any reason once
>> an interface is created?  If not, then probably this is
>> doable.  If it can change, then we are screwed.
>
> I don't think it can change but it's not const (I think?) so drivers
> might do stupid things -- but that would be buggy anyway.

I can imagine someone wanting to poke at a driver to enable/disable
features, but no idea if it is done yet.

>> It seems you are basically wanting to copy the sband[] data
>> local to each interface (sdata), and then we would remove sband from most
>> (or all?) of the method calls that deal with sband->ht_caps?
>
> I guess. Though we still need the band to know which one to use (I'm
> reluctant to say we just need one due to channel switching etc.)
>
>> Looks like quite a bit of code churn, and probably requiring at least two
>> patches:
>>    * Get rid of sband usage by copying the sband data into sdata
>>    * Add the over-ride logic
>
> Yeah. It might be *too much* churn, but that's what I was thinking. If
> you think it's likely too much churn let's go with what you have now,
> there are only a few minor things about it I don't like much.

I would much rather use something similar to my last-posted patch.  I
think it is a lot less risky than rewriting all of the sband usage.

I'll rebase against the latest wireless-testing and post a patch
for further review, hopefully later today.

Thanks,
Ben

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


  reply	other threads:[~2011-11-17 17:42 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-08 19:36 [PATCH v8 1/2] wireless: Support ht-capabilities over-rides greearb
2011-11-08 19:36 ` [PATCH v8 2/2] mac80211: Support ht-cap over-rides greearb
2011-11-08 20:09   ` Johannes Berg
2011-11-08 20:44     ` Ben Greear
2011-11-08 20:58       ` Johannes Berg
2011-11-08 21:00         ` Johannes Berg
2011-11-08 21:06         ` Ben Greear
2011-11-08 21:08           ` Johannes Berg
2011-11-08 20:12   ` Johannes Berg
2011-11-08 20:17     ` Johannes Berg
2011-11-08 20:58     ` Ben Greear
2011-11-08 21:02       ` Johannes Berg
2011-11-08 23:11         ` Ben Greear
2011-11-09  8:37           ` Johannes Berg
2011-11-10 19:25         ` Ben Greear
2011-11-17 11:28           ` Johannes Berg
2011-11-17 17:22             ` Ben Greear
2011-11-17 17:25               ` Johannes Berg
2011-11-17 17:42                 ` Ben Greear [this message]
2011-11-08 20:07 ` [PATCH v8 1/2] wireless: Support ht-capabilities over-rides Johannes Berg

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=4EC54783.6070209@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).