From 9f135b3d8d6152a19000e637844cc41cda6c5335 Mon Sep 17 00:00:00 2001 From: Dmitry Shmidt Date: Fri, 28 Oct 2011 10:35:37 -0700 Subject: [PATCH] net: wireless: Skip connect warning for CONFIG_CFG80211_ALLOW_RECONNECT Signed-off-by: Dmitry Shmidt --- net/wireless/sme.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/net/wireless/sme.c b/net/wireless/sme.c index 81e674700391..cf4be21236b8 100644 --- a/net/wireless/sme.c +++ b/net/wireless/sme.c @@ -763,9 +763,11 @@ int __cfg80211_connect(struct cfg80211_registered_device *rdev, #ifndef CONFIG_CFG80211_ALLOW_RECONNECT if (wdev->sme_state != CFG80211_SME_IDLE) return -EALREADY; -#endif if (WARN_ON(wdev->connect_keys)) { +#else + if (wdev->connect_keys) { +#endif kfree(wdev->connect_keys); wdev->connect_keys = NULL; } -- 2.34.1