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] [day] [month] [year] [list]
Message-ID: <YEYpjqar4SW08CTK@kernel.org>
Date:   Mon, 8 Mar 2021 10:41:34 -0300
From:   Arnaldo Carvalho de Melo <acme@...nel.org>
To:     Daniel Borkmann <daniel@...earbox.net>
Cc:     Ian Rogers <irogers@...gle.com>,
        Peter Zijlstra <peterz@...radead.org>,
        Ingo Molnar <mingo@...hat.com>,
        Mark Rutland <mark.rutland@....com>,
        Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
        Jiri Olsa <jolsa@...hat.com>,
        Namhyung Kim <namhyung@...nel.org>,
        Song Liu <songliubraving@...com>, linux-kernel@...r.kernel.org,
        Alexei Starovoitov <ast@...nel.org>,
        Andrii Nakryiko <andrii@...nel.org>,
        Martin KaFai Lau <kafai@...com>, Yonghong Song <yhs@...com>,
        John Fastabend <john.fastabend@...il.com>,
        KP Singh <kpsingh@...nel.org>,
        Tiezhu Yang <yangtiezhu@...ngson.cn>, netdev@...r.kernel.org,
        bpf@...r.kernel.org, Stephane Eranian <eranian@...gle.com>
Subject: Re: [PATCH] tools include: Add __sum16 and __wsum definitions.

Em Mon, Mar 08, 2021 at 02:37:32PM +0100, Daniel Borkmann escreveu:
> On 3/7/21 11:30 PM, Ian Rogers wrote:
> > This adds definitions available in the uapi version.
> > 
> > Explanation:
> > In the kernel include of types.h the uapi version is included.
> > In tools the uapi/linux/types.h and linux/types.h are distinct.
> > For BPF programs a definition of __wsum is needed by the generated
> > bpf_helpers.h. The definition comes either from a generated vmlinux.h or
> > from <linux/types.h> that may be transitively included from bpf.h. The
> > perf build prefers linux/types.h over uapi/linux/types.h for
> > <linux/types.h>*. To allow tools/perf/util/bpf_skel/bpf_prog_profiler.bpf.c
> > to compile with the same include path used for perf then these
> > definitions are necessary.
> > 
> > There is likely a wider conversation about exactly how types.h should be
> > specified and the include order used by the perf build - it is somewhat
> > confusing that tools/include/uapi/linux/bpf.h is using the non-uapi
> > types.h.
> > 
> > *see tools/perf/Makefile.config:
> > ...
> > INC_FLAGS += -I$(srctree)/tools/include/
> > INC_FLAGS += -I$(srctree)/tools/arch/$(SRCARCH)/include/uapi
> > INC_FLAGS += -I$(srctree)/tools/include/uapi
> > ...
> > The include directories are scanned from left-to-right:
> > https://gcc.gnu.org/onlinedocs/gcc/Directory-Options.html
> > As tools/include/linux/types.h appears before
> > tools/include/uapi/linux/types.h then I say it is preferred.
> > 
> > Signed-off-by: Ian Rogers <irogers@...gle.com>
> 
> Given more related to perf build infra, I presume Arnaldo would pick
> this one up?

I'll process it.

- Arnaldo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ