Linux wireless drivers development
 help / color / mirror / Atom feed
From: Ben Greear <greearb@candelatech.com>
To: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com>,
	"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>
Subject: bug in commit: mac80211: Fix possible sband related NULL pointer de-reference
Date: Fri, 17 Nov 2017 14:30:37 -0800	[thread overview]
Message-ID: <238cb9e7-c78f-66e4-01ed-5fead4f35820@candelatech.com> (raw)

Author: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com>
Date:   Thu Apr 27 12:45:38 2017 +0530

     mac80211: Fix possible sband related NULL pointer de-reference

     Existing API 'ieee80211_get_sdata_band' returns default 2 GHz band even
     if the channel context configuration is NULL. This crashes for chipsets
     which support 5 Ghz alone when it tries to access members of 'sband'.
     Channel context configuration can be NULL in multivif case and when
     channel switch is in progress (or) when it fails. Fix this by replacing
     the API 'ieee80211_get_sdata_band' with  'ieee80211_get_sband' which
     returns a NULL pointer for sband when the channel configuration is NULL.

...

This commit appears to break  sta_set_rate_info_tx on drivers that are not using chantx,
because it calls ieee80211_get_sband, which does a WARN_ON when there is no chantx.

Any idea how to make this work for chandef drivers?

Thanks,
Ben

-- 
Ben Greear <greearb@candelatech.com>
Candela Technologies Inc  http://www.candelatech.com

             reply	other threads:[~2017-11-17 22:30 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-17 22:30 Ben Greear [this message]
2017-11-17 23:09 ` bug in commit: mac80211: Fix possible sband related NULL pointer de-reference Ben Greear

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=238cb9e7-c78f-66e4-01ed-5fead4f35820@candelatech.com \
    --to=greearb@candelatech.com \
    --cc=linux-wireless@vger.kernel.org \
    --cc=mohammed@qti.qualcomm.com \
    /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