summary refs log tree commit diff
path: root/pkgs/os-specific/linux/kernel/common-config.nix
diff options
context:
space:
mode:
authorAaron Andersen <aaron@fosslib.net>2019-01-16 19:58:08 +0000
committerAaron Andersen <aaron@fosslib.net>2019-01-18 13:17:33 +0000
commite63414078a7dd7ac08dc916af04f01c90d01c875 (patch)
treec4f19e59d7a16480bf3de4775944972ec11fc7e9 /pkgs/os-specific/linux/kernel/common-config.nix
parent2832ec93358f60578cae3efc25a843e048e0a55a (diff)
downloadnixpkgs-e63414078a7dd7ac08dc916af04f01c90d01c875.tar
nixpkgs-e63414078a7dd7ac08dc916af04f01c90d01c875.tar.gz
nixpkgs-e63414078a7dd7ac08dc916af04f01c90d01c875.tar.bz2
nixpkgs-e63414078a7dd7ac08dc916af04f01c90d01c875.tar.lz
nixpkgs-e63414078a7dd7ac08dc916af04f01c90d01c875.tar.xz
nixpkgs-e63414078a7dd7ac08dc916af04f01c90d01c875.tar.zst
nixpkgs-e63414078a7dd7ac08dc916af04f01c90d01c875.zip
Enable memory hotplug support
Diffstat (limited to 'pkgs/os-specific/linux/kernel/common-config.nix')
-rw-r--r--pkgs/os-specific/linux/kernel/common-config.nix8
1 files changed, 8 insertions, 0 deletions
diff --git a/pkgs/os-specific/linux/kernel/common-config.nix b/pkgs/os-specific/linux/kernel/common-config.nix
index ab4b1cc2fc9..4e23e533433 100644
--- a/pkgs/os-specific/linux/kernel/common-config.nix
+++ b/pkgs/os-specific/linux/kernel/common-config.nix
@@ -686,6 +686,14 @@ let
       HOTPLUG_PCI_ACPI = yes; # PCI hotplug using ACPI
       HOTPLUG_PCI_PCIE = yes; # PCI-Expresscard hotplug support
 
+      # Enable memory hotplug support
+      # Allows you to dynamically add & remove memory to a VM client running NixOS without requiring a reboot
+      ACPI_HOTPLUG_MEMORY = yes;
+      MEMORY_HOTPLUG = yes;
+      MEMORY_HOTREMOVE = yes;
+      MIGRATION = yes;
+      SPARSEMEM = yes;
+
     } // optionalAttrs (stdenv.hostPlatform.system == "x86_64-linux" || stdenv.hostPlatform.system == "aarch64-linux") {
       # Bump the maximum number of CPUs to support systems like EC2 x1.*
       # instances and Xeon Phi.