Commit bfc8bbf9 authored by Arend van Spriel's avatar Arend van Spriel Committed by John W. Linville

brcmfmac: initialize struct brcmf_fws_info fields before iovar

If iovar to the firmware fails the firmware-signalling module
does a cleanup for which it needs pointer to struct brcmf_pub, which
it gets from struct brcmf_fws_info::drvr. Assign this field before
doing the tlv iovar.
Reviewed-by: default avatarPieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: default avatarPiotr Haber <phaber@broadcom.com>
Reviewed-by: default avatarHante Meuleman <meuleman@broadcom.com>
Signed-off-by: default avatarArend van Spriel <arend@broadcom.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent c3203374
...@@ -919,6 +919,10 @@ int brcmf_fws_init(struct brcmf_pub *drvr) ...@@ -919,6 +919,10 @@ int brcmf_fws_init(struct brcmf_pub *drvr)
goto fail; goto fail;
} }
/* set linkage back */
drvr->fws->drvr = drvr;
drvr->fws->fcmode = fcmode;
/* enable proptxtstatus signaling by default */ /* enable proptxtstatus signaling by default */
rc = brcmf_fil_iovar_int_set(drvr->iflist[0], "tlv", tlv); rc = brcmf_fil_iovar_int_set(drvr->iflist[0], "tlv", tlv);
if (rc < 0) { if (rc < 0) {
...@@ -937,10 +941,6 @@ int brcmf_fws_init(struct brcmf_pub *drvr) ...@@ -937,10 +941,6 @@ int brcmf_fws_init(struct brcmf_pub *drvr)
/* create debugfs file for statistics */ /* create debugfs file for statistics */
brcmf_debugfs_create_fws_stats(drvr, &drvr->fws->stats); brcmf_debugfs_create_fws_stats(drvr, &drvr->fws->stats);
/* set linkage back */
drvr->fws->drvr = drvr;
drvr->fws->fcmode = fcmode;
/* TODO: remove upon feature delivery */ /* TODO: remove upon feature delivery */
brcmf_err("%s bdcv2 tlv signaling [%x]\n", brcmf_err("%s bdcv2 tlv signaling [%x]\n",
drvr->fw_signals ? "enabled" : "disabled", tlv); drvr->fw_signals ? "enabled" : "disabled", tlv);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment