aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/netlink.h
diff options
context:
space:
mode:
authorNicolas Dichtel <nicolas.dichtel@6wind.com>2016-04-22 17:31:17 +0200
committerDavid S. Miller <davem@davemloft.net>2016-04-23 20:13:24 -0400
commite7479122befd7026cf0fb3b3740f17ebd9c64d35 (patch)
tree45d13afd805cfa9b745330a86218d91fd12b8104 /include/net/netlink.h
parent11a99573079e15f11499ae8d21b07e3e3257fff1 (diff)
downloadlinux-e7479122befd7026cf0fb3b3740f17ebd9c64d35.tar.gz
libnl: nla_put_le64(): align on a 64-bit area
nla_data() is now aligned on a 64-bit area. Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/netlink.h')
-rw-r--r--include/net/netlink.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/include/net/netlink.h b/include/net/netlink.h
index 6f51a8a06498c..7f6b99483ab73 100644
--- a/include/net/netlink.h
+++ b/include/net/netlink.h
@@ -878,14 +878,16 @@ static inline int nla_put_net64(struct sk_buff *skb, int attrtype, __be64 value)
}
/**
- * nla_put_le64 - Add a __le64 netlink attribute to a socket buffer
+ * nla_put_le64 - Add a __le64 netlink attribute to a socket buffer and align it
* @skb: socket buffer to add attribute to
* @attrtype: attribute type
* @value: numeric value
+ * @padattr: attribute type for the padding
*/
-static inline int nla_put_le64(struct sk_buff *skb, int attrtype, __le64 value)
+static inline int nla_put_le64(struct sk_buff *skb, int attrtype, __le64 value,
+ int padattr)
{
- return nla_put(skb, attrtype, sizeof(__le64), &value);
+ return nla_put_64bit(skb, attrtype, sizeof(__le64), &value, padattr);
}
/**