public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Luca Coelho <luca@coelho.fi>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Johannes Berg <johannes.berg@intel.com>,
	Emmanuel Grumbach <emmanuel.grumbach@intel.com>,
	Michal Kazior <michal.kazior@tieto.com>,
	Intel Linux Wireless <ilw@linux.intel.com>,
	"John W. Linville" <linville@tuxdriver.com>,
	Linux Wireless List <linux-wireless@vger.kernel.org>,
	Network Development <netdev@vger.kernel.org>
Subject: Re: More wireless problems..
Date: Mon, 18 Aug 2014 11:50:16 +0300	[thread overview]
Message-ID: <1408351816.29649.8.camel@dubbel> (raw)
In-Reply-To: <CA+55aFwUJLZUi4wDKwiX1XAht=H9exmvUD5P_aNHK9=XBSixjA@mail.gmail.com>

Hi Linus,

On Sun, 2014-08-17 at 23:37 -0500, Linus Torvalds wrote:
> On Sun, Aug 17, 2014 at 11:01 PM, Linus Torvalds
> <torvalds@linux-foundation.org> wrote:
> >
> >   BUG: unable to handle kernel NULL pointer dereference at 0000000000000020
> >   IP: ieee80211_vif_use_reserved_switch+0x71c/0xb00 [mac80211]
> 
> Looking at the Code: line and the code generation for that function,
> this *looks* to be this code:
> 
>                         list_del(&sdata->reserved_chanctx_list);
>                         list_move(&sdata->assigned_chanctx_list,
>                                   &new_ctx->assigned_vifs);
>                         sdata->reserved_chanctx = NULL;
> 
> in ieee80211_vif_use_reserved_switch(), where "new_ctx" is NULL, so
> the "list_move()" ends up oopsing. But maybe I screwed up the
> analysis, I don't know the code.
> 
> Looks like that is all-new code introduced by commit 5bcae31d9cb1
> ("mac80211: implement multi-vif in-place reservations")
> 
> And doesn't look at all IWL-specific. Adding Michal Kazior to the list
> of people.

Unfortunately I don't think channel switch on the client side has been
tested very thoroughly yet, from the iwlwifi point of view, we're still
fine-tuning things in the firmware configuration.  So I'd rather disable
channel-switch entirely for iwlwifi.

Probably better to disable it in mac80211, since this oops will probably
happen with other drivers too, since doesn't seem to be iwlwifi related.

I'll sent a patch soon.  Meanwhile, you can apply this directly, to make
the problem go away:

diff --git a/net/mac80211/main.c b/net/mac80211/main.c
index e0ab432..4b8eee8 100644
--- a/net/mac80211/main.c
+++ b/net/mac80211/main.c
@@ -758,6 +758,12 @@ int ieee80211_register_hw(struct ieee80211_hw *hw)
        netdev_features_t feature_whitelist;
        struct cfg80211_chan_def dflt_chandef = {};
 
+       /* The CSA client code is not very stable yet and seems to be
+        * causing trouble.  Disable it for all drivers until
+        * everything has been fixed and tested properly.
+        */
+       hw->flags &= ~IEEE80211_HW_CHANCTX_STA_CSA;
+
        if (hw->flags & IEEE80211_HW_QUEUE_CONTROL &&
            (local->hw.offchannel_tx_hw_queue ==
IEEE80211_INVAL_HW_QUEUE ||
             local->hw.offchannel_tx_hw_queue >= local->hw.queues))

--
Cheers,
Luca.

  reply	other threads:[~2014-08-18  9:18 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-18  4:01 More wireless problems Linus Torvalds
2014-08-18  4:37 ` Linus Torvalds
2014-08-18  8:50   ` Luca Coelho [this message]
2014-08-18 11:19     ` [PATCH] mac80211: fix channel switch for chanctx-based drivers Michal Kazior
2014-08-18 13:40       ` Luca Coelho
2014-08-18 13:53       ` Linus Torvalds
2014-08-18 13:59         ` Luca Coelho
     [not found]       ` <1408360749-10233-1-git-send-email-michal.kazior-++hxYGjEMp0AvxtiuMwx3w@public.gmane.org>
2014-08-18 13:59         ` Linus Torvalds

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=1408351816.29649.8.camel@dubbel \
    --to=luca@coelho.fi \
    --cc=emmanuel.grumbach@intel.com \
    --cc=ilw@linux.intel.com \
    --cc=johannes.berg@intel.com \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linville@tuxdriver.com \
    --cc=michal.kazior@tieto.com \
    --cc=netdev@vger.kernel.org \
    --cc=torvalds@linux-foundation.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