aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/wireless/realtek/rtl8xxxu
diff options
context:
space:
mode:
authorGravatar Dan Carpenter <dan.carpenter@linaro.org> 2024-01-31 10:10:07 +0300
committerGravatar Kalle Valo <kvalo@kernel.org> 2024-02-01 12:21:02 +0200
commit17903a283593c1dbf9da041f836004163ca30f7b (patch)
treefdff9f90a7c27de299766e66746141af8cd2c604 /drivers/net/wireless/realtek/rtl8xxxu
parentwifi: rtw89: 8922a: add more fields to beacon H2C command to support multi-links (diff)
downloadlinux-17903a283593c1dbf9da041f836004163ca30f7b.tar.gz
linux-17903a283593c1dbf9da041f836004163ca30f7b.tar.bz2
linux-17903a283593c1dbf9da041f836004163ca30f7b.zip
wifi: rtl8xxxu: fix error messages
The first parameter of WARN_ONCE() is a condition so this code will end up printing the function name instead of the proper message. Fixes: 3ff7a05996f9 ("wifi: rtl8xxxu: support setting bssid register for multiple interfaces") Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org> Reviewed-by: Ping-Ke Shih <pkshih@realtek.com> Signed-off-by: Kalle Valo <kvalo@kernel.org> Link: https://msgid.link/7b144531-a8da-4725-8911-9b614a525a35@moroto.mountain
Diffstat (limited to 'drivers/net/wireless/realtek/rtl8xxxu')
-rw-r--r--drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c
index 3b954c2fe448..bd6fd3120562 100644
--- a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c
+++ b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c
@@ -3593,7 +3593,7 @@ static int rtl8xxxu_set_mac(struct rtl8xxxu_priv *priv, int port_num)
reg = REG_MACID1;
break;
default:
- WARN_ONCE("%s: invalid port_num\n", __func__);
+ WARN_ONCE(1, "%s: invalid port_num\n", __func__);
return -EINVAL;
}
@@ -3618,7 +3618,7 @@ static int rtl8xxxu_set_bssid(struct rtl8xxxu_priv *priv, const u8 *bssid, int p
reg = REG_BSSID1;
break;
default:
- WARN_ONCE("%s: invalid port_num\n", __func__);
+ WARN_ONCE(1, "%s: invalid port_num\n", __func__);
return -EINVAL;
}