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: <ZKyGh8AKRLobQKlX@finisterre.sirena.org.uk>
Date:   Mon, 10 Jul 2023 23:30:31 +0100
From:   Mark Brown <broonie@...nel.org>
To:     John Hubbard <jhubbard@...dia.com>
Cc:     Shuah Khan <shuah@...nel.org>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Anders Roxell <anders.roxell@...aro.org>,
        Muhammad Usama Anjum <usama.anjum@...labora.com>,
        linux-kselftest@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-arm-kernel@...ts.infradead.org
Subject: Re: [PATCH] selftests: Fix arm64 test installation

On Mon, Jul 10, 2023 at 02:31:56PM -0700, John Hubbard wrote:
> On 7/10/23 14:20, Mark Brown wrote:

> > There are no such thing as far as I am aware - the arm64 selftests are
> > *very* actively used by a range of people and CI systems, I certainly
> > build them pretty consistently and am aware of no build failures with
> > either GCC or clang.  You do need to install the headers to get the
> > current APIs but until your commit everything was building cleanly.

> > If you are seeing any problems please report them.

> oh wow, yes, I am! It's on a slightly older installation (gcc version
> 8.5.0 20210514 (Red Hat 8.5.0-18)), but there are a lot of basic build
> failures, I'll get them together and send out a note.

There is a floor on binutils version for the kselftests that's more
aggressive than that for the kernel itself, though that looks like RHEL
8 which has binutils 2.30 which *should* be fine for most things - the
MTE tests won't build but they do have version detection so should skip,
I guess you might have trouble with PAC support which doesn't have
detection in the tests?  It's certainly old enough that I'm surprised to
hear someone doing development for anything current with it.

I just tried a Debian based GCC 8 container which seems pretty happy
for arm64, the command was:

make -j16 O=/tmp/out INSTALL_PATH=/tmp/kselftest \
	ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- \
	CROSS_COMPILE_COMPAT=arm-linux-gnueabihf- kselftest-install

(the compat toolchain isn't used here IIRC).  It does skip the MTE tests
but otherwise isn't showing any obvious issues in the arm64 tests.

> Meanwhile, if you would like to try a quick fix, I have one that fixes
> the problem on my system. I'm inclined to dress it up with a comment
> that explains it (with a "TODO: stop using recursive Make here"), and
> send it out as an actual fix:
> 
> diff --git a/tools/testing/selftests/arm64/Makefile b/tools/testing/selftests/arm64/Makefile
> index 9460cbe81bcc..ace8b67fb22d 100644
> --- a/tools/testing/selftests/arm64/Makefile
> +++ b/tools/testing/selftests/arm64/Makefile
> @@ -42,7 +42,7 @@ run_tests: all
>         done
>  # Avoid any output on non arm64 on emit_tests
> -emit_tests: all
> +emit_tests:
>         @for DIR in $(ARM64_SUBTARGETS); do                             \
>                 BUILD_TARGET=$(OUTPUT)/$$DIR;                   \
>                 make OUTPUT=$$BUILD_TARGET -C $$DIR $@;         \

That does seem to work around the issue at least with a quick out of
tree build, including with GCC 8.

Download attachment "signature.asc" of type "application/pgp-signature" (489 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ