From nobody Sat Feb 7 15:40:39 2026 Received: from mail-pg1-f178.google.com (mail-pg1-f178.google.com [209.85.215.178]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 879AB1C4A24 for ; Mon, 2 Feb 2026 13:21:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.215.178 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770038510; cv=none; b=Viepm4k/VBt0bngvtFqJcUkxYJb+fgH4WyaIllbPFRKhGgqmUfpWIM7zSzQvP/hxWMsWN6/rktbBhogB83m5ZE3Hlh+iAR+wrr04pEm0VJe1IChEhgorI1mu+1yNnBSjEJ1Gl9/pAGNnNDKypSUudUjWxIvgv/fGchnlqxmGQgY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770038510; c=relaxed/simple; bh=FqXQYRZYmqIBixULrrVa+eEZKmy3PXhlCAE3r5OaLEM=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=ZQDmp2onITboGxOQm+je6mLqUyCv2J2jGkLUTaXgaOfDea0RsJZvfadexKhmBck0skmXIvjGjz2rEcmuJcpT3sotGWVY0/qTVOFpSplrQDx9+ioJkNFk68akmkQbNSYARw0pGEDbhNIXmI1SAB3XJ4ptWOMUbdXs8V2TriwTMvs= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=T30zEBDb; arc=none smtp.client-ip=209.85.215.178 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="T30zEBDb" Received: by mail-pg1-f178.google.com with SMTP id 41be03b00d2f7-bde0f62464cso1679620a12.2 for ; Mon, 02 Feb 2026 05:21:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1770038509; x=1770643309; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=HucOyefr0+DyglbTjyjmO2oyIxVd3mwUnC9ssIIiMtI=; b=T30zEBDbCp/amjBeUxmfuFp6GNx4nihecdA/y8tFdiiEHcn8XQorzw/7M7VjaobMf5 Yy5586gkzq740Uwryzpqa3A/026YZc3ce0RJ4rCD5PXADXkLXJu6sUdT9TXj2s3uYc1/ 4M24b7ILEMVoa0TOV+WS3Mbu//cGtWrYEvE0kd6KyyfI1LcGVLCLrUc7Lmv62r/pMmR4 L5dlGEkm5APXCi55CjQRCZKffdiLJlP3dsIavOfGQsxfc7FspI08/uRwPrhb7zA7qPSi KVkrwnHdeFIWkzOU0t3usVfiy/TxJ7TV098af7uPGOvyU1K8GILmTruiiB2CivN4+YJd KwlA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1770038509; x=1770643309; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=HucOyefr0+DyglbTjyjmO2oyIxVd3mwUnC9ssIIiMtI=; b=XLawPa/PkSjKRCszEoil/SmF3JvoysvQtU+yiVpTWXrTaunSqq8fy66yAdt8L3XvIk qZeREtOSF4C0CRjpRy2Fc0joOj0GoYh65WR12A4GppKgUVOvRbxKUscpi2xp+x2fZ4YE Ij7SXAK7cRg/boJsXHxIfVnRxENxI6D6x6kzIPsrqod/3LZ2m1FKjO8x0iHSRaHMXPPD AdjjcTXAAb/Hc5KTJTnjqWsbaTz1IOQnmQQKwPXM9fYXZXwqyrNdWZbsHre43MLdXA40 6W5yxhR9a0PNifi6DVRQDQVyslfz74jbI3e/gB93Q6M0LCjRMssF4kW/SgvjHZaMsGK0 sXwA== X-Forwarded-Encrypted: i=1; AJvYcCWiphDZ+pJGr1AhwlUy3NHkhpmwgizh4sC3uw+MztLb8JgvJbIIpteqON6KBUQK0s0AW0qe/u1PsZwGgss=@vger.kernel.org X-Gm-Message-State: AOJu0YzwNATyMzxJtibSqMK/PdrRrXuisz0xAz7kQCXbHDbC1MXwMbIF 89zPBrQbT/9jO1u9av8Nk0ICqOvwNgZMZxp99taZEDREvkAtccfzP2WGegpstNnw X-Gm-Gg: AZuq6aLY/B+ydeu5oV8DmbxbKrlhvL/D2ur+q3yAZrNGKydiBquNyzxZfHNCfoGFg4/ rB+99MFcTB94xaMFvreld3ppcjxaGO2gS7WuvHRc3nkPF7jFJA7DV1Co52nHBOBfhS6tzn8erop +v/kL3Pg1/3XqJulZytNteMr38XpPVZQvz4NszCd0Bp/W0SDHy4ZJtJoTuN7U6wjcCBiC82IdTn A+phy7gnl7jtCWM+10AJUM6VvfxddKU2ZJReQU6CiBVZJJ/RhRdxDLMlt6YCp0XDWX7JjenQrD+ oNSH98hs8Ir+d87FH9pC5xUk+WhmOE6LyPETaem1aYYaoEVcgRHjzYjiED1SAxLr2TQ1bFAJJ83 mqQVTQq2K7NaNo6Ggawg+kKTUuvvQ2sljXt4LLDF+NGC+MehcxPkulNvhJ2fX3FiOy1qXLwgOrh 5axujFwzjhq2V2mQ== X-Received: by 2002:a17:902:e801:b0:2a0:d59e:3c9e with SMTP id d9443c01a7336-2a8d80382dfmr121202625ad.33.1770038508821; Mon, 02 Feb 2026 05:21:48 -0800 (PST) Received: from misys ([58.120.241.145]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-2a8c3a23e40sm119569895ad.90.2026.02.02.05.21.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 Feb 2026 05:21:48 -0800 (PST) From: HeeSu Kim To: ojeda@kernel.org Cc: boqun@google.com, gary@garyguo.net, bjorn3_gh@protonmail.com, lossin@kernel.org, a.hindborg@kernel.org, aliceryhl@google.com, tmgross@umich.edu, dakr@kernel.org, rust-for-linux@vger.kernel.org, linux-kernel@vger.kernel.org, HeeSu Kim Subject: [PATCH] rust: Makefile: apply fixed-x18 workaround only on arm64 Date: Tue, 3 Feb 2026 07:21:44 +0900 Message-ID: <20260202222144.2689495-1-mlksvender@gmail.com> X-Mailer: git-send-email 2.52.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The `-Cunsafe-allow-abi-mismatch=3Dfixed-x18` option is a workaround for a rustdoc issue (rust-lang/rust#144521) where target modifiers were not properly saved. This affects both rustdoc and doctests builds. However, `fixed-x18` is an ARM64-specific ABI modifier related to the x18 register reservation (used for Shadow Call Stack). Currently, this workaround is applied unconditionally on all architectures, which is incorrect and may cause issues on non-ARM64 builds. Restrict the workaround to only apply when building for arm64 (SRCARCH=3Darm64). Fixes: 68e8e79e1bdc ("rust: fix `rustdoc` target modifiers") Signed-off-by: HeeSu Kim --- rust/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/rust/Makefile b/rust/Makefile index 5c0155b83..2bd547611 100644 --- a/rust/Makefile +++ b/rust/Makefile @@ -136,7 +136,8 @@ pin_init-flags :=3D \ =20 # `rustdoc` did not save the target modifiers, thus workaround for # the time being (https://github.com/rust-lang/rust/issues/144521). -rustdoc_modifiers_workaround :=3D $(if $(call rustc-min-version,108800),-C= unsafe-allow-abi-mismatch=3Dfixed-x18) +# The `fixed-x18` modifier is ARM64-specific, so only apply it there. +rustdoc_modifiers_workaround :=3D $(if $(filter arm64,$(SRCARCH)),$(if $(c= all rustc-min-version,108800),-Cunsafe-allow-abi-mismatch=3Dfixed-x18)) =20 # Similarly, for doctests (https://github.com/rust-lang/rust/issues/146465= ). doctests_modifiers_workaround :=3D $(rustdoc_modifiers_workaround)$(if $(c= all rustc-min-version,109100),$(comma)sanitizer) --=20 2.52.0