Search Linux Wireless

Re: [PATCH v3 04/12] wifi: rtlwifi: Add rtl8192du/table.{c,h}

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 3/27/2024 2:30 AM, Ping-Ke Shih wrote:
> On Wed, 2024-03-27 at 11:18 +0200, Kalle Valo wrote:
>>
>> Bitterblue Smith <rtl8821cerfe2@xxxxxxxxx> writes:
>>
>>>>> --- /dev/null
>>>>> +++ b/drivers/net/wireless/realtek/rtlwifi/rtl8192du/table.c
>>>>> @@ -0,0 +1,1675 @@
>>>>> +// SPDX-License-Identifier: GPL-2.0
>>>>> +/* Copyright(c) 2009-2012  Realtek Corporation.*/
>>>>> +
>>>>> +#include <linux/types.h>
>>>>> +
>>>>> +#include "table.h"
>>>>> +
>>>>> +u32 rtl8192du_phy_reg_2tarray[PHY_REG_2T_ARRAYLENGTH] = {
>>>>
>>>> static const ?
>>>>
>>>>> +
>>>>> +u32 rtl8192du_phy_reg_array_pg[PHY_REG_ARRAY_PG_LENGTH] = {
>>>>
>>>> static const ?
>>>>
>>>
>>> I can make them static if I move them to table.h. Only phy.c
>>> includes this header, so that should be fine.
>>
>> Do note that .h files can't contain static variables, otherwise there
>> will be duplicate data.
>>
> 
> Indeed, so these cases should be 'const u32', no need 'static'. 
> 
> 
Or make them static and have accessor functions to return pointers to the tables




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux