]> www.infradead.org Git - users/willy/linux.git/commit
wifi: brcmfmac: use 'time_left' variable with wait_event_timeout()
authorWolfram Sang <wsa+renesas@sang-engineering.com>
Mon, 3 Jun 2024 09:15:35 +0000 (11:15 +0200)
committerKalle Valo <kvalo@kernel.org>
Wed, 12 Jun 2024 12:01:08 +0000 (15:01 +0300)
commit158d5a1b3caaaeafc838a28a78dc17ceba468fb6
treeb4cb5b5c11b24803aa3b14eb06da097a2996a1bc
parentbbef1d006cb1c2774c4b44eb70441d784d3aef44
wifi: brcmfmac: use 'time_left' variable with wait_event_timeout()

There is a confusing pattern in the kernel to use a variable named 'timeout' to
store the result of wait_event_timeout() causing patterns like:

timeout = wait_event_timeout(...)
if (!timeout) return -ETIMEDOUT;

with all kinds of permutations. Use 'time_left' as a variable to make the code
self explaining.

Fix to the proper variable type 'long' while here.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Acked-by: Arend van Spriel <arend.vanspriel@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://msgid.link/20240603091541.8367-3-wsa+renesas@sang-engineering.com
drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c