Bug 1187100

Summary: Leap 15.3 ARM images need kernel-default-extra
Product: [openSUSE] openSUSE Distribution Reporter: Martin Wilck <martin.wilck>
Component: OtherAssignee: Guillaume GARDET <guillaume.gardet>
Status: RESOLVED FIXED QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None CC: fvogt
Version: Leap 15.3   
Target Milestone: ---   
Hardware: aarch64   
OS: Other   
See Also: https://bugzilla.suse.com/show_bug.cgi?id=1186096
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Martin Wilck 2021-06-09 09:24:36 UTC
I came across this while trying to make my OdroidC2 working with Leap 15.3.

Detection and initialization of the SoC's MMC devices requires the meson-gx-mmc.ko module, which has been moved to kernel-default-extra. Without this module, the image won't detect storage.

I'm aware that the OdroidC2 is (unfortunately) officially unsupported on Leap.
However, I'm pretty certain that this issue will also affect other ARM boards, and that we need to include kernel-$flavor-extra in various ARM images.

The following change appears to work for the OdroidC2, because kernel-default-extra pulls in kernel-default:

--- Images.kiwi.in      (revision 4e812de30561
c81f831b100d1c01dd17)
+++ Images.kiwi.in      (working copy)
@@ -426,7 +426,7 @@
                          PKG_TAG(bcm43xx-firmware)
 #  define USE_EFI 1
 #elif IS_FLAVOR_odroidc2
-#  define BOOTKERNEL default
+#  define BOOTKERNEL default-extra
 #  define KERNEL_CMDLINE_SER "KERNEL_CMDLINE_DEFAULT"
 #  define KERNEL_CMDLINE_GFX "KERNEL_CMDLINE_DEFAULT console=ttyAML0,115200n8 console=tty"
 #  define EXTRA_PACKAGES PKG_BOOT_TAG(odroidc2-firmware) \
Comment 1 Martin Wilck 2021-06-09 09:30:42 UTC
On the other hand, we include "kernel-firmware-all" in all images, which  contains lots of firmware for devices that are rarely encountered on ARM devices, such as i915. For my OdroidC2, I need no single kernel-firmware-xyz package. By leaving out kernel-firmware-all, we can decrease image sizes significantly (compressed size 400MiB vs 240MiB in my case).
Comment 2 Guillaume GARDET 2021-06-09 09:34:01 UTC
Fix already submitted via maintenance: 
https://build.opensuse.org/request/show/896322
Comment 3 Guillaume GARDET 2021-06-09 09:42:27 UTC
(In reply to Martin Wilck from comment #1)
> On the other hand, we include "kernel-firmware-all" in all images, which 
> contains lots of firmware for devices that are rarely encountered on ARM
> devices, such as i915. For my OdroidC2, I need no single kernel-firmware-xyz
> package. By leaving out kernel-firmware-all, we can decrease image sizes
> significantly (compressed size 400MiB vs 240MiB in my case).

firmware may also be needed for pluggable devices.
And if we drop kernel-firmware-all, it will be hard to avoid regressions on some boards. But I agree some firmware could be dropped safely.

Feel free to submit some updates to openSUSE:Factory:ARM/JeOS, then we can review it.
Comment 4 Martin Wilck 2021-06-09 10:15:20 UTC
(In reply to Guillaume GARDET from comment #2)
> Fix already submitted via maintenance: 
> https://build.opensuse.org/request/show/896322

Ah, thanks. So it's a dup of bug 1186096.

Note: JeOS-odroidc2.kiwi doesn't get updated by the pre_checkin.sh script,
as it skips officially unsupported devices.

(In reply to Guillaume GARDET from comment #3)

> firmware may also be needed for pluggable devices.

Does FW for pluggable devices need to be on JeOS images? IMO it should be sufficient to include FW for onboard devices.

> And if we drop kernel-firmware-all, it will be hard to avoid regressions on
> some boards. But I agree some firmware could be dropped safely.

We need a method to determine which FW is required on a given board. I'm unaware of any simple method. We do have modalias "supplements" in the kernel-firmware-xyz packages, but matching them with the modaliases present on a given system is difficult and error-prone. IIRC YaST supports it somehow, but I don't know the details, and I doubt YaST is able to detect superfluous/unnecessary firmware packages and suggest their de-installation to the user.

> Feel free to submit some updates to openSUSE:Factory:ARM/JeOS, then we can
> review it.

My ARM experience is limited to my OdroidC2 :-/
For it, you can safely drop the kernel-firmware requirement.