git.iko.soy/typeable/nixpkgs
on master help sign in
Use looser 9pfs caching in VM tests/builds
bbd03e2Eelco Dolstra
nixos/modules/virtualisation/qemu-vm.nix+2−2
@@ -440,13 +440,13 @@ in
440 ${if cfg.writableStore then "/nix/.ro-store" else "/nix/store"} =
440 ${if cfg.writableStore then "/nix/.ro-store" else "/nix/store"} =
441 { device = "store";
441 { device = "store";
442 fsType = "9p";
442 fsType = "9p";
443− options = [ "trans=virtio" "version=9p2000.L" "cache=loose" ];
443+ options = [ "trans=virtio" "version=9p2000.L" "veryloose" ];
444 neededForBoot = true;
444 neededForBoot = true;
445 };
445 };
446 "/tmp/xchg" =
446 "/tmp/xchg" =
447 { device = "xchg";
447 { device = "xchg";
448 fsType = "9p";
448 fsType = "9p";
449− options = [ "trans=virtio" "version=9p2000.L" "cache=loose" ];
449+ options = [ "trans=virtio" "version=9p2000.L" "veryloose" ];
450 neededForBoot = true;
450 neededForBoot = true;
451 };
451 };
452 "/tmp/shared" =
452 "/tmp/shared" =
pkgs/build-support/vm/default.nix+2−2
@@ -130,7 +130,7 @@ rec {
130
130
131 echo "mounting Nix store..."
131 echo "mounting Nix store..."
132 mkdir -p /fs${storeDir}
132 mkdir -p /fs${storeDir}
133− mount -t 9p store /fs${storeDir} -o trans=virtio,version=9p2000.L,cache=loose
133+ mount -t 9p store /fs${storeDir} -o trans=virtio,version=9p2000.L,veryloose
134
134
135 mkdir -p /fs/tmp /fs/run /fs/var
135 mkdir -p /fs/tmp /fs/run /fs/var
136 mount -t tmpfs -o "mode=1777" none /fs/tmp
136 mount -t tmpfs -o "mode=1777" none /fs/tmp
@@ -139,7 +139,7 @@ rec {
139
139
140 echo "mounting host's temporary directory..."
140 echo "mounting host's temporary directory..."
141 mkdir -p /fs/tmp/xchg
141 mkdir -p /fs/tmp/xchg
142− mount -t 9p xchg /fs/tmp/xchg -o trans=virtio,version=9p2000.L,cache=loose
142+ mount -t 9p xchg /fs/tmp/xchg -o trans=virtio,version=9p2000.L,veryloose
143
143
144 mkdir -p /fs/proc
144 mkdir -p /fs/proc
145 mount -t proc none /fs/proc
145 mount -t proc none /fs/proc
pkgs/os-specific/linux/kernel/patches.nix+9
@@ -175,4 +175,13 @@ rec {
175 };
175 };
176 };
176 };
177
177
178+ p9_caching_4_4 = rec
179+ { name = "9p-caching.patch";
180+ patch = fetchpatch {
181+ inherit name;
182+ url = https://github.com/edolstra/linux/commit/d522582553368b9564e2d88a8d7b1d469bf98c65.patch;
183+ sha256 = "01h7461pdgavd6ghd6w9wg136hkaca0mrmmzhy6s3phksksimbc2";
184+ };
185+ };
186+
178}
187}
pkgs/top-level/all-packages.nix+1
@@ -11069,6 +11069,7 @@ in
11069 kernelPatches =
11069 kernelPatches =
11070 [ kernelPatches.bridge_stp_helper
11070 [ kernelPatches.bridge_stp_helper
11071 kernelPatches.cpu-cgroup-v2."4.4"
11071 kernelPatches.cpu-cgroup-v2."4.4"
11072+ kernelPatches.p9_caching_4_4
11072 ]
11073 ]
11073 ++ lib.optionals ((platform.kernelArch or null) == "mips")
11074 ++ lib.optionals ((platform.kernelArch or null) == "mips")
11074 [ kernelPatches.mips_fpureg_emu
11075 [ kernelPatches.mips_fpureg_emu