From nobody Thu Apr 9 14:59:51 2026 Received: from todd.t-8ch.de (todd.t-8ch.de [159.69.126.157]) (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 46F1A355F25; Sun, 8 Mar 2026 21:24:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=159.69.126.157 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773005049; cv=none; b=ftoKUb0DVF1aY0BsXHvvA5MjViVPYNcawM7M+vYyJNtSe0mkOvHHGx6mPyBFk28UCFDaqBqTuK6fFY2sG/YaeZi98Wdem61i0BsVJUyw3yRTBqq7h2tb2yyrzftsXHKphFRJ6+4SAvWWZWhT4/A4i+Sg9cKZUxK/2CNAD6baxaU= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773005049; c=relaxed/simple; bh=HwLfblw+VRZLHJdgjzQhIHg+sRaFcsc1K0c5qr+oBMY=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=frfoDmLm5wbkV4udeaF9dMnYVJKh09238czFybUFXuEtm4NLlqzKmFcJ1zW1qyb/pQXqmdru/Nv7c48xKx0nACuZ9SsZ5rigH+RGAjDETDzhBpec32txGFH7ViNn7PJP6faIg/FJtTJ6U/mUlP7PFOlZ9WInqqNpc/zljCkVk/o= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=weissschuh.net; spf=pass smtp.mailfrom=weissschuh.net; dkim=pass (1024-bit key) header.d=weissschuh.net header.i=@weissschuh.net header.b=ebT2VyAB; arc=none smtp.client-ip=159.69.126.157 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=weissschuh.net Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=weissschuh.net Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=weissschuh.net header.i=@weissschuh.net header.b="ebT2VyAB" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=weissschuh.net; s=mail; t=1773005045; bh=HwLfblw+VRZLHJdgjzQhIHg+sRaFcsc1K0c5qr+oBMY=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=ebT2VyABQsUQ5DK/pJmOfS9GUdwU6LaQk8qxfBLC2h3+okQrXd8PHg6Cz54yF0xwq likZpZziXxOcMUpBsaYwZbMAKWfa388RlQVWhBtmXlONKd/KkHUTrqWUeFwYOanYGj UaedLySmuNzei4jTPVwC1Le58INJVQsS3L4t5www= From: =?utf-8?q?Thomas_Wei=C3=9Fschuh?= Date: Sun, 08 Mar 2026 22:24:03 +0100 Subject: [PATCH RFC 3/5] kbuild: uapi: handle UML in architecture-specific exclusion lists 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: <20260308-kbuild-uapi-c-v1-3-86aae09a7f1d@weissschuh.net> References: <20260308-kbuild-uapi-c-v1-0-86aae09a7f1d@weissschuh.net> In-Reply-To: <20260308-kbuild-uapi-c-v1-0-86aae09a7f1d@weissschuh.net> To: Arnd Bergmann , Nathan Chancellor , Nicolas Schier Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, David Howells , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= X-Mailer: b4 0.14.3 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773005045; l=1749; i=linux@weissschuh.net; s=20221212; h=from:subject:message-id; bh=HwLfblw+VRZLHJdgjzQhIHg+sRaFcsc1K0c5qr+oBMY=; b=DIDGAfWpVSn7G2ouaCJofvVSnkFxYDIZQRSGfJxtScz56ikvQv5mWzrSigzV14hjhZO7nYBMm ZwakK5g3dZBAJ1ckmGOzCa8S+WqZ8s3ZQkMEO5YQdiN6bVsYie877+7 X-Developer-Key: i=linux@weissschuh.net; a=ed25519; pk=KcycQgFPX2wGR5azS7RhpBqedglOZVgRPfdFSPB1LNw= When building User Mode Linux SRCARCH is set to 'um', while the actual underlying architecture is provided in HEADER_ARCH. Allow the exclusion lists to work on UML by comparing against HEADER_ARCH when that is available. Signed-off-by: Thomas Wei=C3=9Fschuh --- usr/include/Makefile | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/usr/include/Makefile b/usr/include/Makefile index 74f5ba24bb29..edeaf9d778c4 100644 --- a/usr/include/Makefile +++ b/usr/include/Makefile @@ -7,6 +7,7 @@ # -std=3Dc90 (equivalent to -ansi) catches the violation of those. # We cannot go as far as adding -Wpedantic since it emits too many warning= s. UAPI_CFLAGS :=3D -std=3Dc90 -Werror=3Dimplicit-function-declaration +UAPI_ARCH :=3D $(or $(HEADER_ARCH),$(SRCARCH)) =20 override c_flags =3D $(KBUILD_USERCFLAGS) $(UAPI_CFLAGS) -Wp,-MMD,$(depfil= e) =20 @@ -48,11 +49,11 @@ no-header-test +=3D xen/privcmd.h =20 # More headers are broken in some architectures =20 -ifneq ($(filter arc openrisc xtensa nios2, $(SRCARCH)),) +ifneq ($(filter arc openrisc xtensa nios2, $(UAPI_ARCH)),) no-header-test +=3D linux/bpf_perf_event.h endif =20 -ifeq ($(SRCARCH),sparc) +ifeq ($(UAPI_ARCH),sparc) no-header-test +=3D asm/uctx.h no-header-test +=3D asm/fbio.h endif @@ -122,15 +123,15 @@ uses-libc +=3D linux/wireless.h uses-libc +=3D regulator/regulator.h uses-libc +=3D scsi/fc/fc_els.h =20 -ifeq ($(SRCARCH),hexagon) +ifeq ($(UAPI_ARCH),hexagon) uses-libc +=3D asm/sigcontext.h endif =20 -ifeq ($(SRCARCH),nios2) +ifeq ($(UAPI_ARCH),nios2) uses-libc +=3D asm/ptrace.h endif =20 -ifeq ($(SRCARCH),s390) +ifeq ($(UAPI_ARCH),s390) uses-libc +=3D asm/chpid.h uses-libc +=3D asm/chsc.h endif --=20 2.53.0