Skip to content

Commit 468952f

Browse files
ArvindYadavCsKalle Valo
authored andcommitted
rtlwifi: rtl8821ae: constify pci_device_id.
pci_device_id are not supposed to change at runtime. All functions working with pci_device_id provided by <linux/pci.h> work with const pci_device_id. So mark the non-const structs as const. File size before: text data bss dec hex filename 2491 960 0 3451 d7b realtek/rtlwifi/rtl8821ae/sw.o File size After adding 'const': text data bss dec hex filename 2587 864 0 3451 d7b realtek/rtlwifi/rtl8821ae/sw.o Signed-off-by: Arvind Yadav <[email protected]> Signed-off-by: Kalle Valo <[email protected]>
1 parent 67f512e commit 468952f

File tree

1 file changed

+1
-1
lines changed
  • drivers/net/wireless/realtek/rtlwifi/rtl8821ae

1 file changed

+1
-1
lines changed

drivers/net/wireless/realtek/rtlwifi/rtl8821ae/sw.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -423,7 +423,7 @@ static const struct rtl_hal_cfg rtl8821ae_hal_cfg = {
423423
.maps[RTL_RC_VHT_RATE_2SS_MCS9] = DESC_RATEVHT2SS_MCS9,
424424
};
425425

426-
static struct pci_device_id rtl8821ae_pci_ids[] = {
426+
static const struct pci_device_id rtl8821ae_pci_ids[] = {
427427
{RTL_PCI_DEVICE(PCI_VENDOR_ID_REALTEK, 0x8812, rtl8821ae_hal_cfg)},
428428
{RTL_PCI_DEVICE(PCI_VENDOR_ID_REALTEK, 0x8821, rtl8821ae_hal_cfg)},
429429
{},

0 commit comments

Comments
 (0)