From bda6c82a8162ebbf3c25e028992a4b8a9c323065 Mon Sep 17 00:00:00 2001 From: Maximilian Bosch Date: Sat, 12 Oct 2024 16:43:31 +0200 Subject: [PATCH] linux_testing: disable NFS_LOCALIO on aarch64-linux This breaks the build like this: /nix/store/f3k0rdhcd2cx57phx755c2xixgifw5m5-binutils-2.42/bin/ld: Unexpected GOT/PLT entries detected! /nix/store/f3k0rdhcd2cx57phx755c2xixgifw5m5-binutils-2.42/bin/ld: Unexpected run-time procedure linkages detected! /nix/store/f3k0rdhcd2cx57phx755c2xixgifw5m5-binutils-2.42/bin/ld: fs/nfs/localio.o: in function `nfs_local_iocb_alloc': /build/source/build/../fs/nfs/localio.c:290:(.text+0x324): undefined reference to `nfs_to' [...] Reported as https://lore.kernel.org/all/D4OUJRP8YWRM.ATQ7KASTYX5H@mbosch.me/ --- pkgs/os-specific/linux/kernel/common-config.nix | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pkgs/os-specific/linux/kernel/common-config.nix b/pkgs/os-specific/linux/kernel/common-config.nix index 91b57676abca..e60513b57095 100644 --- a/pkgs/os-specific/linux/kernel/common-config.nix +++ b/pkgs/os-specific/linux/kernel/common-config.nix @@ -639,7 +639,10 @@ let NFS_V4_1 = yes; # NFSv4.1 client support NFS_V4_2 = yes; NFS_V4_SECURITY_LABEL = yes; - NFS_LOCALIO = whenAtLeast "6.12" yes; + + # Fails with + # `fs/nfs/localio.o: relocation R_AARCH64_ADR_PREL_PG_HI21 against symbol `nfs_to' which may bind externally can not be used when making a shared object; recompile with -fPIC` + NFS_LOCALIO = lib.mkIf (!stdenv.hostPlatform.isAarch64) (whenAtLeast "6.12" yes); CIFS_XATTR = yes; CIFS_POSIX = option yes;