diff options
author | Arend van Spriel <arend@broadcom.com> | 2016-01-05 13:05:48 +0300 |
---|---|---|
committer | Kalle Valo <kvalo@codeaurora.org> | 2016-01-08 11:44:43 +0300 |
commit | 63ce3d5db09324b56b739bfde5704799b0d6fd89 (patch) | |
tree | 35f60de0df82e3f0ed89a52c5aae40a122f458b2 /drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c | |
parent | 4011fc49969019eb5e20824285831d873e885f77 (diff) | |
download | linux-63ce3d5db09324b56b739bfde5704799b0d6fd89.tar.xz |
brcmfmac: use msecs_to_jiffies() in macro definitions
Instead to having macro definition for millisecond timeout have
the definition directly in jiffies. This makes the unit of the
value immediately clear and may result in code that is bit more
compact.
Reviewed-by: Hante Meuleman <meuleman@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c')
-rw-r--r-- | drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c index 3d2d790d3ad6..0480b70e3eb8 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c @@ -191,7 +191,7 @@ static struct brcmf_firmware_mapping brcmf_pcie_fwnames[] = { #define BRCMF_H2D_HOST_D0_INFORM_IN_USE 0x00000008 #define BRCMF_H2D_HOST_D0_INFORM 0x00000010 -#define BRCMF_PCIE_MBDATA_TIMEOUT 2000 +#define BRCMF_PCIE_MBDATA_TIMEOUT msecs_to_jiffies(2000) #define BRCMF_PCIE_CFGREG_STATUS_CMD 0x4 #define BRCMF_PCIE_CFGREG_PM_CSR 0x4C @@ -1885,9 +1885,8 @@ static int brcmf_pcie_pm_enter_D3(struct device *dev) devinfo->mbdata_completed = false; brcmf_pcie_send_mb_data(devinfo, BRCMF_H2D_HOST_D3_INFORM); - wait_event_timeout(devinfo->mbdata_resp_wait, - devinfo->mbdata_completed, - msecs_to_jiffies(BRCMF_PCIE_MBDATA_TIMEOUT)); + wait_event_timeout(devinfo->mbdata_resp_wait, devinfo->mbdata_completed, + BRCMF_PCIE_MBDATA_TIMEOUT); if (!devinfo->mbdata_completed) { brcmf_err("Timeout on response for entering D3 substate\n"); return -EIO; |