All of lore.kernel.org
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: Chaitanya T K <chaitanya.mgit@gmail.com>
Cc: linux-wireless <linux-wireless@vger.kernel.org>
Subject: Re: [PATCH V3] mac80211: wowlan: suspend: Fix power save state stuck in ACTIVE caused by race between suspend and Tx packet.
Date: Wed, 17 Jun 2015 10:47:50 +0200	[thread overview]
Message-ID: <1434530870.1884.12.camel@sipsolutions.net> (raw)
In-Reply-To: <1433943751-11221-1-git-send-email-chaitanya.mgit@gmail.com> (sfid-20150610_154245_778081_DC26490D)

On Wed, 2015-06-10 at 19:12 +0530, Chaitanya T K wrote:
> From: Chaitanya T K <chaitanya.mgit@gmail.com>
> 
> Background: When wowlan is enabled, the chipset stays in low
> power state maintaining the connection as per the
> mac80211 power save state.
> 
> If suspended during TX in progress, there can be 
> race where the driver is put of of power-save due
> to TX and during suspend dynamic_ps_time is cancelled
> and TX packet is flushed, leaving the driver in ACTIVE
> even after resuming until dynamic_ps_time puts 
> driver back in DOZE. (Which only happens if there
> is another TX).
> 
> This can lead to high power consumption of chipset 
> during (or) after resuming.

I still don't like it. I also don't believe that what you're writing is
actually true. The only problem I can see is that it leads to higher
power consumption *while the system is suspended* - at resume time we
send a packet and thus kick the timers...

I was going to change it to this:

-------
mac80211: ensure powersave is enabled when going to WoWLAN

If the system suspends while the client powersave mechanism
is waiting to suspend due to a previous TX, the system will 
go to sleep with the NIC being awake (active) rather than
in doze mode. Unless the driver handles this, it leads to
excessive power consumption while sleeping.
-------

but I'm not convinced all of this is right.

johannes


  reply	other threads:[~2015-06-17  8:47 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-10 13:42 [PATCH V3] mac80211: wowlan: suspend: Fix power save state stuck in ACTIVE caused by race between suspend and Tx packet Chaitanya T K
2015-06-17  8:47 ` Johannes Berg [this message]
2015-06-17 10:22   ` Krishna Chaitanya
2015-06-17 11:01     ` Johannes Berg
2015-06-17 11:35       ` Krishna Chaitanya
2015-06-17 11:37         ` Johannes Berg
2015-06-17 12:15           ` Krishna Chaitanya
2015-07-17  9:16             ` Johannes Berg
2015-07-17  9:33               ` Krishna Chaitanya

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=1434530870.1884.12.camel@sipsolutions.net \
    --to=johannes@sipsolutions.net \
    --cc=chaitanya.mgit@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.