]> git.baikalelectronics.ru Git - kernel.git/commit
netlink: remove type-unsafe validation_data pointer
authorJohannes Berg <johannes.berg@intel.com>
Thu, 30 Apr 2020 20:13:05 +0000 (22:13 +0200)
committerDavid S. Miller <davem@davemloft.net>
Fri, 1 May 2020 00:51:41 +0000 (17:51 -0700)
commit808470d9994d136243018e886ad710f9f90cb39a
tree922bbadbfa571fae66f3c3503d7e2331c403c632
parent753f7dfa462d65e1873f4f3087e915c71a19a7db
netlink: remove type-unsafe validation_data pointer

In the netlink policy, we currently have a void *validation_data
that's pointing to different things:
 * a u32 value for bitfield32,
 * the netlink policy for nested/nested array
 * the string for NLA_REJECT

Remove the pointer and place appropriate type-safe items in the
union instead.

While at it, completely dissolve the pointer for the bitfield32
case and just put the value there directly.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/netlink.h
lib/nlattr.c
net/sched/act_api.c
net/sched/sch_red.c