linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* WARN_ON message hit on enabling power save.
@ 2009-01-28 16:03 Vivek Natarajan
  2009-01-28 19:59 ` Kalle Valo
  0 siblings, 1 reply; 2+ messages in thread
From: Vivek Natarajan @ 2009-01-28 16:03 UTC (permalink / raw)
  To: kalle.valo; +Cc: linux-wireless

Hello Kalle,

In the function 'ieee80211_master_start_xmit',
ieee80211_stop_queues_by_reason is called and a  ps_disable_work is
queued where wake_queues is called. Can you please clarify me on why the
queues are stopped and started. If at all that needs to be stopped,
wouldn't ieee80211_dynamic_ps_enable_work be a better place to do it?

The issue is  while this ps_disable_work is queued,
netif_subqueue_stopped() is checked in _ieee80211_tx which ultimately
results in a WARN_ON(info->flags & IEEE80211_TX_CTL_AMPDU) in
ieee80211_tx. Please see the code for clarification.

So, while I try to ping after enabling power save, the packets are
dropped due to this warning.
The warning message is not at all related to the issue and hence I feel
that this is an inappropriate place for that WARN_ON. 

The fix for the issue is to remove the stop/start queues if it is not
really needed or the better fix is to remove this inappropriate warning
message. Please clarify me if I'm wrong.


Thanks for your time,
Vivek.

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: WARN_ON message hit on enabling power save.
  2009-01-28 16:03 WARN_ON message hit on enabling power save Vivek Natarajan
@ 2009-01-28 19:59 ` Kalle Valo
  0 siblings, 0 replies; 2+ messages in thread
From: Kalle Valo @ 2009-01-28 19:59 UTC (permalink / raw)
  To: Vivek Natarajan; +Cc: linux-wireless@vger.kernel.org

Vivek Natarajan <vivek.natraj@gmail.com> writes:

> Hello Kalle,

Hi Vivek,

> In the function 'ieee80211_master_start_xmit',
> ieee80211_stop_queues_by_reason is called and a  ps_disable_work is
> queued where wake_queues is called. Can you please clarify me on why the
> queues are stopped and started.

Originally they were in ieee80211_subif_start_xmit() before you moved
them. The reason why added them was to preserve the order of first
disabling IEEE80211_CONF_PS and after that sending the data frames.
Because ieee80211_hw_config() must sleep, I decided to do it in a
workqueue.

> If at all that needs to be stopped, wouldn't
> ieee80211_dynamic_ps_enable_work be a better place to do it?

That's was too late. In that case some of the date frames might have
been already transmitted to the driver before IEEE80211_CONF_PS is
disabled.

> The issue is  while this ps_disable_work is queued,
> netif_subqueue_stopped() is checked in _ieee80211_tx which ultimately
> results in a WARN_ON(info->flags & IEEE80211_TX_CTL_AMPDU) in
> ieee80211_tx. Please see the code for clarification.
>
> So, while I try to ping after enabling power save, the packets are
> dropped due to this warning. The warning message is not at all
> related to the issue and hence I feel that this is an inappropriate
> place for that WARN_ON.
>
> The fix for the issue is to remove the stop/start queues if it is not
> really needed or the better fix is to remove this inappropriate warning
> message. Please clarify me if I'm wrong.

Unfortunately I'm not familiar with the 11n implementation. I will
take a look at this more closely tomorrow and will get back to you.

-- 
Kalle Valo

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-01-28 20:01 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-28 16:03 WARN_ON message hit on enabling power save Vivek Natarajan
2009-01-28 19:59 ` Kalle Valo

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).