diff options
author | Simon Horman <simon.horman@netronome.com> | 2015-11-26 22:07:23 -0800 |
---|---|---|
committer | Pravin B Shelar <pshelar@ovn.org> | 2016-01-28 19:02:54 -0800 |
commit | 6dbd98e6cad2cc6aced7f8be2cd15b5a5cc3ed47 (patch) | |
tree | b6809598d828afeaa3ecd6e5407a8d04b25a136b /datapath | |
parent | 025f69aa62650a911861c48281490e52ae658b94 (diff) | |
download | openvswitch-6dbd98e6cad2cc6aced7f8be2cd15b5a5cc3ed47.tar.gz |
datapath: test for netlink_set_err returning void
In v2.6.33 netlink_set_err returns void. However, 1a50307ba182 ("netlink:
fix NETLINK_RECV_NO_ENOBUFS in netlink_set_err()") was backported and
included in v2.6.33.2 and in that and subsequent v2.6.33 stable releases
netlink_set_err returns an int.
It seems plausible that there are other backports floating around. So check
for netlink_set_err returning void rather than including compatibility code
based on the version of the kernel.
Signed-off-by: Simon Horman <simon.horman@netronome.com>
Acked-by: Pravin B Shelar <pshelar@ovn.org>
Diffstat (limited to 'datapath')
-rw-r--r-- | datapath/linux/compat/include/net/genetlink.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/datapath/linux/compat/include/net/genetlink.h b/datapath/linux/compat/include/net/genetlink.h index cf89d4c23..2830fa376 100644 --- a/datapath/linux/compat/include/net/genetlink.h +++ b/datapath/linux/compat/include/net/genetlink.h @@ -67,7 +67,7 @@ static inline int rpl_genl_unregister_family(struct genl_family *family) static inline int genl_set_err(struct genl_family *family, struct net *net, u32 portid, u32 group, int code) { -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,33) +#ifdef HAVE_VOID_NETLINK_SET_ERR netlink_set_err(net->genl_sock, portid, group, code); return 0; #else |