After create the p2p0 wireless device. When call the cfg80211_conn_work, it will crash cause this function will use wdev->netdev which is invalid, below patch will skip the further operation when get the info if the wireless device is P2P device. please review, thanks. BR /Yanbo From: Yanbo Li <dreamfly281@xxxxxxxxx> Date: Thu, 23 May 2013 11:05:20 +0800 Subject: [PATCH] Add the P2P device condition at cfg80211_conn_work to avoid crash Signed-off-by: Yanbo Li <dreamfly281@xxxxxxxxx> --- net/wireless/sme.c | 6 ++++++ 1 files changed, 6 insertions(+) diff --git a/net/wireless/sme.c b/net/wireless/sme.c index 8019b39..232194c 100644 --- a/net/wireless/sme.c +++ b/net/wireless/sme.c @@ -232,6 +232,12 @@ void cfg80211_conn_work(struct work_struct *work) list_for_each_entry(wdev, &rdev->wdev_list, list) { wdev_lock(wdev); +#ifdef CONFIG_CFG80211_ANDROID_P2P_HACK + if (wdev->iftype == NL80211_IFTYPE_P2P_DEVICE) { + wdev_unlock(wdev); + continue; + } +#endif if (!netif_running(wdev->netdev)) { wdev_unlock(wdev); continue; -- 1.7.9.5 -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html