brcm80211: fix error code in brcmf_pcie_exit_download_state()

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>
This commit is contained in:
Dan Carpenter 2015-11-27 16:43:27 +03:00 committed by Kalle Valo
parent 6d91ff7acc
commit 7941c2129a

View File

@ -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;
}