Staging driver fix for 5.4-rc5

Here is a single staging driver fix, for the wlan-ng driver, that
 resolves a reported issue.
 
 It is been in linux-next for a while with no reported issues.
 
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 -----BEGIN PGP SIGNATURE-----
 
 iG0EABECAC0WIQT0tgzFv3jCIUoxPcsxR9QN2y37KQUCXbSLUQ8cZ3JlZ0Brcm9h
 aC5jb20ACgkQMUfUDdst+ynO4gCfab1VoWPRVdWZhHyuoujMJzT9Sf8AmwZjjfdq
 Dcdt02eKTe18+jvirVeE
 =0l6i
 -----END PGP SIGNATURE-----

Merge tag 'staging-5.4-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging

Pull staging driver fix from Greg KH:
 "Here is a single staging driver fix, for the wlan-ng driver, that
  resolves a reported issue.

  It is been in linux-next for a while with no reported issues"

* tag 'staging-5.4-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging:
  staging: wlan-ng: fix exit return when sme->key_idx >= NUM_WEPKEYS
This commit is contained in:
Linus Torvalds 2019-10-26 16:36:47 -04:00
commit 228bd62434
1 changed files with 2 additions and 4 deletions

View File

@ -469,10 +469,8 @@ static int prism2_connect(struct wiphy *wiphy, struct net_device *dev,
/* Set the encryption - we only support wep */
if (is_wep) {
if (sme->key) {
if (sme->key_idx >= NUM_WEPKEYS) {
err = -EINVAL;
goto exit;
}
if (sme->key_idx >= NUM_WEPKEYS)
return -EINVAL;
result = prism2_domibset_uint32(wlandev,
DIDMIB_DOT11SMT_PRIVACYTABLE_WEPDEFAULTKEYID,