From nobody Tue Feb 10 01:30:56 2026 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8CCCF2DF14C for ; Tue, 30 Dec 2025 07:11:00 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=193.142.43.55 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767078662; cv=none; b=uevguvTbrx9t+eIa9f/kG+nyX1UOAivOiy3xiKcipg2ThqbWlbj9u5dsdD58zDJkbeRTuPTsh4uvGs7YyvnfMFC/O2fHtrci+J/r5JkqjpIpQpwiL0zRZNLB/j6uccx2R2y5otd3ZNLmhlHJIIUYEHJV5bSiFhP2heNOzQop6io= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767078662; c=relaxed/simple; bh=dlMzPHrReQ/pbAK9lXDYAAj3fJdbnf/meKB9Kt356Y8=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=VEYocys1t/YdWSsuwwogyznQzg884hKwA/uDrasXehQjTVrdyTacjQoy7yQR1ppkh5xOjlawwI4Ntt/69dXX+aEogLZw936MIyhUro7WzUu20kQi2wOG9nO0SX2EF2JpicrChEFJw9k0peLwJIx6LY+zTPtpq1/juOOImbRHBGc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de; spf=pass smtp.mailfrom=linutronix.de; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=EPru/JBd; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=CH3rtd9E; arc=none smtp.client-ip=193.142.43.55 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linutronix.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="EPru/JBd"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="CH3rtd9E" From: =?utf-8?q?Thomas_Wei=C3=9Fschuh?= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1767078658; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=j8y8y0Vihpsa7kuidmjsGKlmg3PpJ4ZCRAtbsIsvEA4=; b=EPru/JBdop90f20HwDMYpSDZfSu7RVm5ZonqWojoxnwP0ttp730pwGhgu+dcN2QcLVGnbo R1xPksWm/cDo8tOxhAzfTemulMqdtxAUiBnTeh/sgtOjFdbOnGdoafIFG8G1XWGOTUbnuV PvsiL59O3N5vAanT5C8+mFKWWiBSckzkZvPaZL4jwQvR4/dTsb8cJxHGMo33N8gIz3IGQB Y+6pGztPk3G/1Y/ek3HXKk9EPrHNR8vqsM/0Jps2yy42l3fYxQEUennmR5Bk4kB9BMhvYb Oby8T8BN8jGtTZKGcQcCvkdL5fkzFOfcaLa+Thgc8OZunk54ld/vJWUyx5R48w== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1767078658; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=j8y8y0Vihpsa7kuidmjsGKlmg3PpJ4ZCRAtbsIsvEA4=; b=CH3rtd9E772ePoMaKS1UNf/jOc7XYb1l2Rk95sRGGqKZAlJR3w34KPDweNubhBMDgyL4ld 4z38lK3DT3eCFEBg== Date: Tue, 30 Dec 2025 08:10:57 +0100 Subject: [PATCH 2/5] ARM: uapi: Stop leaking CONFIG_CPU_ENDIAN_BE8 reference to userspace Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20251230-headers_install-config-leak-v1-2-efba5c58073d@linutronix.de> References: <20251230-headers_install-config-leak-v1-0-efba5c58073d@linutronix.de> In-Reply-To: <20251230-headers_install-config-leak-v1-0-efba5c58073d@linutronix.de> To: Vineet Gupta , Russell King , Dinh Nguyen , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , x86@kernel.org, "H. Peter Anvin" Cc: linux-snps-arc@lists.infradead.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Arnd Bergmann , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= X-Developer-Signature: v=1; a=ed25519-sha256; t=1767078657; l=1602; i=thomas.weissschuh@linutronix.de; s=20240209; h=from:subject:message-id; bh=dlMzPHrReQ/pbAK9lXDYAAj3fJdbnf/meKB9Kt356Y8=; b=VfzyRNZ1kLHgDwyWyW6WGerkr2OPyUdHI92dxkNl9b8iSqPsOW9iadOCl6gKfQ3SCWmNwnWce BIxUeFaUYPOBS6RhRUr7D1L8LgIRkGJoyigr3HSPh05xywhCVZgb5ac X-Developer-Key: i=thomas.weissschuh@linutronix.de; a=ed25519; pk=pfvxvpFUDJV2h2nY0FidLUml22uGLSjByFbM6aqQQws= UAPI headers are not supposed to leak references to kconfig symbols. These won't be set when building userspace. Hide the kconfig reference behind 'if defined(__KERNEL__)', so it will be stripped by headers_install.sh, the same way other kconfig references in this file are handled. The result for userspace will be the same, but the exception in headers_install.sh can also be removed. Signed-off-by: Thomas Wei=C3=9Fschuh --- arch/arm/include/uapi/asm/ptrace.h | 2 +- scripts/headers_install.sh | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/arm/include/uapi/asm/ptrace.h b/arch/arm/include/uapi/asm= /ptrace.h index 8896c23ccba7..fe656da1701b 100644 --- a/arch/arm/include/uapi/asm/ptrace.h +++ b/arch/arm/include/uapi/asm/ptrace.h @@ -105,7 +105,7 @@ /* * Default endianness state */ -#ifdef CONFIG_CPU_ENDIAN_BE8 +#if defined(__KERNEL__) && defined(CONFIG_CPU_ENDIAN_BE8) #define PSR_ENDSTATE PSR_E_BIT #else #define PSR_ENDSTATE 0 diff --git a/scripts/headers_install.sh b/scripts/headers_install.sh index 727f7f82c2c7..4f03521f4026 100755 --- a/scripts/headers_install.sh +++ b/scripts/headers_install.sh @@ -70,7 +70,6 @@ configs=3D$(sed -e ' # # The format is : in each line. config_leak_ignores=3D" -arch/arm/include/uapi/asm/ptrace.h:CONFIG_CPU_ENDIAN_BE8 arch/nios2/include/uapi/asm/swab.h:CONFIG_NIOS2_CI_SWAB_NO arch/nios2/include/uapi/asm/swab.h:CONFIG_NIOS2_CI_SWAB_SUPPORT arch/x86/include/uapi/asm/auxvec.h:CONFIG_IA32_EMULATION --=20 2.52.0