Skip to contentSkip to conversation

rtw88: fix compile warning: [-Wignored-qualifiers]

PATCH In review [email protected] 2 participants 2 messages Sep 2, 2020 – Sep 7, 2020 Realtek wireless driver (rtw88)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 rtw88: fix compile warning: [-Wignored-qualifiers]

From: Tzu-En Huang <[email protected]>

Remove function return type const in rtw8821c_get_swing_index(). This is unused, and unnecessary to be const.

All warnings (new ones prefixed by >>):

Quoted 1 line
Quoted 1 line

drivers/net/wireless/realtek/rtw88/rtw8821c.c:71:8: warning: type

qualifiers ignored on function return type [-Wignored-qualifiers]
71 | static const u8 rtw8821c_get_swing_index(struct rtw_dev *rtwdev)
| ^~~~~

Fixes f745eb9ca5bf ("rtw88: 8821c: Add 8821CE to Kconfig and Makefile")
---
 drivers/net/wireless/realtek/rtw88/rtw8821c.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/wireless/realtek/rtw88/rtw8821c.c +1 -1
index d8863d8a5468..da2e7415be8f 100644
@@ -68,7 +68,7 @@ static const u32 rtw8821c_txscale_tbl[] = {
 	0x2d3, 0x2fe, 0x32b, 0x35c, 0x38e, 0x3c4, 0x3fe
 };
 
-static const u8 rtw8821c_get_swing_index(struct rtw_dev *rtwdev)
+static u8 rtw8821c_get_swing_index(struct rtw_dev *rtwdev)
 {
 	u8 i = 0;
 	u32 swing, table_value;
Signature · 1 line
2.17.1
#1 lore raw
Quoted 8 lines · <[email protected]> wrote:

From: Tzu-En Huang <[email protected]>

Remove function return type const in rtw8821c_get_swing_index(). This is unused, and unnecessary to be const.

All warnings (new ones prefixed by >>):

Quoted 1 line
Quoted 1 line

drivers/net/wireless/realtek/rtw88/rtw8821c.c:71:8: warning: type

Quoted 8 lines

qualifiers ignored on function return type [-Wignored-qualifiers]
71 | static const u8 rtw8821c_get_swing_index(struct rtw_dev *rtwdev)
| ^~~~~

Fixes f745eb9ca5bf ("rtw88: 8821c: Add 8821CE to Kconfig and Makefile")

Patch applied to wireless-drivers-next.git, thanks.

8f8b8aa62e68 rtw88: fix compile warning: [-Wignored-qualifiers]

Signature · 3 lines
https://patchwork.kernel.org/patch/11749861/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches