Browse Source

qcacld-3.0: Check HDD context validity before processing IPA Rx events

qcacld-2.0 to qcacld-3.0 propagation

This fixes a race condition between IPA Rx handler and wlan unloading

Change-Id: I8997d532a92b2708bc48f09badb89fabe1544c87
CRs-fixed: 1059550
Prakash Dhavali 8 years ago
parent
commit
63f8fd65cf
1 changed files with 3 additions and 0 deletions
  1. 3 0
      core/hdd/src/wlan_hdd_ipa.c

+ 3 - 0
core/hdd/src/wlan_hdd_ipa.c

@@ -2756,6 +2756,9 @@ static void __hdd_ipa_w2i_cb(void *priv, enum ipa_dp_evt_type evt,
 
 	hdd_ipa = (struct hdd_ipa_priv *)priv;
 
+	if (!hdd_ipa || wlan_hdd_validate_context(hdd_ipa->hdd_ctx))
+		return;
+
 	switch (evt) {
 	case IPA_RECEIVE:
 		skb = (qdf_nbuf_t) data;