From: Joel Fernandes <joel@joelfernandes.org>
To: Masahiro Yamada <yamada.masahiro@socionext.com>
Cc: linux-kbuild@vger.kernel.org, Sam Ravnborg <sam@ravnborg.org>,
Tony Luck <tony.luck@intel.com>,
John Fastabend <john.fastabend@gmail.com>,
Jakub Kicinski <jakub.kicinski@netronome.com>,
Daniel Borkmann <daniel@iogearbox.net>,
xdp-newbies@vger.kernel.org, Anton Vorontsov <anton@enomsg.org>,
Matthias Brugger <matthias.bgg@gmail.com>,
Song Liu <songliubraving@fb.com>, Yonghong Song <yhs@fb.com>,
Michal Marek <michal.lkml@markovi.net>,
Jesper Dangaard Brouer <hawk@kernel.org>,
Martin KaFai Lau <kafai@fb.com>,
linux-mediatek@lists.infradead.org,
linux-arm-kernel@lists.infradead.org,
Colin Cross <ccross@android.com>,
"David S. Miller" <davem@davemloft.net>,
Kees Cook <keescook@chromium.org>,
Alexei Starovoitov <ast@kernel.org>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
bpf@vger.kernel.org
Subject: Re: [PATCH 7/7] kbuild: compile-test kernel headers to ensure they are self-contained
Date: Tue, 2 Jul 2019 12:47:12 -0400 [thread overview]
Message-ID: <20190702164712.GA98338@google.com> (raw)
In-Reply-To: <20190701005845.12475-8-yamada.masahiro@socionext.com>
On Mon, Jul 01, 2019 at 09:58:45AM +0900, Masahiro Yamada wrote:
> The headers in include/ are globally used in the kernel source tree
> to provide common APIs. They are included from external modules, too.
>
> It will be useful to make as many headers self-contained as possible
> so that we do not have to rely on a specific include order.
>
> There are more than 4000 headers in include/. In my rough analysis,
> 70% of them are already self-contained. With efforts, most of them
> can be self-contained.
>
> For now, we must exclude more than 1000 headers just because they
> cannot be compiled as standalone units. I added them to header-test-.
> The blacklist was mostly generated by a script, so the reason of the
> breakage should be checked later.
>
> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
> Tested-by: Jani Nikula <jani.nikula@intel.com>
> ---
>
> Changes in v4:
> - Fix vmlinux build error
> - Exclude more headers for sparc
>
> Changes in v3:
> - Exclude more headers
> (Tested for allnoconfig + CONFIG_HEADER_TEST=y)
>
> Changes in v2:
> - Add everything to test coverage, and exclude broken ones
> - Rename 'Makefile' to 'Kbuild'
> - Add CONFIG_KERNEL_HEADER_TEST option
>
> Makefile | 1 +
> include/Kbuild | 1253 ++++++++++++++++++++++++++++++++++++++++++++++++
> init/Kconfig | 11 +
> 3 files changed, 1265 insertions(+)
> create mode 100644 include/Kbuild
[snip
> diff --git a/init/Kconfig b/init/Kconfig
> index 74192de8ada6..e2e99544da8d 100644
> --- a/init/Kconfig
> +++ b/init/Kconfig
> @@ -108,6 +108,17 @@ config HEADER_TEST
> If you are a developer or tester and want to ensure the requested
> headers are self-contained, say Y here. Otherwise, choose N.
>
> +config KERNEL_HEADER_TEST
> + bool "Compile test kernel headers"
> + depends on HEADER_TEST
> + help
> + Headers in include/ are used to build external moduls.
Nit:
modules.
Otherwise lgtm, thanks for the cc.
Reviewed-by: Joel Fernandes (Google) <joel@joelfernandes.org>
prev parent reply other threads:[~2019-07-02 16:47 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-01 0:58 [PATCH 0/7] Compile-test UAPI and kernel headers Masahiro Yamada
2019-07-01 0:58 ` [PATCH 1/7] init/Kconfig: add CONFIG_CC_CAN_LINK Masahiro Yamada
2019-07-01 0:58 ` [PATCH 2/7] kbuild: compile-test exported headers to ensure they are self-contained Masahiro Yamada
2019-07-01 0:58 ` [PATCH 7/7] kbuild: compile-test kernel " Masahiro Yamada
2019-07-02 16:47 ` Joel Fernandes [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190702164712.GA98338@google.com \
--to=joel@joelfernandes.org \
--cc=anton@enomsg.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=ccross@android.com \
--cc=daniel@iogearbox.net \
--cc=davem@davemloft.net \
--cc=hawk@kernel.org \
--cc=jakub.kicinski@netronome.com \
--cc=john.fastabend@gmail.com \
--cc=kafai@fb.com \
--cc=keescook@chromium.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kbuild@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=matthias.bgg@gmail.com \
--cc=michal.lkml@markovi.net \
--cc=netdev@vger.kernel.org \
--cc=sam@ravnborg.org \
--cc=songliubraving@fb.com \
--cc=tony.luck@intel.com \
--cc=xdp-newbies@vger.kernel.org \
--cc=yamada.masahiro@socionext.com \
--cc=yhs@fb.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).