xdp socket support (AF_XDP) is the new way of implementing high
performance networking on linux. on arch linux and debian this is
already enabled (checked via the links from the nixos manual).
moreover, these flags are suggested by the bpf documentation at cilium:
https://cilium.readthedocs.io/en/latest/bpf/#compiling-the-kernel
additionally the flag `BPF_JIT_ALWAYS_ON` on was suggested to help
spectre attack mitigations:
290af86629
This allows to set queueing disciplines different than a simple fifo,
like fq_codel, which is the default in systemd since quite some time.
NET_SCHED is already set in the kernels x86_64_defconfig, but not on
arm/aarch64, so let's set it here.
These enable some power management settings. They are needed for [s-tui
to show power readings](https://github.com/amanusk/s-tui/issues/105).
The values chosen here match what Arch Linux has. In particular
the Intel specific code is loadable as a module rather than compiled in.
Fixes https://github.com/NixOS/nixpkgs/issues/58070, and brings NixOS
into line with Ubuntu/Fedora/Arch/etc.
Tested that all kernels in Nixpkgs that build before this change build
after it.
To quote block/Kconfig:
> Builds Logic for interfacing with Opal enabled controllers.
> Enabling this option enables users to setup/unlock/lock
> Locking ranges for SED devices using the Opal protocol.
Without `BLK_SED_OPAL`, it is impossible to resume from sleep when using
a locked self-encrypting drive.
This configuration option appeared in earlier kernels, but only reached
maturity in 4.14 according to discussion at:
- https://github.com/Drive-Trust-Alliance/sedutil/issues/90 and
- https://github.com/Drive-Trust-Alliance/sedutil/pull/190
This kernel option is enabled in the default kernels shipped with
Fedora, Debian, and other mainstream Linux distributions.
This should make the composability of kernel configurations more straigthforward.
- now distinguish freeform options from tristate ones
- will look for a structured config in kernelPatches too
one can now access the structuredConfig from a kernel via linux_test.configfile.structuredConfig
in order to reinject it into another kernel, no need to rewrite the config from scratch
The following merge strategies are used in case of conflict:
-- freeform items must be equal or they conflict (mergeEqualOption)
-- for tristate (y/m/n) entries, I use the mergeAnswer strategy which takes the best available value, "best" being defined by the user (by default "y" > "m" > "n", e.g. if one entry is both marked "y" and "n", "y" wins)
-- if one item is both marked optional/mandatory, mandatory wins (mergeFalseByDefault)