linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: ioanaruxandra.stancioi@gmail.com
Cc: david.lebrun@uclouvain.be, kuznet@ms2.inr.ac.ru,
	yoshfuji@linux-ipv6.org, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org, elver@google.com,
	glider@google.com, stancioi@google.com
Subject: Re: [PATCH] uapi, seg6_iptunnel: Add missing include in seg6_iptunnel.h
Date: Wed, 29 Jul 2020 12:50:10 -0700 (PDT)	[thread overview]
Message-ID: <20200729.125010.1457267567599420810.davem@davemloft.net> (raw)
In-Reply-To: <20200729104903.3586064-1-ioanaruxandra.stancioi@gmail.com>

From: Ioana-Ruxandra Stancioi <ioanaruxandra.stancioi@gmail.com>
Date: Wed, 29 Jul 2020 10:49:03 +0000

> From: Ioana-Ruxandra Stăncioi <stancioi@google.com>
> 
> Include <linux/ipv6.h> in uapi/linux/seg6_iptunnel.h to fix the
> following linux/seg6_iptunnel.h compilation error:
> 
>    invalid application of 'sizeof' to incomplete type 'struct ipv6hdr'
>        head = sizeof(struct ipv6hdr);
>                      ^~~~~~
> 
> This is to allow including this header in places where <linux/ipv6.h>
> has not been included but __KERNEL__ is defined. In the kernel the easy
> workaround is including <linux/ipv6.h>, but the header may also be used
> by code analysis tools.
> 
> Signed-off-by: Ioana-Ruxandra Stăncioi <stancioi@google.com>

This doesn't belong in a UAPI header (it's __KERNEL__ protected after
all), and it's only called in one place in the kernel, namely
net/ipv6/net/ipv6/seg6_iptunnel.c)

Just move the helper to that foo.c file, and drop the inline keyword.

Thank you.

      reply	other threads:[~2020-07-29 19:50 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-29 10:49 [PATCH] uapi, seg6_iptunnel: Add missing include in seg6_iptunnel.h Ioana-Ruxandra Stancioi
2020-07-29 19:50 ` David Miller [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=20200729.125010.1457267567599420810.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=david.lebrun@uclouvain.be \
    --cc=elver@google.com \
    --cc=glider@google.com \
    --cc=ioanaruxandra.stancioi@gmail.com \
    --cc=kuznet@ms2.inr.ac.ru \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=stancioi@google.com \
    --cc=yoshfuji@linux-ipv6.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 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).