1 { lib, buildLinux, fetchurl
3 , structuredExtraConfig ? {}
9 version = "5.4.278-rt91"; # updated by ./update-rt.sh
10 branch = lib.versions.majorMinor version;
11 kversion = builtins.elemAt (lib.splitString "-" version) 0;
12 in buildLinux (args // {
17 url = "mirror://kernel/linux/kernel/v5.x/linux-${kversion}.tar.xz";
18 sha256 = "1245zf7vk2fyprw9fspljqy9wlzma9bayri7xx2g8iam2430d875";
21 kernelPatches = let rt-patch = {
24 url = "mirror://kernel/linux/kernel/projects/rt/${branch}/older/patch-${version}.patch.xz";
25 sha256 = "0s1ars3d18jg55kpvk6q5b6rk66c74d2khd2mxzdm5ifgm47047k";
27 }; in [ rt-patch ] ++ kernelPatches;
29 structuredExtraConfig = with lib.kernel; {
31 # Fix error: unused option: PREEMPT_RT.
32 EXPERT = yes; # PREEMPT_RT depends on it (in kernel/Kconfig.preempt)
33 # Fix error: option not set correctly: PREEMPT_VOLUNTARY (wanted 'y', got 'n').
34 PREEMPT_VOLUNTARY = lib.mkForce no; # PREEMPT_RT deselects it.
35 # Fix error: unused option: RT_GROUP_SCHED.
36 RT_GROUP_SCHED = lib.mkForce (option no); # Removed by sched-disable-rt-group-sched-on-rt.patch.
37 } // structuredExtraConfig;
39 extraMeta = extraMeta // {