[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAK7LNAS4zC0=Ptf2_ux6d=kXhWELeaV_tp6+ZBaD-oDKdCEfrA@mail.gmail.com>
Date: Mon, 29 Jul 2019 23:07:56 +0900
From: Masahiro Yamada <yamada.masahiro@...ionext.com>
To: Pablo Neira Ayuso <pablo@...filter.org>
Cc: Jozsef Kadlecsik <kadlec@...filter.org>,
Florian Westphal <fw@...len.de>,
Netfilter Development Mailing list
<netfilter-devel@...r.kernel.org>, coreteam@...filter.org,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] netfilter: add include guard to xt_connlabel.h
On Mon, Jul 29, 2019 at 10:15 PM Pablo Neira Ayuso <pablo@...filter.org> wrote:
>
> On Mon, Jul 29, 2019 at 12:51:38AM +0900, Masahiro Yamada wrote:
> > Add a header include guard just in case.
>
> Applied to nf.git, thanks.
>
> BTW, is the _UAPI_ prefix really needed? I can see netfilter headers
> under include/uapi/ sometimes are prefixed by UAPI and sometimes not.
The _UAPI prefix will be useful when you happen to
add the corresponding kernel-space header
since it is often the case to have the same name headers
for kernel-space and uapi.
For example, compare the include guards of the following.
include/linux/kernel.h
include/uapi/linux/kernel.h
Or, if you want to see an example for netfilter,
include/linux/netfilter/xt_hashlimit.h
include/uapi/linux/netfilter/xt_hashlimit.h
I recommend to add _UAPI prefix to headers
under include/uapi/
to avoid include guard conflict.
The _UAPI prefix is ripped off by
scripts/headers_install.sh
when exported to user-space.
--
Best Regards
Masahiro Yamada
Powered by blists - more mailing lists