2022-03-16 20:12:40

by Arnd Bergmann

[permalink] [raw]
Subject: [PATCH] iwlwifi: mei: fix building iwlmei

From: Arnd Bergmann <[email protected]>

Building iwlmei without CONFIG_CFG80211 causes a link-time warning:

ld.lld: error: undefined symbol: ieee80211_hdrlen
>>> referenced by net.c
>>> net/wireless/intel/iwlwifi/mei/net.o:(iwl_mei_tx_copy_to_csme) in archive drivers/built-in.a

Add an explicit dependency to avoid this. In theory it should not
be needed here, but it also seems pointless to allow IWLMEI
for configurations without CFG80211.

Signed-off-by: Arnd Bergmann <[email protected]>
---
drivers/net/wireless/intel/iwlwifi/Kconfig | 1 +
1 file changed, 1 insertion(+)

I see this warning on 5.17-rc8, but did not test it on linux-next,
which may already have a fix.

diff --git a/drivers/net/wireless/intel/iwlwifi/Kconfig b/drivers/net/wireless/intel/iwlwifi/Kconfig
index 85e704283755..a647a406b87b 100644
--- a/drivers/net/wireless/intel/iwlwifi/Kconfig
+++ b/drivers/net/wireless/intel/iwlwifi/Kconfig
@@ -139,6 +139,7 @@ config IWLMEI
tristate "Intel Management Engine communication over WLAN"
depends on INTEL_MEI
depends on PM
+ depends on CFG80211
help
Enables the iwlmei kernel module.

--
2.29.2


2022-03-17 02:59:40

by Kalle Valo

[permalink] [raw]
Subject: Re: [PATCH] iwlwifi: mei: fix building iwlmei

Arnd Bergmann <[email protected]> writes:

> From: Arnd Bergmann <[email protected]>
>
> Building iwlmei without CONFIG_CFG80211 causes a link-time warning:
>
> ld.lld: error: undefined symbol: ieee80211_hdrlen
>>>> referenced by net.c
>>>> net/wireless/intel/iwlwifi/mei/net.o:(iwl_mei_tx_copy_to_csme)
>>>> in archive drivers/built-in.a
>
> Add an explicit dependency to avoid this. In theory it should not
> be needed here, but it also seems pointless to allow IWLMEI
> for configurations without CFG80211.
>
> Signed-off-by: Arnd Bergmann <[email protected]>
> ---
> drivers/net/wireless/intel/iwlwifi/Kconfig | 1 +
> 1 file changed, 1 insertion(+)
>
> I see this warning on 5.17-rc8, but did not test it on linux-next,
> which may already have a fix.

I just sent the last pull request to v5.17. Luca, should I take this to
wireless-next? Ack?

--
https://patchwork.kernel.org/project/linux-wireless/list/

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

2022-03-17 05:14:28

by Grumbach, Emmanuel

[permalink] [raw]
Subject: RE: [PATCH] iwlwifi: mei: fix building iwlmei

>
> From: Arnd Bergmann <[email protected]>
>
> Building iwlmei without CONFIG_CFG80211 causes a link-time warning:
>
> ld.lld: error: undefined symbol: ieee80211_hdrlen
> >>> referenced by net.c
> >>>
> >>> net/wireless/intel/iwlwifi/mei/net.o:(iwl_mei_tx_copy_to_csme) in
> >>> archive drivers/built-in.a
>
> Add an explicit dependency to avoid this. In theory it should not be needed
> here, but it also seems pointless to allow IWLMEI for configurations without
> CFG80211.
>
> Signed-off-by: Arnd Bergmann <[email protected]>
> ---
> drivers/net/wireless/intel/iwlwifi/Kconfig | 1 +
> 1 file changed, 1 insertion(+)
>
> I see this warning on 5.17-rc8, but did not test it on linux-next, which may
> already have a fix.
>
> diff --git a/drivers/net/wireless/intel/iwlwifi/Kconfig
> b/drivers/net/wireless/intel/iwlwifi/Kconfig
> index 85e704283755..a647a406b87b 100644
> --- a/drivers/net/wireless/intel/iwlwifi/Kconfig
> +++ b/drivers/net/wireless/intel/iwlwifi/Kconfig
> @@ -139,6 +139,7 @@ config IWLMEI
> tristate "Intel Management Engine communication over WLAN"
> depends on INTEL_MEI
> depends on PM
> + depends on CFG80211
> help
> Enables the iwlmei kernel module.
>

FWIW: Luca just merged the exact same patch internally. So
Acked-by: Emmanuel Grumbach <[email protected]>

2022-03-17 12:43:30

by Luciano Coelho

[permalink] [raw]
Subject: Re: [PATCH] iwlwifi: mei: fix building iwlmei

On Wed, 2022-03-16 at 18:55 +0000, Grumbach, Emmanuel wrote:
> >
> > From: Arnd Bergmann <[email protected]>
> >
> > Building iwlmei without CONFIG_CFG80211 causes a link-time warning:
> >
> > ld.lld: error: undefined symbol: ieee80211_hdrlen
> > > > > referenced by net.c
> > > > >
> > > > > net/wireless/intel/iwlwifi/mei/net.o:(iwl_mei_tx_copy_to_csme
> > > > > ) in
> > > > > archive drivers/built-in.a
> >
> > Add an explicit dependency to avoid this. In theory it should not
> > be needed
> > here, but it also seems pointless to allow IWLMEI for
> > configurations without
> > CFG80211.
> >
> > Signed-off-by: Arnd Bergmann <[email protected]>
> > ---
> >  drivers/net/wireless/intel/iwlwifi/Kconfig | 1 +
> >  1 file changed, 1 insertion(+)
> >
> > I see this warning on 5.17-rc8, but did not test it on linux-next,
> > which may
> > already have a fix.
> >
> > diff --git a/drivers/net/wireless/intel/iwlwifi/Kconfig
> > b/drivers/net/wireless/intel/iwlwifi/Kconfig
> > index 85e704283755..a647a406b87b 100644
> > --- a/drivers/net/wireless/intel/iwlwifi/Kconfig
> > +++ b/drivers/net/wireless/intel/iwlwifi/Kconfig
> > @@ -139,6 +139,7 @@ config IWLMEI
> >   tristate "Intel Management Engine communication over WLAN"
> >   depends on INTEL_MEI
> >   depends on PM
> > + depends on CFG80211
> >   help
> >   Enables the iwlmei kernel module.
> >
>
> FWIW: Luca just merged the exact same patch internally. So
> Acked-by: Emmanuel Grumbach <[email protected]>

Yeah, please take this.

Acked-by: Luca Coelho <[email protected]>

--
Cheers,
Luca.

2022-03-17 19:03:12

by Kalle Valo

[permalink] [raw]
Subject: Re: [PATCH] iwlwifi: mei: fix building iwlmei

Arnd Bergmann <[email protected]> wrote:

> From: Arnd Bergmann <[email protected]>
>
> Building iwlmei without CONFIG_CFG80211 causes a link-time warning:
>
> ld.lld: error: undefined symbol: ieee80211_hdrlen
> >>> referenced by net.c
> >>> net/wireless/intel/iwlwifi/mei/net.o:(iwl_mei_tx_copy_to_csme) in archive drivers/built-in.a
>
> Add an explicit dependency to avoid this. In theory it should not
> be needed here, but it also seems pointless to allow IWLMEI
> for configurations without CFG80211.
>
> Signed-off-by: Arnd Bergmann <[email protected]>
> Acked-by: Emmanuel Grumbach <[email protected]>
> Acked-by: Luca Coelho <[email protected]>

Patch applied to wireless-next.git, thanks.

066291bec0c5 iwlwifi: mei: fix building iwlmei

--
https://patchwork.kernel.org/project/linux-wireless/patch/[email protected]/

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