New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[RFT,RFC] generic: Add support for 6.6 kernel version #14751
Conversation
for the last commit, we have backports-6.6 now: fb45887 |
That's great. I didn't notice that. lol |
Make some more generic fixes and added tons missing symbols on top of this: |
Great, it was about time for 6.6 as 5.15 and 6.1 are so annoying to work with. |
I just created a 6.6 kernel support patch for the ralink mt7620 chipset: #14774 based on your PR. |
@hackpascal I made a PR to fix the GPIO button driver: |
Not sure if this is the right place to discuss this, but I want to open this debate: So I suggest to not repeat this mistake and merge support for Linux 6.6 asap and for a short time keep all 3 kernel version (5.15, 6.1, 6.6) in tree. Keeping 5.15 makes sense to ease backports to the current stable openwrt-23.05 branch. And moving the targets which are already on 6.1 now to 6.6 should not be too difficult, so we can drop Linux 6.1 again once this was done. |
@dangowrt I am all for adding 6.6 ASAP as having to deal with backporting more and more is just constantly increasing the workload. Not to mention that 5.15 really needs to go away, its just too old at this point and if we ever want to have a new release its time to push for all targets to move to 6.1 ASAP. |
Looks like CONFIG_INGENIC_CGU_JZ4755 is another symbol that needs to be added to the generic config:
I'm also seeing this, triggered by target/linux/generic/pending-6.6/205-backtrace_module_info.patch. Seems fallout of torvalds/linux@ac3b432:
|
There will be plenty of symbols to disable with the various target combos we have |
@@ -128,6 +129,7 @@ $(curdir)/quilt/compile := $(curdir)/autoconf/compile $(curdir)/findutils/compil | |||
$(curdir)/sdcc/compile := $(curdir)/bison/compile | |||
$(curdir)/squashfs3-lzma/compile := $(curdir)/lzma-old/compile | |||
$(curdir)/squashfs4/compile := $(curdir)/xz/compile $(curdir)/zlib/compile | |||
$(curdir)/util-linux/compile := $(curdir)/bison/compile |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
curious if it makes more sense to build with meson.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
curious if it makes more sense to build with meson.
I used meson at first, but it turns out that some components can't be disabled by meson and it finally lead to a build failure in buildbot container.
I was wondering why my port of mediatek target wouldn't boot and thought it might be smart to try armsr before, just to be sure that Aarch64 kernel in general boots fine on OpenWrt-patched Linux 6.6. Turns out it doesn't:
I will continue to look into this tomorrow, just posting now to share what I already found.
So this must be caused by one of our downstream hacks as, of course, it doesn't happen on vanilla Linux. In order to get armsr (armv8) to build I had to add some more new module dependencies: diff --git a/package/kernel/linux/modules/crypto.mk b/package/kernel/linux/modules/crypto.mk
index dd17d868fa..67dbac7662 100644
--- a/package/kernel/linux/modules/crypto.mk
+++ b/package/kernel/linux/modules/crypto.mk
@@ -44,7 +44,7 @@ define KernelPackage/crypto-aead
$(LINUX_DIR)/crypto/aead.ko \
$(LINUX_DIR)/crypto/geniv.ko
AUTOLOAD:=$(call AutoLoad,09,aead,1)
- $(call AddDepends/crypto, +kmod-crypto-null)
+ $(call AddDepends/crypto, +kmod-crypto-null +kmod-crypto-rng)
endef
$(eval $(call KernelPackage,crypto-aead))
diff --git a/package/kernel/linux/modules/netdevices.mk b/package/kernel/linux/modules/netdevices.mk
index 72504d8de7..2ba59f40d2 100644
--- a/package/kernel/linux/modules/netdevices.mk
+++ b/package/kernel/linux/modules/netdevices.mk
@@ -1573,7 +1573,7 @@ $(eval $(call KernelPackage,pcs-xpcs))
define KernelPackage/stmmac-core
SUBMENU:=$(NETWORK_DEVICES_MENU)
TITLE:=Synopsis Ethernet Controller core (NXP,STMMicro,others)
- DEPENDS:=@TARGET_x86_64||TARGET_armsr_armv8 +kmod-pcs-xpcs +kmod-ptp
+ DEPENDS:=@TARGET_x86_64||TARGET_armsr_armv8 +kmod-pcs-xpcs +LINUX_6_6:kmod-of-mdio +kmod-ptp
KCONFIG:=CONFIG_STMMAC_ETH \
CONFIG_STMMAC_SELFTESTS=n \
CONFIG_STMMAC_PLATFORM \ Strangly when making |
Is this related to hackpascal#3 ? |
Oh yes, that very obviously looks like the same problem. Got most things working now: |
replace |
@hackpascal thanks for the ping. I've created #14713 last week, maybe the script is useful to do the bumping so that we can keep kernel history. @robimarko wdyt? |
@oliv3r I tested in on the ath25 bump and it seemed to work just fine |
While this is the wrong thread, let's merge it and iterate where needed :) then we can use the script here too.
…On March 2, 2024 11:11:40 a.m. GMT+01:00, Robert Marko ***@***.***> wrote:
@oliv3r I tested in on the ath25 bump and it seemed to work just fine
--
Reply to this email directly or view it on GitHub:
#14751 (comment)
You are receiving this because you were mentioned.
Message ID: ***@***.***>
|
Well, I seem to have got |
In 6.6 kernel, the mpi.ko that the kmod-crypto-rsa module depends on is located at $(LINUX_DIR)/lib/crypto/mpi/mpi.ko. How should the makefile adapt to this directory change? There are changes caused by this commit that are also worth investigating |
Sort generic config for 6.6. The sort commands: $ ./scripts/kconfig.pl '+' target/linux/generic/config-6.6 /dev/null > target/linux/generic/config-6.6-new $ mv target/linux/generic/config-6.6-new target/linux/generic/config-6.6 Signed-off-by: Weijie Gao <hackpascal@gmail.com>
Update fitblk driver which has previously been backported to Linux 6.1 so it can build and work with Linux 6.6. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Currently, the existing uncompressed kallsym support is causing qualcommax boards to hang on boot, and only after earlycon and verbose BUG() prints are enabled the trace is visible: [ 0.000000] ------------[ cut here ]------------ [ 0.000000] kernel BUG at kernel/kallsyms.c:340! [ 0.000000] Internal error: Oops - BUG: 00000000f2000800 [#1] SMP Felix has fixed up the uncompressed kallsyms support so modify the current patch with the fix. All credits for the code go to Felix. Signed-off-by: Robert Marko <robimarko@gmail.com>
Avoid crashing the kernel when trying to detect early versions of RealTek RTL8221B 2.5G Ethernet PHY. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Adapt iio kmods for building under kernel 6.6: * kmod-iio-lsm6dsx depends on kmod-kmod-industrialio-triggered-buffer from 6.2 Signed-off-by: Weijie Gao <hackpascal@gmail.com>
Adapt input kmods for building under kernel 6.6: * kmod-input-touchscreen-edt-ft5x06 depends on kmod-regmap-i2c from 6.3 as it starts to use regmap to access registers * CONFIG_HID_SUPPORT needs to be set in addition to CONFIG_HID. Signed-off-by: Daniel Golle <daniel@makrotopia.org> Signed-off-by: Weijie Gao <hackpascal@gmail.com>
Adapt netsupport kmods for building under kernel 6.6: * common part of mqprio was split into a new Kconfig since 6.3. Add new kmod-sched-mqprio-common as dependency for kmod-sched-mqprio. Signed-off-by: Weijie Gao <hackpascal@gmail.com>
Adapt netdevices kmods for building under kernel 6.6: * Add missing module dependency for kmod-stmmac-core on kmod-of-mdio. * Invert criteria to allow Airoha EN8811H PHY driver to build with Linux 6.1 as well as Linux 6.6. * Mellanox mlx5 driver started exposing thermal sensors and now it requires hwmon Signed-off-by: Robert Marko <robimarko@gmail.com> Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Adapt usb kmods for building under kernel 6.6: * Add kmod-phylink as dependency for usb-net-asix * Add kmod-net-selftests as dependency for usb-net-smsc95xx * Add kmod-iio-core as dependency for usb-hid-mcp2221 as ADC/DAC support was added since 6.2 which requires IIO. Signed-off-by: Weijie Gao <hackpascal@gmail.com>
Adapt fs kmods for building under kernel 6.6: * Add kmod-fs-netfs as dependency for kmod-fs-9p * Add kmod-fs-netfs as dependency for fs-smbfs-common as netfs is required for cifs since 6.3 * Add new kmod-nls-ucs2-utils as dependency for smbfs/jfs as UCS2 support was split as new module since 6.6. * Add kmod-lib-zlib-deflate and kmod-lib-zlib-inflate as dependencies for kmod-pstore due to crypto API compression was replaced with zlib_deflate library calls since 6.6 * Remove nfs_ssc.ko from kmod-fs-nfs-common. The nfs_ssc was no longer a kernel module described by NFS_V4_2_SSC_HELPER since 5.13 [1] Link: [1] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/fs/Kconfig?id=d9092b4bb2109502eb8972021a3f74febc931a63 Signed-off-by: Weijie Gao <hackpascal@gmail.com>
Adapt block kmods for building under kernel 6.6: * To build scsi_transport_iscsi.ko, change CONFIG_SCSI_ISCSI_ATTRS from =y to =m as this config is always tristate since 2.6. Signed-off-by: Weijie Gao <hackpascal@gmail.com>
Adapt video kmods for building under kernel 6.6: * Add drm_exec.ko and drm_suballoc_helper.ko for kmod-drm as they are added since 6.6 and 6.4 * Add uvc.ko for kmod-video-uvc as related contents was split as a new module since 6.3 Signed-off-by: Tan Zien <nabsdh9@gmail.com> Signed-off-by: Weijie Gao <hackpascal@gmail.com>
Adapt crypto kmods for building under kernel 6.6: * mpi.ko moved from lib/mpi/mpi.ko to lib/crypto/mpi/mpi.ko * jitterentropy_rng requires SHA3 support for kernel 6.6 Signed-off-by: Robert Marko <robimarko@gmail.com> Signed-off-by: Tan Zien <nabsdh9@gmail.com> Signed-off-by: Weijie Gao <hackpascal@gmail.com>
Adapt hwmon kmods for building under kernel 6.6: * ad7418 now requires regmap * Invert criteria to allow adt7410 be built with Linux 6.1 as well as Linux 6.6. Signed-off-by: Tan Zien <nabsdh9@gmail.com>
In kernel 6.5 geniv was split from AEAD config symbol, in order to manage its dependencies on other code. So, lets do the same in OpenWrt and split it from aead module so others can depend on geniv directly. Signed-off-by: Robert Marko <robimarko@gmail.com>
geniv was separated intentionally from aead in kernel 6.5, and since we now have it packaged separately as well remove it from kmod-aead in 6.6. Signed-off-by: Robert Marko <robimarko@gmail.com>
…se it Now that geniv is packaged separately for kernel 6.6, we need to add it as a dependency to kmod-crypto-seqiv and kmod-crypto-echainiv that require it under kernel 6.6. Signed-off-by: Robert Marko <robimarko@gmail.com>
devm_gpiod_get_from_of_node() was removed since linux 6.2. devm_fwnode_gpiod_get() is the recommended replacement. Link: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/drivers/gpio/gpiolib-devres.c?id=650f2dc970539b3344a98c4bd18efa309e66623b Signed-off-by: Robert Marko <robimarko@gmail.com> Signed-off-by: Weijie Gao <hackpascal@gmail.com>
Fix build failure with linux kernel 6.6 Related kernel commits: 20b0b53aca43 (genetlink: introduce split op representation) bffcc6882a1b (genetlink: remove userhdr from struct genl_info) e9a688bcb193 (random: use rejection sampling for uniform bounded random integers) 3c202d14a9d7 (prandom: remove prandom_u32_max()) 3d2f20ad46f8 (wifi: iwlwifi: Use generic thermal_zone_get_trip() function) Signed-off-by: Weijie Gao <hackpascal@gmail.com>
A commit introduced in kernel 6.6 has splitted page_pool.h into several headers. Thus the included header must be modified for a successful build. Ref: a9ca9f9ceff3 (page_pool: split types and declarations from page_pool.h) Signed-off-by: Weijie Gao <hackpascal@gmail.com>
Use the correct return status code to avoid incompatible type error Signed-off-by: Weijie Gao <hackpascal@gmail.com>
Fix a build error caused by fortify checking memcpy data range. Signed-off-by: Weijie Gao <hackpascal@gmail.com>
Allow building fitblk with Linux 6.6 by depending on !LINUX_5_15 instead of LINUX_6_1. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Lets not delay this any further, we can always fixup stuff in main as well |
Then I have one question: how to ensure host-build of
You have to send another PR now XD |
Add support for 6.6 kernel version: