]> git.karo-electronics.de Git - mv-sheeva.git/blobdiff - include/linux/netlink.h
headers_check fix: linux/blktrace_api.h
[mv-sheeva.git] / include / linux / netlink.h
index cbba7760545b8b48ce45430973ca983f47d0c838..51b09a1f46c3bde1da65df6d096cbaa4b409c541 100644 (file)
@@ -220,7 +220,7 @@ struct netlink_callback
        int             (*dump)(struct sk_buff * skb, struct netlink_callback *cb);
        int             (*done)(struct netlink_callback *cb);
        int             family;
-       long            args[7];
+       long            args[6];
 };
 
 struct netlink_notify
@@ -242,7 +242,8 @@ __nlmsg_put(struct sk_buff *skb, u32 pid, u32 seq, int type, int len, int flags)
        nlh->nlmsg_flags = flags;
        nlh->nlmsg_pid = pid;
        nlh->nlmsg_seq = seq;
-       memset(NLMSG_DATA(nlh) + len, 0, NLMSG_ALIGN(size) - size);
+       if (!__builtin_constant_p(size) || NLMSG_ALIGN(size) - size != 0)
+               memset(NLMSG_DATA(nlh) + len, 0, NLMSG_ALIGN(size) - size);
        return nlh;
 }