From nobody Wed Dec 31 12:32:23 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D877CC4167B for ; Sun, 5 Nov 2023 11:35:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230410AbjKELfU (ORCPT ); Sun, 5 Nov 2023 06:35:20 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58204 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230236AbjKELfK (ORCPT ); Sun, 5 Nov 2023 06:35:10 -0500 Received: from todd.t-8ch.de (todd.t-8ch.de [159.69.126.157]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0AF97E1; Sun, 5 Nov 2023 03:35:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=weissschuh.net; s=mail; t=1699184102; bh=IdJFXFy2rUhosoH8Z7h6MB9DWZTcM5ZHRroV78U+Fiw=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=aQnhtEh4oHnnVRhhOMGSxfSYjJY8wGO/yqMvBBwPv7MsQ+hUu15HzjWjM6EzPMXW0 ghAOBZ/OpaLrcWc7aKgKMYdpV0uTb3lzcS/oqS2GWTNdZ9n2qKUIyRneCIpPFpjVrp GBmwNIxwKAt14r8Uz6lbBupZPeZo5RKYKzGEWbMg= From: =?utf-8?q?Thomas_Wei=C3=9Fschuh?= Date: Sun, 05 Nov 2023 12:35:00 +0100 Subject: [PATCH v2 3/6] selftests/nolibc: use XARCH for MIPS MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20231105-nolibc-mips-be-v2-3-4ec993cb5407@weissschuh.net> References: <20231105-nolibc-mips-be-v2-0-4ec993cb5407@weissschuh.net> In-Reply-To: <20231105-nolibc-mips-be-v2-0-4ec993cb5407@weissschuh.net> To: Willy Tarreau , Shuah Khan Cc: Zhangjin Wu , linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, =?utf-8?q?Thomas_Wei=C3=9Fschuh?= X-Mailer: b4 0.12.4 X-Developer-Signature: v=1; a=ed25519-sha256; t=1699184102; l=4274; i=linux@weissschuh.net; s=20221212; h=from:subject:message-id; bh=IdJFXFy2rUhosoH8Z7h6MB9DWZTcM5ZHRroV78U+Fiw=; b=ilBW37jFgjSgNWl7vowrgRQbusU+xSSnJUlYm4CP5feL39NDJ8YsItziynNCdK0syWRtcrgi4 +8BzjAQeX7eDVyaAzOq7uwqnbvGyFDQcIKnZHAbY/NwPzRSW8Uk3Lte X-Developer-Key: i=linux@weissschuh.net; a=ed25519; pk=KcycQgFPX2wGR5azS7RhpBqedglOZVgRPfdFSPB1LNw= Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org MIPS has many different configurations prepare the support of additional ones by moving the build of MIPS to the generic XARCH infrastructure. Signed-off-by: Thomas Wei=C3=9Fschuh Acked-by: Willy Tarreau --- tools/testing/selftests/nolibc/Makefile | 12 +++++++----- tools/testing/selftests/nolibc/run-tests.sh | 2 +- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/tools/testing/selftests/nolibc/Makefile b/tools/testing/selfte= sts/nolibc/Makefile index c5df1617cbc3..71fa5fdd10b6 100644 --- a/tools/testing/selftests/nolibc/Makefile +++ b/tools/testing/selftests/nolibc/Makefile @@ -40,12 +40,14 @@ objtree ?=3D $(srctree) =20 # configure default variants for target kernel supported architectures XARCH_powerpc =3D ppc +XARCH_mips =3D mips32le XARCH =3D $(or $(XARCH_$(ARCH)),$(ARCH)) =20 # map from user input variants to their kernel supported architectures ARCH_ppc =3D powerpc ARCH_ppc64 =3D powerpc ARCH_ppc64le =3D powerpc +ARCH_mips32le =3D mips ARCH :=3D $(or $(ARCH_$(XARCH)),$(XARCH)) =20 # kernel image names by architecture @@ -54,7 +56,7 @@ IMAGE_x86_64 =3D arch/x86/boot/bzImage IMAGE_x86 =3D arch/x86/boot/bzImage IMAGE_arm64 =3D arch/arm64/boot/Image IMAGE_arm =3D arch/arm/boot/zImage -IMAGE_mips =3D vmlinuz +IMAGE_mips32le =3D vmlinuz IMAGE_ppc =3D vmlinux IMAGE_ppc64 =3D vmlinux IMAGE_ppc64le =3D arch/powerpc/boot/zImage @@ -70,7 +72,7 @@ DEFCONFIG_x86_64 =3D defconfig DEFCONFIG_x86 =3D defconfig DEFCONFIG_arm64 =3D defconfig DEFCONFIG_arm =3D multi_v7_defconfig -DEFCONFIG_mips =3D malta_defconfig +DEFCONFIG_mips32le =3D malta_defconfig DEFCONFIG_ppc =3D pmac32_defconfig DEFCONFIG_ppc64 =3D powernv_be_defconfig DEFCONFIG_ppc64le =3D powernv_defconfig @@ -88,7 +90,7 @@ QEMU_ARCH_x86_64 =3D x86_64 QEMU_ARCH_x86 =3D x86_64 QEMU_ARCH_arm64 =3D aarch64 QEMU_ARCH_arm =3D arm -QEMU_ARCH_mips =3D mipsel # works with malta_defconfig +QEMU_ARCH_mips32le =3D mipsel # works with malta_defconfig QEMU_ARCH_ppc =3D ppc QEMU_ARCH_ppc64 =3D ppc64 QEMU_ARCH_ppc64le =3D ppc64 @@ -110,7 +112,7 @@ QEMU_ARGS_x86_64 =3D -M pc -append "console=3DttyS0= ,9600 i8042.noaux panic=3D-1 $( QEMU_ARGS_x86 =3D -M pc -append "console=3DttyS0,9600 i8042.noaux p= anic=3D-1 $(TEST:%=3DNOLIBC_TEST=3D%)" QEMU_ARGS_arm64 =3D -M virt -cpu cortex-a53 -append "panic=3D-1 $(TES= T:%=3DNOLIBC_TEST=3D%)" QEMU_ARGS_arm =3D -M virt -append "panic=3D-1 $(TEST:%=3DNOLIBC_TES= T=3D%)" -QEMU_ARGS_mips =3D -M malta -append "panic=3D-1 $(TEST:%=3DNOLIBC_TE= ST=3D%)" +QEMU_ARGS_mips32le =3D -M malta -append "panic=3D-1 $(TEST:%=3DNOLIBC_TE= ST=3D%)" QEMU_ARGS_ppc =3D -M g3beige -append "console=3DttyS0 panic=3D-1 $(= TEST:%=3DNOLIBC_TEST=3D%)" QEMU_ARGS_ppc64 =3D -M powernv -append "console=3Dhvc0 panic=3D-1 $(T= EST:%=3DNOLIBC_TEST=3D%)" QEMU_ARGS_ppc64le =3D -M powernv -append "console=3Dhvc0 panic=3D-1 $(T= EST:%=3DNOLIBC_TEST=3D%)" @@ -134,7 +136,7 @@ CFLAGS_ppc =3D -m32 -mbig-endian -mno-vsx $(call cc-opt= ion,-mmultiple) CFLAGS_ppc64 =3D -m64 -mbig-endian -mno-vsx $(call cc-option,-mmultiple) CFLAGS_ppc64le =3D -m64 -mlittle-endian -mno-vsx $(call cc-option,-mabi=3D= elfv2) CFLAGS_s390 =3D -m64 -CFLAGS_mips =3D -EL +CFLAGS_mips32le =3D -EL CFLAGS_STACKPROTECTOR ?=3D $(call cc-option,-mstack-protector-guard=3Dglob= al $(call cc-option,-fstack-protector-all)) CFLAGS ?=3D -Os -fno-ident -fno-asynchronous-unwind-tables -std=3Dc89 -W = -Wall -Wextra \ $(call cc-option,-fno-stack-protector) \ diff --git a/tools/testing/selftests/nolibc/run-tests.sh b/tools/testing/se= lftests/nolibc/run-tests.sh index 1bf020d49f54..8f2c3bc572cb 100755 --- a/tools/testing/selftests/nolibc/run-tests.sh +++ b/tools/testing/selftests/nolibc/run-tests.sh @@ -14,7 +14,7 @@ cache_dir=3D"${XDG_CACHE_HOME:-"$HOME"/.cache}" download_location=3D"${cache_dir}/crosstools/" build_location=3D"$(realpath "${cache_dir}"/nolibc-tests/)" perform_download=3D0 -archs=3D"i386 x86_64 arm64 arm mips ppc ppc64 ppc64le riscv s390 loongarch" +archs=3D"i386 x86_64 arm64 arm mips32le ppc ppc64 ppc64le riscv s390 loong= arch" =20 TEMP=3D$(getopt -o 'j:d:c:b:a:ph' -n "$0" -- "$@") =20 --=20 2.42.1