Skip to content

Commit

Permalink
brcm80211: fix error code in brcmf_pcie_exit_download_state()
Browse files Browse the repository at this point in the history
The original code returns 1 on failure and 0 on success but the caller
was expecting an error code on failure.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
  • Loading branch information
Dan Carpenter authored and Kalle Valo committed Nov 30, 2015
1 parent 6d91ff7 commit 7941c21
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c
Original file line number Diff line number Diff line change
Expand Up @@ -609,7 +609,9 @@ static int brcmf_pcie_exit_download_state(struct brcmf_pciedev_info *devinfo,
brcmf_chip_resetcore(core, 0, 0, 0);
}

return !brcmf_chip_set_active(devinfo->ci, resetintr);
if (!brcmf_chip_set_active(devinfo->ci, resetintr))
return -EINVAL;
return 0;
}


Expand Down

0 comments on commit 7941c21

Please sign in to comment.