This patch (backported from Linux 5.5) fixes hotplugging with cloud-hypervisor. See https://github.com/cloud-hypervisor/cloud-hypervisor/blob/8b7aafad16ee8a23d7.... --- pkgs/os-specific/linux/kernel/patches.nix | 9 +++++++++ pkgs/os-specific/linux/spectrum/linux/vm.nix | 5 ++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/pkgs/os-specific/linux/kernel/patches.nix b/pkgs/os-specific/linux/kernel/patches.nix index 8ce1ac2b587..a802a0a24d7 100644 --- a/pkgs/os-specific/linux/kernel/patches.nix +++ b/pkgs/os-specific/linux/kernel/patches.nix @@ -92,4 +92,13 @@ name = "mac_nvme_t2"; patch = ./mac-nvme-t2.patch; }; + + # https://github.com/cloud-hypervisor/cloud-hypervisor/blob/8b7aafad16ee8a23d7... + evged = { + name = "evged"; + patch = fetchpatch { + url = "https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/patch?id=..."; + sha256 = "0hzl3s2fmsvz54hq478lqi14dwry8a5g2b2awsssxf0r2ga15jk5"; + }; + }; } diff --git a/pkgs/os-specific/linux/spectrum/linux/vm.nix b/pkgs/os-specific/linux/spectrum/linux/vm.nix index 9c9ba78b691..f456053dc99 100644 --- a/pkgs/os-specific/linux/spectrum/linux/vm.nix +++ b/pkgs/os-specific/linux/spectrum/linux/vm.nix @@ -1,8 +1,11 @@ -{ lib, linux }: +{ lib, linux, kernelPatches }: with lib.kernel; linux.override { + # Fix hotplugging with cloud-hypervisor. + kernelPatches = linux.kernelPatches ++ [ kernelPatches.evged ]; + structuredExtraConfig = { VIRTIO_PCI = yes; VIRTIO_BLK = yes; -- 2.30.0