From 9dcc451664e5a671793453aa39a9ddfd896438fc Mon Sep 17 00:00:00 2001 From: Jiri Slaby Date: Apr 20 2023 11:00:43 +0000 Subject: wifi: mwifiex: mark OF related data as maybe unused (bsc#1012628). --- diff --git a/patches.kernel.org/6.2.12-082-wifi-mwifiex-mark-OF-related-data-as-maybe-unu.patch b/patches.kernel.org/6.2.12-082-wifi-mwifiex-mark-OF-related-data-as-maybe-unu.patch new file mode 100644 index 0000000..40f6f2c --- /dev/null +++ b/patches.kernel.org/6.2.12-082-wifi-mwifiex-mark-OF-related-data-as-maybe-unu.patch @@ -0,0 +1,58 @@ +From: Krzysztof Kozlowski +Date: Sun, 12 Mar 2023 14:25:23 +0100 +Subject: [PATCH] wifi: mwifiex: mark OF related data as maybe unused +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit +References: bsc#1012628 +Patch-mainline: 6.2.12 +Git-commit: 139f6973bf140c65d4d1d4bde5485badb4454d7a + +[ Upstream commit 139f6973bf140c65d4d1d4bde5485badb4454d7a ] + +The driver can be compile tested with !CONFIG_OF making certain data +unused: + + drivers/net/wireless/marvell/mwifiex/sdio.c:498:34: error: ‘mwifiex_sdio_of_match_table’ defined but not used [-Werror=unused-const-variable=] + drivers/net/wireless/marvell/mwifiex/pcie.c:175:34: error: ‘mwifiex_pcie_of_match_table’ defined but not used [-Werror=unused-const-variable=] + +Signed-off-by: Krzysztof Kozlowski +Reviewed-by: Simon Horman +Signed-off-by: Kalle Valo +Link: https://lore.kernel.org/r/20230312132523.352182-1-krzysztof.kozlowski@linaro.org +Signed-off-by: Sasha Levin +Signed-off-by: Jiri Slaby +--- + drivers/net/wireless/marvell/mwifiex/pcie.c | 2 +- + drivers/net/wireless/marvell/mwifiex/sdio.c | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/drivers/net/wireless/marvell/mwifiex/pcie.c b/drivers/net/wireless/marvell/mwifiex/pcie.c +index 5dcf6176..9a698a16 100644 +--- a/drivers/net/wireless/marvell/mwifiex/pcie.c ++++ b/drivers/net/wireless/marvell/mwifiex/pcie.c +@@ -172,7 +172,7 @@ static const struct mwifiex_pcie_device mwifiex_pcie8997 = { + .can_ext_scan = true, + }; + +-static const struct of_device_id mwifiex_pcie_of_match_table[] = { ++static const struct of_device_id mwifiex_pcie_of_match_table[] __maybe_unused = { + { .compatible = "pci11ab,2b42" }, + { .compatible = "pci1b4b,2b42" }, + { } +diff --git a/drivers/net/wireless/marvell/mwifiex/sdio.c b/drivers/net/wireless/marvell/mwifiex/sdio.c +index 9f506efa..ea1c1c24 100644 +--- a/drivers/net/wireless/marvell/mwifiex/sdio.c ++++ b/drivers/net/wireless/marvell/mwifiex/sdio.c +@@ -479,7 +479,7 @@ static struct memory_type_mapping mem_type_mapping_tbl[] = { + {"EXTLAST", NULL, 0, 0xFE}, + }; + +-static const struct of_device_id mwifiex_sdio_of_match_table[] = { ++static const struct of_device_id mwifiex_sdio_of_match_table[] __maybe_unused = { + { .compatible = "marvell,sd8787" }, + { .compatible = "marvell,sd8897" }, + { .compatible = "marvell,sd8997" }, +-- +2.35.3 + diff --git a/series.conf b/series.conf index 21ae31f..cf19cde 100644 --- a/series.conf +++ b/series.conf @@ -2309,6 +2309,7 @@ patches.kernel.org/6.2.12-079-power-supply-cros_usbpd-reclassify-default-cas.patch patches.kernel.org/6.2.12-080-power-supply-axp288_fuel_gauge-Added-check-for.patch patches.kernel.org/6.2.12-081-selftests-bpf-Fix-progs-find_vma_fail1.c-build.patch + patches.kernel.org/6.2.12-082-wifi-mwifiex-mark-OF-related-data-as-maybe-unu.patch ######################################################## # Build fixes that apply to the vanilla kernel too.