]> git.baikalelectronics.ru Git - kernel.git/commit
mac80211: fix channel switch for chanctx-based drivers
authorMichal Kazior <michal.kazior@tieto.com>
Mon, 18 Aug 2014 11:19:09 +0000 (13:19 +0200)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 22 Aug 2014 21:45:49 +0000 (14:45 -0700)
commit20aa03f13d6eeca6e06a6ef5b660e46470e09abc
treefbbdae22f891b0e9eb5fd26abe0890ca2762bd89
parentb40cfb4fc11b9223f0c365a14ad847840a6c1868
mac80211: fix channel switch for chanctx-based drivers

The new_ctx pointer is set only for non-chanctx drivers.  This yielded a
crash for chanctx-based drivers during channel switch finalization:

  BUG: unable to handle kernel NULL pointer dereference at 0000000000000020
  IP: ieee80211_vif_use_reserved_switch+0x71c/0xb00 [mac80211]

Use an adequate chanctx pointer to fix this.

Reported-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
net/mac80211/chan.c