On Thu 2021-02-04 09:51:03, Greg Kroah-Hartman wrote:
On Thu, Feb 04, 2021 at 08:26:04AM +0100, Jiri Slaby wrote:
On 04. 02. 21, 7:20, Greg Kroah-Hartman wrote:
On Thu, Feb 04, 2021 at 05:59:42AM +0000, Jari Ruusu wrote:
Greg, I hope that your linux kernel release scripts are implemented in a way that understands that PATCHLEVEL= and SUBLEVEL= numbers in top-level linux Makefile are encoded as 8-bit numbers for LINUX_VERSION_CODE and KERNEL_VERSION() macros, and must stay in range 0...255. These 8-bit limits are hardcoded in both kernel source and userspace ABI.
After 4.9.255 and 4.4.255, your scripts should be incrementing a number in EXTRAVERSION= in top-level linux Makefile.
Should already be fixed in linux-next, right?
I assume you mean: commit 537896fabed11f8d9788886d1aacdb977213c7b3 Author: Sasha Levin sashal@kernel.org Date: Mon Jan 18 14:54:53 2021 -0500
kbuild: give the SUBLEVEL more room in KERNEL_VERSION
That would IMO break userspace as definition of kernel version has changed. And that one is UAPI/ABI (see include/generated/uapi/linux/version.h) as Jari writes. For example will glibc still work: http://sourceware.org/git/?p=glibc.git%3Ba=blob%3Bf=sysdeps/unix/sysv/linux/...
? Or gcc 10 (11 will have this differently): https://gcc.gnu.org/git/?p=gcc.git%3Ba=blob%3Bf=gcc/config/bpf/bpf.c%3Bhb=ee...
and
https://gcc.gnu.org/git/?p=gcc.git%3Ba=blob%3Bf=gcc/config/bpf/bpf-helpers.h...
Ugh, I thought this was an internal representation, not an external one :(
It might work somewhere, but there are a lot of (X * 65536 + Y * 256 + Z) assumptions all around the world. So this doesn't look like a good idea.
Ok, so what happens if we "wrap"? What will break with that? At first glance, I can't see anything as we keep the padding the same, and our build scripts seem to pick the number up from the Makefile and treat it like a string.
It's only the crazy out-of-tree kernel stuff that wants to do minor version checks that might go boom. And frankly, I'm not all that concerned if they have problems :)
So, let's leave it alone and just see what happens!
Yeah, stable is a great place to do the experiments. Not that this is the first time :-(. Pavel