All of lore.kernel.org
 help / color / mirror / Atom feed
From: Petr Vorel <petr.vorel@gmail.com>
To: stable@vger.kernel.org
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Sasha Levin <sashal@kernel.org>, Rich Felker <dalias@libc.org>,
	Peter Korsgaard <peter@korsgaard.com>,
	Baruch Siach <baruch@tkos.co.il>,
	Florian Weimer <fweimer@redhat.com>,
	Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [PATCH 1/1] uapi: move constants from <linux/kernel.h> to <linux/const.h>
Date: Fri, 1 Jan 2021 21:06:22 +0100	[thread overview]
Message-ID: <X++AviN6Zb75Yziv@pevik> (raw)
In-Reply-To: <20210101200308.22770-1-petr.vorel@gmail.com>

Hi,

> and include <linux/const.h> in UAPI headers instead of <linux/kernel.h>.

> commit a85cbe6159ffc973e5702f70a3bd5185f8f3c38d upstream.

> The reason is to avoid indirect <linux/sysinfo.h> include when using
> some network headers: <linux/netlink.h> or others -> <linux/kernel.h>
> -> <linux/sysinfo.h>.

> This indirect include causes on MUSL redefinition of struct sysinfo when
> included both <sys/sysinfo.h> and some of UAPI headers:

>     In file included from x86_64-buildroot-linux-musl/sysroot/usr/include/linux/kernel.h:5,
>                      from x86_64-buildroot-linux-musl/sysroot/usr/include/linux/netlink.h:5,
>                      from ../include/tst_netlink.h:14,
>                      from tst_crypto.c:13:
>     x86_64-buildroot-linux-musl/sysroot/usr/include/linux/sysinfo.h:8:8: error: redefinition of `struct sysinfo'
>      struct sysinfo {
>             ^~~~~~~
>     In file included from ../include/tst_safe_macros.h:15,
>                      from ../include/tst_test.h:93,
>                      from tst_crypto.c:11:
>     x86_64-buildroot-linux-musl/sysroot/usr/include/sys/sysinfo.h:10:8: note: originally defined here

> Link: https://lkml.kernel.org/r/20201015190013.8901-1-petr.vorel@gmail.com
> Signed-off-by: Petr Vorel <petr.vorel@gmail.com>
> Suggested-by: Rich Felker <dalias@aerifal.cx>
> Acked-by: Rich Felker <dalias@libc.org>
> Cc: Peter Korsgaard <peter@korsgaard.com>
> Cc: Baruch Siach <baruch@tkos.co.il>
> Cc: Florian Weimer <fweimer@redhat.com>
> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
> ---
> Hi,

> could this fix be backported to stable releases?
> Maybe safer to wait till v5.11 release.

> Adjusted for stable/linux-4.9.y.
I'm sorry, this one is for stable/linux-4.4.y

Kind regards,
Petr

  reply	other threads:[~2021-01-01 20:07 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-01 20:03 [PATCH 1/1] uapi: move constants from <linux/kernel.h> to <linux/const.h> Petr Vorel
2021-01-01 20:06 ` Petr Vorel [this message]
2021-01-04 10:29   ` Greg Kroah-Hartman
  -- strict thread matches above, loose matches on Subject: below --
2021-01-01 20:06 Petr Vorel
2021-01-01 20:10 Petr Vorel
2021-01-01 20:15 Petr Vorel

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=X++AviN6Zb75Yziv@pevik \
    --to=petr.vorel@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=baruch@tkos.co.il \
    --cc=dalias@libc.org \
    --cc=fweimer@redhat.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=peter@korsgaard.com \
    --cc=sashal@kernel.org \
    --cc=stable@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.