ath10k.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Arend Van Spriel <arend.vanspriel@broadcom.com>
To: Wen Gong <wgong@codeaurora.org>,
	Johannes Berg <johannes@sipsolutions.net>
Cc: Johannes Berg <johannes.berg@intel.com>,
	kirtika@google.com, linux-wireless-owner@vger.kernel.org,
	linux-wireless@vger.kernel.org, ath10k@lists.infradead.org,
	ath11k@lists.infradead.org
Subject: Re: [PATCH v2] mac80211: reject/clear user rate mask if not usable
Date: Thu, 12 Nov 2020 13:49:41 +0100	[thread overview]
Message-ID: <5decc452-7b2a-db1d-c5eb-04ab6bb61553@broadcom.com> (raw)
In-Reply-To: <07179008e9369bc81e152009ca85191d@codeaurora.org>


[-- Attachment #1.1: Type: text/plain, Size: 1347 bytes --]

On 11/12/2020 11:55 AM, Wen Gong wrote:
> On 2017-03-08 21:20, Johannes Berg wrote:
>> From: Johannes Berg <johannes.berg@intel.com>
>>

[...]

>> @@ -2685,6 +2686,21 @@ static int ieee80211_set_bitrate_mask(struct
>> wiphy *wiphy,
>>              return ret;
>>      }
>>
>> +    /*
>> +     * If active validate the setting and reject it if it doesn't leave
>> +     * at least one basic rate usable, since we really have to be able
>> +     * to send something, and if we're an AP we have to be able to do
>> +     * so at a basic rate so that all clients can receive it.
>> +     */
>> +    if (rcu_access_pointer(sdata->vif.chanctx_conf) &&
>> +        sdata->vif.bss_conf.chandef.chan) {
>> +        u32 basic_rates = sdata->vif.bss_conf.basic_rates;
>> +        enum nl80211_band band = sdata->vif.bss_conf.chandef.chan->band;
>> +
>> +        if (!(mask->control[band].legacy & basic_rates))
>> +            return -EINVAL;
> If user want to use “iw wlan0 set bitrates legacy-5 54” to set it to 
> fixed in 54M and 54M is
> not basic rate in AP's becaon as example of below, then the iw command 
> will fail.

Which was the intent of this change, wasn't it? You want to allow anyway 
or you want a clear error message as to why it fails?

Regards,
Arend

[-- Attachment #1.2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 4176 bytes --]

[-- Attachment #2: Type: text/plain, Size: 146 bytes --]

_______________________________________________
ath10k mailing list
ath10k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath10k

  reply	other threads:[~2020-11-12 12:49 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20170308132022.4216-1-johannes@sipsolutions.net>
2020-11-12 10:55 ` [PATCH v2] mac80211: reject/clear user rate mask if not usable Wen Gong
2020-11-12 12:49   ` Arend Van Spriel [this message]
2020-11-13  2:08     ` Wen Gong
2020-11-13  7:38       ` Johannes Berg
2020-11-13  8:14         ` Wen Gong
2020-11-13  8:16           ` Johannes Berg
2020-11-13  8:35             ` Wen Gong
2020-11-13  8:35               ` Johannes Berg
2020-11-13  8:51                 ` Wen Gong
2020-11-13  8:51                   ` Johannes Berg
2020-11-13  9:09                     ` Wen Gong
2020-11-13  9:10                       ` Johannes Berg
2020-11-13  9:21                         ` Wen Gong
2020-11-13  9:23                           ` 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=5decc452-7b2a-db1d-c5eb-04ab6bb61553@broadcom.com \
    --to=arend.vanspriel@broadcom.com \
    --cc=ath10k@lists.infradead.org \
    --cc=ath11k@lists.infradead.org \
    --cc=johannes.berg@intel.com \
    --cc=johannes@sipsolutions.net \
    --cc=kirtika@google.com \
    --cc=linux-wireless-owner@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=wgong@codeaurora.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).