From: Emmanuel Grumbach Date: Tue, 5 Feb 2013 08:08:35 +0000 (+0200) Subject: iwlwifi: mvm: fix the keyidx assignment X-Git-Tag: v3.9-rc1~139^2~2^2^2~29 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8115efbdc82acc935b54f0a849eb834129ea1fd0;p=pandora-kernel.git iwlwifi: mvm: fix the keyidx assignment Fixes an issue that smatch pointed out: 1118 1119 key_flags = cpu_to_le16(keyconf->keyidx & STA_KEY_FLG_KEYID_MSK); ^^^^^^^^^^^^^^^ This is s8. ^^^^^^^^^^^^^^^^^^^^^ STA_KEY_FLG_KEYID_MSK is 0x300. The result after the bitwise AND is always zero because 0xff & 0x300. Reported-by: Dan Carpenter Signed-off-by: Emmanuel Grumbach Signed-off-by: Johannes Berg --- Reading git-diff-tree failed