diff mbox series

mwlwifi: remove target dependency

Message ID YFe4BHKrZaHXWnfL@makrotopia.org
State Superseded
Delegated to: Daniel Golle
Headers show
Series mwlwifi: remove target dependency | expand

Commit Message

Daniel Golle March 21, 2021, 9:17 p.m. UTC
Users complained that building images for various mvebu Linksys devices
fails when using the ImageBuilder, it complains about the package
'mwlwifi-firmware-88w8964' not being found.

Turns out the package builds fine in mvebu/cortex-a9 images build, but
isn't built at all for arm/cortex-a9 packages. This is because we are
using the SDK for bcm53xx/generic to build packages for arm/cortex-a9,
hence the dependency for @TARGET_mvebu fails.

Remove the target dependency as kmod-mwlwifi as well as firmware
packages actually build fine on all platforms (and people might even
want to use Marvell mPCIe Wifi on non-mvebu platforms).
As a result, the missing 'mwlwifi-firmware-'* packages should become
available for arm/cortex-a9 (and all other platforms).

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
---
See also:
https://forum.openwrt.org/t/recent-imagebuilder-build-issues-for-wrt3200acm-on-master/91802

 package/kernel/mwlwifi/Makefile | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Imre Kaloz March 22, 2021, 3:22 p.m. UTC | #1
Hi Daniel,

FWIW in my opinion we should get back to this topic as soon as you have a mwlwifi supported card up and running on any other platform. Right now this would introduce a change just to make a different platform's SDK usable for a purpose which would get a straight "no" from the developer community if a user would have proposed it.

I'm against this change (not that it matters ever since you've stripped maintainer roles in the name of democracy).


Imre
Daniel Golle March 22, 2021, 3:58 p.m. UTC | #2
On Mon, Mar 22, 2021 at 03:22:25PM +0000, Imre Kaloz wrote:
> Hi Daniel,
> 
> FWIW in my opinion we should get back to this topic as soon as you have a mwlwifi supported card up and running on any other platform. Right now this would introduce a change just to make a different platform's SDK usable for a purpose which would get a straight "no" from the developer community if a user would have proposed it.
> 

This change makes mwlwifi usable also on mvebu. I does not right now,
people fail to build images for e.g. WRT3200ACM using the ImageBuilder,
see link to forums below as well as commit description.

> I'm against this change (not that it matters ever since you've stripped maintainer roles in the name of democracy).

Do you have another idea then how we can get the issue resolved?
(I prefer not having to make any changes on the buildbots)

As you are the author of the driver, your opinion sure does matter, and
I do see you as being responsible for it even if that fact is not
reflected technically in the form of access control rules as it used to
be before 2017. I could have obviously just commited that (rather
trivial) change, but I thought it might be good to reach out and see if
anyone has objections (because you wouldn't add dependencies just for
the modest amount of fun in doing so, usually)


Cheers


Daniel


> 
> 
> Imre
> 
> ________________________________________
> From: Daniel Golle <daniel@makrotopia.org>
> Sent: Sunday, March 21, 2021 22:17
> To: openwrt-devel@lists.openwrt.org
> Cc: Imre Kaloz
> Subject: [PATCH] mwlwifi: remove target dependency
> 
> Users complained that building images for various mvebu Linksys devices
> fails when using the ImageBuilder, it complains about the package
> 'mwlwifi-firmware-88w8964' not being found.
> 
> Turns out the package builds fine in mvebu/cortex-a9 images build, but
> isn't built at all for arm/cortex-a9 packages. This is because we are
> using the SDK for bcm53xx/generic to build packages for arm/cortex-a9,
> hence the dependency for @TARGET_mvebu fails.
> 
> Remove the target dependency as kmod-mwlwifi as well as firmware
> packages actually build fine on all platforms (and people might even
> want to use Marvell mPCIe Wifi on non-mvebu platforms).
> As a result, the missing 'mwlwifi-firmware-'* packages should become
> available for arm/cortex-a9 (and all other platforms).
> 
> Signed-off-by: Daniel Golle <daniel@makrotopia.org>
> ---
> See also:
> https://forum.openwrt.org/t/recent-imagebuilder-build-issues-for-wrt3200acm-on-master/91802
> 
>  package/kernel/mwlwifi/Makefile | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/package/kernel/mwlwifi/Makefile b/package/kernel/mwlwifi/Makefile
> index 648c826ccb..14973d0010 100644
> --- a/package/kernel/mwlwifi/Makefile
> +++ b/package/kernel/mwlwifi/Makefile
> @@ -28,7 +28,7 @@ include $(INCLUDE_DIR)/package.mk
>  define KernelPackage/mwlwifi
>    SUBMENU:=Wireless Drivers
>    TITLE:=Marvell 88W8864/88W8897/88W8964/88W8997 wireless driver
> -  DEPENDS:=+kmod-mac80211 +@DRIVER_11N_SUPPORT +@DRIVER_11AC_SUPPORT @PCI_SUPPORT @TARGET_mvebu
> +  DEPENDS:=+kmod-mac80211 +@DRIVER_11N_SUPPORT +@DRIVER_11AC_SUPPORT @PCI_SUPPORT
>    FILES:=$(PKG_BUILD_DIR)/mwlwifi.ko
>    AUTOLOAD:=$(call AutoLoad,50,mwlwifi)
>  endef
> @@ -54,7 +54,7 @@ define Package/mwlwifi-firmware-default
>    SECTION:=firmware
>    CATEGORY:=Firmware
>    TITLE:=Marvell $(1) firmware
> -  DEPENDS:=+kmod-mwlwifi @TARGET_mvebu
> +  DEPENDS:=+kmod-mwlwifi
>  endef
> 
>  define Package/mwlwifi-firmware/install
> --
> 2.31.0
> 
> 
> _______________________________________________
> openwrt-devel mailing list
> openwrt-devel@lists.openwrt.org
> https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Hauke Mehrtens March 22, 2021, 10:14 p.m. UTC | #3
On 3/21/21 10:17 PM, Daniel Golle wrote:
> Users complained that building images for various mvebu Linksys devices
> fails when using the ImageBuilder, it complains about the package
> 'mwlwifi-firmware-88w8964' not being found.
> 
> Turns out the package builds fine in mvebu/cortex-a9 images build, but
> isn't built at all for arm/cortex-a9 packages. This is because we are
> using the SDK for bcm53xx/generic to build packages for arm/cortex-a9,
> hence the dependency for @TARGET_mvebu fails.
> 
> Remove the target dependency as kmod-mwlwifi as well as firmware
> packages actually build fine on all platforms (and people might even
> want to use Marvell mPCIe Wifi on non-mvebu platforms).
> As a result, the missing 'mwlwifi-firmware-'* packages should become
> available for arm/cortex-a9 (and all other platforms).

Does this happen for the kmod or only for the firmware package? If this 
only happens for the firmware package, does it help to add this to the 
package Makefile:
PKG_FLAGS:=nonshared

I think we only have this problems with the packages build by the 2. 
phase build bot which is shared between different targets with the same 
CPU. When we make it nonshared it should be build together with the 
target. We had a similar problems with the mtd package some time ago.

We should check if there are more places with similar problem.

Hauke
Daniel Golle March 23, 2021, 12:17 a.m. UTC | #4
On Mon, Mar 22, 2021 at 11:14:39PM +0100, Hauke Mehrtens wrote:
> On 3/21/21 10:17 PM, Daniel Golle wrote:
> > Users complained that building images for various mvebu Linksys devices
> > fails when using the ImageBuilder, it complains about the package
> > 'mwlwifi-firmware-88w8964' not being found.
> > 
> > Turns out the package builds fine in mvebu/cortex-a9 images build, but
> > isn't built at all for arm/cortex-a9 packages. This is because we are
> > using the SDK for bcm53xx/generic to build packages for arm/cortex-a9,
> > hence the dependency for @TARGET_mvebu fails.
> > 
> > Remove the target dependency as kmod-mwlwifi as well as firmware
> > packages actually build fine on all platforms (and people might even
> > want to use Marvell mPCIe Wifi on non-mvebu platforms).
> > As a result, the missing 'mwlwifi-firmware-'* packages should become
> > available for arm/cortex-a9 (and all other platforms).
> 
> Does this happen for the kmod or only for the firmware package? If this only
> happens for the firmware package, does it help to add this to the package
> Makefile:
> PKG_FLAGS:=nonshared

It's only the firmware package missing as the kmods are built in phase1.

> 
> I think we only have this problems with the packages build by the 2. phase
> build bot which is shared between different targets with the same CPU. When
> we make it nonshared it should be build together with the target. We had a
> similar problems with the mtd package some time ago.

Yes, adding PKG_FLAGS:=nonshared would solve the problem (and shouldn't
affect the anyway nonshared kmod build in the same package Makefile).
I forgot about that one...

> 
> We should check if there are more places with similar problem.

Other potentially affected packages which do have target dependencies
set but do not have PKG_FLAGS:=nonshared set:

network/utils/ltq-dsl-base
firmware/cypress-nvram

All other non-kmod core packages seem to have nonshared set in case
they got target dependencies.


Cheers


Daniel
Paul Spooren March 23, 2021, 1:16 a.m. UTC | #5
On Di, Mär 23, 2021 at 00:17, Daniel Golle <daniel@makrotopia.org> 
wrote:
> On Mon, Mar 22, 2021 at 11:14:39PM +0100, Hauke Mehrtens wrote:
>>  On 3/21/21 10:17 PM, Daniel Golle wrote:
>>  > Users complained that building images for various mvebu Linksys 
>> devices
>>  > fails when using the ImageBuilder, it complains about the package
>>  > 'mwlwifi-firmware-88w8964' not being found.
>>  >
>>  > Turns out the package builds fine in mvebu/cortex-a9 images 
>> build, but
>>  > isn't built at all for arm/cortex-a9 packages. This is because we 
>> are
>>  > using the SDK for bcm53xx/generic to build packages for 
>> arm/cortex-a9,
>>  > hence the dependency for @TARGET_mvebu fails.
>>  >
>>  > Remove the target dependency as kmod-mwlwifi as well as firmware
>>  > packages actually build fine on all platforms (and people might 
>> even
>>  > want to use Marvell mPCIe Wifi on non-mvebu platforms).
>>  > As a result, the missing 'mwlwifi-firmware-'* packages should 
>> become
>>  > available for arm/cortex-a9 (and all other platforms).
>> 
>>  Does this happen for the kmod or only for the firmware package? If 
>> this only
>>  happens for the firmware package, does it help to add this to the 
>> package
>>  Makefile:
>>  PKG_FLAGS:=nonshared
> 
> It's only the firmware package missing as the kmods are built in 
> phase1.
> 
>> 
>>  I think we only have this problems with the packages build by the 
>> 2. phase
>>  build bot which is shared between different targets with the same 
>> CPU. When
>>  we make it nonshared it should be build together with the target. 
>> We had a
>>  similar problems with the mtd package some time ago.
> 
> Yes, adding PKG_FLAGS:=nonshared would solve the problem (and 
> shouldn't
> affect the anyway nonshared kmod build in the same package Makefile).
> I forgot about that one...
> 
>> 
>>  We should check if there are more places with similar problem.
> 
> Other potentially affected packages which do have target dependencies
> set but do not have PKG_FLAGS:=nonshared set:
> 
> network/utils/ltq-dsl-base
> firmware/cypress-nvram

Could you do a treewide fixup patch?

> 
> All other non-kmod core packages seem to have nonshared set in case
> they got target dependencies.
> 
> 
> Cheers
> 
> 
> Daniel
> 
> _______________________________________________
> openwrt-devel mailing list
> openwrt-devel@lists.openwrt.org
> https://lists.openwrt.org/mailman/listinfo/openwrt-devel
diff mbox series

Patch

diff --git a/package/kernel/mwlwifi/Makefile b/package/kernel/mwlwifi/Makefile
index 648c826ccb..14973d0010 100644
--- a/package/kernel/mwlwifi/Makefile
+++ b/package/kernel/mwlwifi/Makefile
@@ -28,7 +28,7 @@  include $(INCLUDE_DIR)/package.mk
 define KernelPackage/mwlwifi
   SUBMENU:=Wireless Drivers
   TITLE:=Marvell 88W8864/88W8897/88W8964/88W8997 wireless driver
-  DEPENDS:=+kmod-mac80211 +@DRIVER_11N_SUPPORT +@DRIVER_11AC_SUPPORT @PCI_SUPPORT @TARGET_mvebu
+  DEPENDS:=+kmod-mac80211 +@DRIVER_11N_SUPPORT +@DRIVER_11AC_SUPPORT @PCI_SUPPORT
   FILES:=$(PKG_BUILD_DIR)/mwlwifi.ko
   AUTOLOAD:=$(call AutoLoad,50,mwlwifi)
 endef
@@ -54,7 +54,7 @@  define Package/mwlwifi-firmware-default
   SECTION:=firmware
   CATEGORY:=Firmware
   TITLE:=Marvell $(1) firmware
-  DEPENDS:=+kmod-mwlwifi @TARGET_mvebu
+  DEPENDS:=+kmod-mwlwifi
 endef
 
 define Package/mwlwifi-firmware/install