{ pkgs, inputs, ... }: { boot.kernelPatches = let pickPatch = x: "${inputs.kernel-clr}/${x}"; patchFiles = map pickPatch [ "0101-i8042-decrease-debug-message-level-to-info.patch" "0102-increase-the-ext4-default-commit-age.patch" "0104-pci-pme-wakeups.patch" "0106-intel_idle-tweak-cpuidle-cstates.patch" "0107-bootstats-add-printk-s-to-measure-boot-time-in-more-.patch" "0108-smpboot-reuse-timer-calibration.patch" "0109-initialize-ata-before-graphics.patch" "0111-ipv4-tcp-allow-the-memory-tuning-for-tcp-to-go-a-lit.patch" "0112-init-wait-for-partition-and-retry-scan.patch" "0114-add-boot-option-to-allow-unsigned-modules.patch" "0115-enable-stateless-firmware-loading.patch" "0116-migrate-some-systemd-defaults-to-the-kernel-defaults.patch" "0117-xattr-allow-setting-user.-attributes-on-symlinks-by-.patch" "0120-do-accept-in-LIFO-order-for-cache-efficiency.patch" "0121-locking-rwsem-spin-faster.patch" "0122-ata-libahci-ignore-staggered-spin-up.patch" "0123-print-CPU-that-faults.patch" "0125-nvme-workaround.patch" "0126-don-t-report-an-error-if-PowerClamp-run-on-other-CPU.patch" "0127-lib-raid6-add-patch.patch" "0128-itmt_epb-use-epb-to-scale-itmt.patch" "0130-itmt2-ADL-fixes.patch" "0131-add-a-per-cpu-minimum-high-watermark-an-tune-batch-s.patch" "0133-novector.patch" "0134-md-raid6-algorithms-scale-test-duration-for-speedier.patch" "0135-initcall-only-print-non-zero-initcall-debug-to-speed.patch" "scale.patch" "libsgrowdown.patch" "adlrdt.patch" "epp-retune.patch" "0001-powerbump-functionality.patch" "0002-add-networking-support-for-powerbump.patch" "0003-futex-bump.patch" "0001-add-umonitor-umwait-C0.x-C-states.patch" "0001-mm-memcontrol-add-some-branch-hints-based-on-gcov-an.patch" "0002-sched-core-add-some-branch-hints-based-on-gcov-analy.patch" "0136-crypto-kdf-make-the-module-init-call-a-late-init-cal.patch" "ratelimit-sched-yield.patch" "scale-net-alloc.patch" "0158-clocksource-only-perform-extended-clocksource-checks.patch" "better_idle_balance.patch" "0161-ACPI-align-slab-buffers-for-improved-memory-performa.patch" "0162-extra-optmization-flags.patch" "0163-thermal-intel-powerclamp-check-MWAIT-first-use-pr_wa.patch" "0164-KVM-VMX-make-vmx-init-a-late-init-call-to-get-to-ini.patch" "0001-sched-migrate.patch" "0002-sched-migrate.patch" ]; patches = map builtins.readFile patchFiles; patchSet = builtins.concatStringsSep "\n" patches; patch = pkgs.writeText "kernel-clr-combined.patch" patchSet; in [{ inherit patch; name = "Clear Linux* patchset"; }]; }