linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: Ivan Bezyazychnyy <ivan.bezyazychnyy@gmail.com>
Cc: linux-wireless@vger.kernel.org
Subject: Re: [RFC 1/7] mac80211: mesh power mode indication in QoS frames
Date: Fri, 21 Oct 2011 11:52:47 +0200	[thread overview]
Message-ID: <1319190767.3964.8.camel@jlt3.sipsolutions.net> (raw)
In-Reply-To: <CAG5dHkRULKh90W1MeR3zq+-gpeNUshrHZ0qbKXsW19PMG5enoQ@mail.gmail.com> (sfid-20111021_103637_877411_FF47FAB4)

On Fri, 2011-10-21 at 12:36 +0400, Ivan Bezyazychnyy wrote:

> +/* mesh power save level subfield mask */
> +#define IEEE80211_QOS_CTL_PS_LEVEL      0x0200

That looks like it could use a better name?

> --- a/include/linux/nl80211.h

Why is this in a mac80211 patch?

> --- a/include/net/cfg80211.h
> +++ b/include/net/cfg80211.h
> @@ -765,6 +765,8 @@ struct mesh_config {
>  	u16 dot11MeshMaxPeerLinks;
>  	u8  dot11MeshMaxRetries;
>  	u8  dot11MeshTTL;
> +	/* non-peer mesh power save mode */
> +	u8 power_mode;

Ditto.

> +#ifdef CONFIG_MAC80211_MESH

No ifdefs please. There's no need for these.

>  	ieee80211_set_qos_hdr(sdata, skb);
> +#ifdef CONFIG_MAC80211_MESH
> +	ieee80211_set_mesh_ps_fields(sdata, hdr);
> +#endif /* CONFIG_MAC80211_MESH */

ditto.

>  	/* receiver and we are QoS enabled, use a QoS type frame */
> -	if (wme_sta && local->hw.queues >= 4) {
> +	if ((wme_sta && local->hw.queues >= 4) ||
> +	    (ieee80211_vif_is_mesh(&sdata->vif) &&
> +	     (ieee80211s_get_ps_mode(sdata, &hdr) !=
> +			NL80211_MESH_POWER_ACTIVE))) {
>  		fc |= cpu_to_le16(IEEE80211_STYPE_QOS_DATA);

This should not be necessary.

johannes


  reply	other threads:[~2011-10-21  9:52 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-21  8:36 [RFC 1/7] mac80211: mesh power mode indication in QoS frames Ivan Bezyazychnyy
2011-10-21  9:52 ` Johannes Berg [this message]
2011-10-23 13:10   ` Ivan Bezyazychnyy
2011-10-26  9:57     ` 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=1319190767.3964.8.camel@jlt3.sipsolutions.net \
    --to=johannes@sipsolutions.net \
    --cc=ivan.bezyazychnyy@gmail.com \
    --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).