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]
Date:   Fri, 27 Jan 2023 17:21:51 +0100
From:   Matthieu Baerts <matthieu.baerts@...sares.net>
To:     Mathieu Desnoyers <mathieu.desnoyers@...icios.com>,
        Shuah Khan <shuah@...nel.org>, linux-kselftest@...r.kernel.org,
        Ingo Molnar <mingo@...hat.com>
Cc:     linux-kernel@...r.kernel.org, stable@...r.kernel.org
Subject: Re: [PATCH 17/34] selftests: net: Fix incorrect kernel headers search
 path

Hi Mathieu,

On 27/01/2023 14:57, Mathieu Desnoyers wrote:
> Use $(KHDR_INCLUDES) as lookup path for kernel headers. This prevents
> building against kernel headers from the build environment in scenarios
> where kernel headers are installed into a specific output directory
> (O=...).

Thank you for the patch!

> Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@...icios.com>
> Cc: Shuah Khan <shuah@...nel.org>
> Cc: linux-kselftest@...r.kernel.org
> Cc: Ingo Molnar <mingo@...hat.com>
> Cc: <stable@...r.kernel.org>    [5.18+]

(It might be useful to add a "Fixes" tag as well to clearly indicate the
dependence with a specific commit and better understand the fix.)

(and add all the individual maintainers of the files you modify -- feel
free to use 'b4' to help you for this task ;-) )

(...)

> diff --git a/tools/testing/selftests/net/mptcp/Makefile b/tools/testing/selftests/net/mptcp/Makefile
> index 43a723626126..06bba013bcef 100644
> --- a/tools/testing/selftests/net/mptcp/Makefile
> +++ b/tools/testing/selftests/net/mptcp/Makefile
> @@ -2,7 +2,7 @@
>  
>  top_srcdir = ../../../../..
>  
> -CFLAGS =  -Wall -Wl,--no-as-needed -O2 -g -I$(top_srcdir)/usr/include $(KHDR_INCLUDES)
> +CFLAGS =  -Wall -Wl,--no-as-needed -O2 -g $(KHDR_INCLUDES)

I only looked at the modification here with MPTCP selftests and it looks
good to me. It makes sense because if KHDR_INCLUDES is not set, it will
be set later by lib.mk I suppose.

Just one small thing: I guess you can also remove "top_srcdir" variable
that is no longer used, right? I see that "lib.mk" uses a variable with
the same name but it overrides its value anyway. But it is likely I
missed something there :)

If indeed it is no longer needed, I guess a few Makefile can be adapted
according to:

  git grep top_srcdir -- tools/testing/selftests/*/

I guess most of these Makefile are very similar, no? For MPTCP, we
simply looked at what was done elsewhere :)

Cheers,
Matt
-- 
Tessares | Belgium | Hybrid Access Solutions
www.tessares.net

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ