On 4/8/17 1:48 PM, Johannes Berg wrote: > diff --git a/include/uapi/linux/netlink.h b/include/uapi/linux/netlink.h > index f3946a27bd07..d1564557d645 100644 > --- a/include/uapi/linux/netlink.h > +++ b/include/uapi/linux/netlink.h > @@ -101,6 +101,29 @@ struct nlmsghdr { > struct nlmsgerr { > int error; > struct nlmsghdr msg; > + /* > + * followed by the message contents unless NETLINK_CAP_ACK was set, > + * message length is aligned with NLMSG_ALIGN() > + */ > + /* > + * followed by TLVs defined in enum nlmsgerr_attrs > + * if NETLINK_EXT_ACK was set > + */ > +}; > + > +/** > + * enum nlmsgerr_attrs - netlink error message attributes > + * @NLMSGERR_ATTR_UNUSED: unused > + * @NLMSGERR_ATTR_MSG: error message string (string) > + * @NLMSGERR_ATTR_OFFS: error offset in the original message (u32) > + * @NLMSGERR_ATTR_ATTR: top-level attribute that caused the error > + * (or is missing, u16) > + */ > +enum nlmsgerr_attrs { > + NLMSGERR_ATTR_UNUSED, > + NLMSGERR_ATTR_MSG, > + NLMSGERR_ATTR_OFFS, > + NLMSGERR_ATTR_ATTR, can you add __NLMSGERR_ATTR_MAX and #define NLMSGERR_ATTR_MAX (__NLMSGERR_ATTR_MAX - 1)