linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: Lorenzo Bianconi <lorenzo.bianconi83@gmail.com>
Cc: linux-wireless@vger.kernel.org, nbd@openwrt.org,
	thomas@net.t-labs.tu-berlin.de
Subject: Re: [PATCHv3] mac80211: enable TPC through mac80211 stack
Date: Tue, 06 Jan 2015 11:41:34 +0100	[thread overview]
Message-ID: <1420540894.1966.13.camel@sipsolutions.net> (raw)
In-Reply-To: <1419412868-28938-1-git-send-email-lorenzo.bianconi83@gmail.com> (sfid-20141224_102111_602160_7438652E)

On Wed, 2014-12-24 at 10:21 +0100, Lorenzo Bianconi wrote:
> -	list_for_each_entry(sdata, &local->interfaces, list)
> +	list_for_each_entry(sdata, &local->interfaces, list) {
>  		sdata->user_power_level = local->user_power_level;
> +		if (!update_tpc && type != sdata->vif.bss_conf.txpower_type)
> +			update_tpc = true;

Why bother checking - if it's already true then setting it to true won't
matter, and IMHO makes the code easier to read.

I also think "update_tpc" is a bad name - transmit power control is the
actual usage here, but you really mean "update_txp_type" or so.

johannes


  reply	other threads:[~2015-01-06 10:41 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-24  9:21 [PATCHv3] mac80211: enable TPC through mac80211 stack Lorenzo Bianconi
2015-01-06 10:41 ` Johannes Berg [this message]
2015-01-06 16:28   ` Lorenzo Bianconi

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=1420540894.1966.13.camel@sipsolutions.net \
    --to=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    --cc=lorenzo.bianconi83@gmail.com \
    --cc=nbd@openwrt.org \
    --cc=thomas@net.t-labs.tu-berlin.de \
    /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).