lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230729083530.GN956@1wt.eu>
Date:   Sat, 29 Jul 2023 10:35:30 +0200
From:   Willy Tarreau <w@....eu>
To:     Zhangjin Wu <falcon@...ylab.org>
Cc:     thomas@...ch.de, arnd@...db.de, linux-kernel@...r.kernel.org,
        linux-kselftest@...r.kernel.org
Subject: Re: [PATCH v3 06/12] selftests/nolibc: customize CROSS_COMPILE for
 32/64-bit powerpc

On Fri, Jul 28, 2023 at 04:28:17AM +0800, Zhangjin Wu wrote:
> The little-endian powerpc64le compilers provided by Ubuntu and Fedora
> are able to compile big endian kernel and big endian nolibc-test [1].
> 
> These default CROSS_COMPILE settings allow to test target architectures
> with:
> 
>     $ cd /path/to/tools/testing/selftests/nolibc/
> 
>     $ for arch in ppc ppc64 ppc64le; do \
>         make run-user ARCH=$arch | grep "status: "; \
>       done
> 
> If want to use another cross compiler, please simply pass CROSS_COMPILE
> or CC as before.
> 
> For example, it is able to build 64-bit nolibc-test with the big endian
> powerpc64-linux-gcc crosstool from [2]:
> 
>     $ wget -c https://mirrors.edge.kernel.org/pub/tools/crosstool/files/bin/x86_64/13.1.0/x86_64-gcc-13.1.0-nolibc-powerpc64-linux.tar.xz
>     $ tar xvf x86_64-gcc-13.1.0-nolibc-powerpc64-linux.tar.xz
>     $ export PATH=$PWD/gcc-13.1.0-nolibc/powerpc64-linux/bin/:$PATH
> 
>     $ export CROSS_COMPILE_ppc64=powerpc64-linux-
>     $ export CROSS_COMPILE_ppc64le=powerpc64-linux-
>     $ for arch in ppc64 ppc64le; do \
>         make run-user ARCH=$arch | grep "status: "; \
>       done
> 
> Or specify CC directly with full path:
> 
>     $ export CC=$PWD/gcc-13.1.0-nolibc/powerpc64-linux/bin/powerpc64-linux-gcc
>     $ for arch in ppc64 ppc64le; do \
>         make run-user ARCH=$arch | grep "status: "; \
>       done
> 
> [1]: https://github.com/open-power/skiboot
> [2]: https://mirrors.edge.kernel.org/pub/tools/crosstool/
> 
> Signed-off-by: Zhangjin Wu <falcon@...ylab.org>
> ---
>  tools/testing/selftests/nolibc/Makefile | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/tools/testing/selftests/nolibc/Makefile b/tools/testing/selftests/nolibc/Makefile
> index 3f15c7f7ef76..6385915d16c9 100644
> --- a/tools/testing/selftests/nolibc/Makefile
> +++ b/tools/testing/selftests/nolibc/Makefile
> @@ -46,6 +46,9 @@ IMAGE            = $(IMAGE_$(XARCH))
>  IMAGE_NAME       = $(notdir $(IMAGE))
>  
>  # CROSS_COMPILE: cross toolchain prefix by architecture
> +CROSS_COMPILE_ppc       ?= powerpc-linux-gnu-
> +CROSS_COMPILE_ppc64     ?= powerpc64le-linux-gnu-
> +CROSS_COMPILE_ppc64le   ?= powerpc64le-linux-gnu-
>  CROSS_COMPILE           ?= $(CROSS_COMPILE_$(XARCH))

It seems to me that this patch and the previous one were rather
for the PPC series as I'm not seeing the relation with the tiny
config here.

Willy

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ