From: Felix Fietkau Date: Wed, 11 Jan 2017 14:32:13 +0000 (+0200) Subject: ath5k: drop bogus warning on drv_set_key with unsupported cipher X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=a70e1d6fd6b5e1a81fa6171600942bee34f5128f;p=openwrt%2Fstaging%2Fblogic.git ath5k: drop bogus warning on drv_set_key with unsupported cipher Simply return -EOPNOTSUPP instead. Cc: stable@vger.kernel.org Signed-off-by: Felix Fietkau Signed-off-by: Kalle Valo --- diff --git a/drivers/net/wireless/ath/ath5k/mac80211-ops.c b/drivers/net/wireless/ath/ath5k/mac80211-ops.c index dc44cfef7517..16e052d02c94 100644 --- a/drivers/net/wireless/ath/ath5k/mac80211-ops.c +++ b/drivers/net/wireless/ath/ath5k/mac80211-ops.c @@ -502,8 +502,7 @@ ath5k_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd, break; return -EOPNOTSUPP; default: - WARN_ON(1); - return -EINVAL; + return -EOPNOTSUPP; } mutex_lock(&ah->lock);