wifi: rtw88: Fix Sparse warning for rtw8821c_hw_spec
Sparse lists the following: CHECK drivers/net/wireless/realtek/rtw88/rtw8821c.c drivers/net/wireless/realtek/rtw88/rtw8821c.c:1880:22: warning: symbol 'rtw8821c_hw_spec' was not declared. Should it be static? The warning arises because the external declaration for rtw8821c_hw_spec occurs in rtw8821ce.h, which is not included in rtw8821c.h. That line is moved, and the now empty file rtw8821ce.h is deleted. Symbol 'rtw8821c_hw_spec' can be made constant. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@kernel.org> Link: https://lore.kernel.org/r/20220524153716.20450-1-Larry.Finger@lwfinger.net
This commit is contained in:
parent
e36db29cfd
commit
89d8f53ff6
@ -1877,7 +1877,7 @@ static const struct rtw_reg_domain coex_info_hw_regs_8821c[] = {
|
||||
{0x60A, MASKBYTE0, RTW_REG_DOMAIN_MAC8},
|
||||
};
|
||||
|
||||
struct rtw_chip_info rtw8821c_hw_spec = {
|
||||
const struct rtw_chip_info rtw8821c_hw_spec = {
|
||||
.ops = &rtw8821c_ops,
|
||||
.id = RTW_CHIP_TYPE_8821C,
|
||||
.fw_name = "rtw88/rtw8821c_fw.bin",
|
||||
|
@ -84,6 +84,8 @@ _rtw_write32s_mask(struct rtw_dev *rtwdev, u32 addr, u32 mask, u32 data)
|
||||
rtw_write32_mask(rtwdev, addr + 0x200, mask, data);
|
||||
}
|
||||
|
||||
extern const struct rtw_chip_info rtw8821c_hw_spec;
|
||||
|
||||
#define rtw_write32s_mask(rtwdev, addr, mask, data) \
|
||||
do { \
|
||||
BUILD_BUG_ON((addr) < 0xC00 || (addr) >= 0xD00); \
|
||||
|
@ -5,7 +5,7 @@
|
||||
#include <linux/module.h>
|
||||
#include <linux/pci.h>
|
||||
#include "pci.h"
|
||||
#include "rtw8821ce.h"
|
||||
#include "rtw8821c.h"
|
||||
|
||||
static const struct pci_device_id rtw_8821ce_id_table[] = {
|
||||
{
|
||||
|
@ -1,10 +0,0 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */
|
||||
/* Copyright(c) 2018-2019 Realtek Corporation
|
||||
*/
|
||||
|
||||
#ifndef __RTW_8821CE_H_
|
||||
#define __RTW_8821CE_H_
|
||||
|
||||
extern struct rtw_chip_info rtw8821c_hw_spec;
|
||||
|
||||
#endif
|
Loading…
x
Reference in New Issue
Block a user