mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-20 13:57:40 +07:00
brcmfmac: fix static checker warning in pmklist handling
The patch fixes a static checker warning: drivers/net/wireless/brcm80211/brcmfmac/cfg80211.c:2965 brcmf_cfg80211_set_pmksa() warn: can 'pmkid_len' be negative? The answer to the question above is likely no so changing its type to unsigned is sufficient. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com> Reviewed-by: Daniel (Deognyoun) Kim <dekim@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
parent
ef16ea32db
commit
c15d789e3c
@ -2932,7 +2932,7 @@ brcmf_update_pmklist(struct net_device *ndev,
|
||||
struct brcmf_cfg80211_pmk_list *pmk_list, s32 err)
|
||||
{
|
||||
int i, j;
|
||||
int pmkid_len;
|
||||
u32 pmkid_len;
|
||||
|
||||
pmkid_len = le32_to_cpu(pmk_list->pmkids.npmkid);
|
||||
|
||||
@ -2960,8 +2960,7 @@ brcmf_cfg80211_set_pmksa(struct wiphy *wiphy, struct net_device *ndev,
|
||||
struct brcmf_if *ifp = netdev_priv(ndev);
|
||||
struct pmkid_list *pmkids = &cfg->pmk_list->pmkids;
|
||||
s32 err = 0;
|
||||
int i;
|
||||
int pmkid_len;
|
||||
u32 pmkid_len, i;
|
||||
|
||||
brcmf_dbg(TRACE, "Enter\n");
|
||||
if (!check_vif_up(ifp->vif))
|
||||
@ -3000,7 +2999,7 @@ brcmf_cfg80211_del_pmksa(struct wiphy *wiphy, struct net_device *ndev,
|
||||
struct brcmf_if *ifp = netdev_priv(ndev);
|
||||
struct pmkid_list pmkid;
|
||||
s32 err = 0;
|
||||
int i, pmkid_len;
|
||||
u32 pmkid_len, i;
|
||||
|
||||
brcmf_dbg(TRACE, "Enter\n");
|
||||
if (!check_vif_up(ifp->vif))
|
||||
|
Loading…
Reference in New Issue
Block a user