lkml.org 
[lkml]   [2021]   [Feb]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: Kernel version numbers after 4.9.255 and 4.4.255
From
Date
On 2/4/21 6:00 AM, Jiri Slaby wrote:
> Agreed. But currently, sublevel won't "wrap", it will "overflow" to
> patchlevel. And that might be a problem. So we might need to update the
> header generation using e.g. "sublevel & 0xff" (wrap around) or
> "sublevel > 255 : 255 : sublevel" (be monotonic and get stuck at 255).
>
> In both LINUX_VERSION_CODE generation and KERNEL_VERSION proper.

My preference would be to be monotonic and get stuck at 255 to avoid
breaking out-of-tree modules.  If needed, add another macro that
increases the number of bits that can be used to check for sublevels >
255, while keeping the old macros for compatibility reasons.  Since
sublevels > 255 have never existed before, any such checks must be
newly-added, so they can be required to use the new macros.

I do not run the 4.4/4.9 kernels usually, but I do sometimes test a wide
range of kernels from 3.18 (gasp!) up to the latest when bisecting,
benchmarking, or debugging problems.  And I use a number of out-of-tree
modules that rely on the KERNEL_VERSION to make everything work.  Some
out-of-tree modules like an updated igb network driver might be needed
to make it possible to test the old kernel on particular hardware.

In the worst case, I can patch LINUX_VERSION_CODE and KERNEL_VERSION
locally to make out-of-tree modules work.  Or else just not test kernels
with sublevel > 255.

Tony Battersby
Cybernetics


\
 
 \ /
  Last update: 2021-02-05 18:52    [W:0.116 / U:1.640 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site