linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] iwlwifi: document switch case fall-through in iwl_mvm_send_sta_key
@ 2015-01-12 21:18 John W. Linville
  2015-01-12 21:36 ` Johannes Berg
  2015-01-13  6:00 ` Grumbach, Emmanuel
  0 siblings, 2 replies; 3+ messages in thread
From: John W. Linville @ 2015-01-12 21:18 UTC (permalink / raw)
  To: linux-wireless; +Cc: Emmanuel Grumbach, Kalle Valo, ilw, John W. Linville

Add a comment indicating that the WLAN_CIPHER_SUITE_WEP104 case falls
through to the WLAN_CIPHER_SUITE_WEP40 case in iwl_mvm_send_sta_key.
This will document that the lack of a break is intentional.

Coverity: CID 1260023

Signed-off-by: John W. Linville <linville@tuxdriver.com>
---
This seems to work, so I'm guessing that the fall-through is
intentional...

 drivers/net/wireless/iwlwifi/mvm/sta.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/wireless/iwlwifi/mvm/sta.c b/drivers/net/wireless/iwlwifi/mvm/sta.c
index d86fe432e51f..c0fc4fc0161b 100644
--- a/drivers/net/wireless/iwlwifi/mvm/sta.c
+++ b/drivers/net/wireless/iwlwifi/mvm/sta.c
@@ -1196,6 +1196,7 @@ static int iwl_mvm_send_sta_key(struct iwl_mvm *mvm,
 		break;
 	case WLAN_CIPHER_SUITE_WEP104:
 		key_flags |= cpu_to_le16(STA_KEY_FLG_WEP_13BYTES);
+		/* fall through */
 	case WLAN_CIPHER_SUITE_WEP40:
 		key_flags |= cpu_to_le16(STA_KEY_FLG_WEP);
 		memcpy(cmd.key + 3, keyconf->key, keyconf->keylen);
-- 
2.1.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-01-13  6:00 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-01-12 21:18 [PATCH] iwlwifi: document switch case fall-through in iwl_mvm_send_sta_key John W. Linville
2015-01-12 21:36 ` Johannes Berg
2015-01-13  6:00 ` Grumbach, Emmanuel

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).