From: zyjzyj2000@gmail.com
To: netdev@vger.kernel.org, pabeni@redhat.com, daniel@iogearbox.net,
pshelar@nicira.com, aduyck@mirantis.com,
hannes@stressinduktion.org, jbenc@redhat.com,
davem@davemloft.net, zyjzyj2000@gmail.com
Subject: [PATCH 1/1] vxlan: make the struct nlattr variable const
Date: Sat, 3 Sep 2016 22:07:10 +0800 [thread overview]
Message-ID: <1472911630-22285-1-git-send-email-zyjzyj2000@gmail.com> (raw)
From: Zhu Yanjun <zyjzyj2000@gmail.com>
The struct nlattr variable should not be changed.
Signed-off-by: Zhu Yanjun <zyjzyj2000@gmail.com>
---
drivers/net/vxlan.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/vxlan.c b/drivers/net/vxlan.c
index f605a36..ce65897 100644
--- a/drivers/net/vxlan.c
+++ b/drivers/net/vxlan.c
@@ -115,7 +115,7 @@ static inline bool vxlan_addr_multicast(const union vxlan_addr *ipa)
return IN_MULTICAST(ntohl(ipa->sin.sin_addr.s_addr));
}
-static int vxlan_nla_get_addr(union vxlan_addr *ip, struct nlattr *nla)
+static int vxlan_nla_get_addr(union vxlan_addr *ip, const struct nlattr *nla)
{
if (nla_len(nla) >= sizeof(struct in6_addr)) {
ip->sin6.sin6_addr = nla_get_in6_addr(nla);
@@ -157,7 +157,7 @@ static inline bool vxlan_addr_multicast(const union vxlan_addr *ipa)
return IN_MULTICAST(ntohl(ipa->sin.sin_addr.s_addr));
}
-static int vxlan_nla_get_addr(union vxlan_addr *ip, struct nlattr *nla)
+static int vxlan_nla_get_addr(union vxlan_addr *ip, const struct nlattr *nla)
{
if (nla_len(nla) >= sizeof(struct in6_addr)) {
return -EAFNOSUPPORT;
--
2.7.4
next reply other threads:[~2016-09-03 14:18 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-03 14:07 zyjzyj2000 [this message]
2016-09-04 12:27 ` [PATCH 1/1] vxlan: make the struct nlattr variable const Jiri Benc
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=1472911630-22285-1-git-send-email-zyjzyj2000@gmail.com \
--to=zyjzyj2000@gmail.com \
--cc=aduyck@mirantis.com \
--cc=daniel@iogearbox.net \
--cc=davem@davemloft.net \
--cc=hannes@stressinduktion.org \
--cc=jbenc@redhat.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=pshelar@nicira.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).