From 71fc56e415bf356df42f073fca2590761dfaa1ff Mon Sep 17 00:00:00 2001 From: Artemis Tosini Date: Tue, 29 Sep 2020 23:12:47 +0000 Subject: [PATCH] Add cursed patch for spike --- externals/patches/increase_max_topo.patch | 13 +++++++++++++ system/spike/boot-config.nix | 4 ++++ 2 files changed, 17 insertions(+) create mode 100644 externals/patches/increase_max_topo.patch diff --git a/externals/patches/increase_max_topo.patch b/externals/patches/increase_max_topo.patch new file mode 100644 index 0000000..f0617bb --- /dev/null +++ b/externals/patches/increase_max_topo.patch @@ -0,0 +1,13 @@ +diff --git a/include/linux/usb/hcd.h b/include/linux/usb/hcd.h +index 3dbb42c637c1..8d45c90cee8a 100644 +--- a/include/linux/usb/hcd.h ++++ b/include/linux/usb/hcd.h +@@ -26,7 +26,7 @@ + #include + #include + +-#define MAX_TOPO_LEVEL 6 ++#define MAX_TOPO_LEVEL 1022 + + /* This file contains declarations of usbcore internals that are mostly + * used or exposed by Host Controller Drivers. diff --git a/system/spike/boot-config.nix b/system/spike/boot-config.nix index 08c4c2e..67225fa 100644 --- a/system/spike/boot-config.nix +++ b/system/spike/boot-config.nix @@ -3,6 +3,10 @@ { boot = { kernelPackages = pkgs.linuxPackages_latest; + kernelPatches = [ { + name = "increase_max_topo"; + patch = ../../externals/patches/increase_max_topo.patch; + } ]; kernel.sysctl."vm.swappiness" = 5; cleanTmpDir = true;