From: Thomas Huehn <thomas@net.t-labs.tu-berlin.de>
To: linville@tuxdriver.com
Cc: linux-wireless@vger.kernel.org, ath9k-devel@lists.ath9k.org,
ath5k-devel@lists.ath5k.org, ilw@linux.intel.com,
users@rt2x00.serialmonkey.com, b43-dev@lists.infradead.org,
brcm80211-dev-list@broadcom.com, chunkeey@googlemail.com,
buytenh@wantstofly.org, dsd@gentoo.org, coelho@ti.com,
johannes.berg@intel.com
Subject: [PATCH v3 1/2] mac80211_hwsim: fix possible race condition in usage of info->control.sta & control.vif
Date: Tue, 17 Jul 2012 22:16:13 +0200 [thread overview]
Message-ID: <1342556174-23769-2-git-send-email-thomas@net.t-labs.tu-berlin.de> (raw)
In-Reply-To: <1342556174-23769-1-git-send-email-thomas@net.t-labs.tu-berlin.de>
info->control.sta and control.vif may only be dereferenced during the
drv_tx call otherwise could lead to use-after-free bugs.
Signed-off-by: Thomas Huehn <thomas@net.t-labs.tu-berlin.de>
---
drivers/net/wireless/mac80211_hwsim.c | 5 -----
1 file changed, 5 deletions(-)
diff --git a/drivers/net/wireless/mac80211_hwsim.c b/drivers/net/wireless/mac80211_hwsim.c
index 3f38d84..826ac7b 100644
--- a/drivers/net/wireless/mac80211_hwsim.c
+++ b/drivers/net/wireless/mac80211_hwsim.c
@@ -1540,11 +1540,6 @@ static int hwsim_tx_info_frame_received_nl(struct sk_buff *skb_2,
/* now send back TX status */
txi = IEEE80211_SKB_CB(skb);
- if (txi->control.vif)
- hwsim_check_magic(txi->control.vif);
- if (txi->control.sta)
- hwsim_check_sta_magic(txi->control.sta);
-
ieee80211_tx_info_clear_status(txi);
for (i = 0; i < IEEE80211_TX_MAX_RATES; i++) {
--
1.7.11.1
next prev parent reply other threads:[~2012-07-17 20:16 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-17 20:16 [PATCH v3 0/0] mac80211: Restructure ieee80211_tx_info->control to gain free space along tx-path Thomas Huehn
2012-07-17 20:16 ` Thomas Huehn [this message]
2012-07-17 20:16 ` [PATCH v3 2/2] mac80211: Remove control.sta from struct ieee80211_tx_info and restructure tx-path Thomas Huehn
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=1342556174-23769-2-git-send-email-thomas@net.t-labs.tu-berlin.de \
--to=thomas@net.t-labs.tu-berlin.de \
--cc=ath5k-devel@lists.ath5k.org \
--cc=ath9k-devel@lists.ath9k.org \
--cc=b43-dev@lists.infradead.org \
--cc=brcm80211-dev-list@broadcom.com \
--cc=buytenh@wantstofly.org \
--cc=chunkeey@googlemail.com \
--cc=coelho@ti.com \
--cc=dsd@gentoo.org \
--cc=ilw@linux.intel.com \
--cc=johannes.berg@intel.com \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
--cc=users@rt2x00.serialmonkey.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;
as well as URLs for NNTP newsgroup(s).