From: Ioana-Ruxandra Stancioi <ioanaruxandra.stancioi@gmail.com>
To: david.lebrun@uclouvain.be, davem@davemloft.net,
kuznet@ms2.inr.ac.ru, yoshfuji@linux-ipv6.org,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: elver@google.com, glider@google.com,
"Ioana-Ruxandra Stăncioi" <stancioi@google.com>
Subject: [PATCH] uapi, seg6_iptunnel: Add missing include in seg6_iptunnel.h
Date: Wed, 29 Jul 2020 10:49:03 +0000 [thread overview]
Message-ID: <20200729104903.3586064-1-ioanaruxandra.stancioi@gmail.com> (raw)
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>
---
include/uapi/linux/seg6_iptunnel.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/include/uapi/linux/seg6_iptunnel.h b/include/uapi/linux/seg6_iptunnel.h
index 09fb608a35ec..b904228f463c 100644
--- a/include/uapi/linux/seg6_iptunnel.h
+++ b/include/uapi/linux/seg6_iptunnel.h
@@ -38,6 +38,7 @@ enum {
};
#ifdef __KERNEL__
+#include <linux/ipv6.h>
static inline size_t seg6_lwt_headroom(struct seg6_iptunnel_encap *tuninfo)
{
--
2.28.0.rc0.142.g3c755180ce-goog
next reply other threads:[~2020-07-29 10:52 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-29 10:49 Ioana-Ruxandra Stancioi [this message]
2020-07-29 19:50 ` [PATCH] uapi, seg6_iptunnel: Add missing include in seg6_iptunnel.h David Miller
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=20200729104903.3586064-1-ioanaruxandra.stancioi@gmail.com \
--to=ioanaruxandra.stancioi@gmail.com \
--cc=davem@davemloft.net \
--cc=david.lebrun@uclouvain.be \
--cc=elver@google.com \
--cc=glider@google.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).