From: Ben Pfaff Date: Tue, 3 Mar 2009 22:03:18 +0000 (-0800) Subject: datapath: Fix build on Linux 2.6.18 through 2.6.28. X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7db28df6b4395e8f33d57d2d427ee9d94eede88f;p=openvswitch datapath: Fix build on Linux 2.6.18 through 2.6.28. --- diff --git a/datapath/brcompat.c b/datapath/brcompat.c index b64a2b8b..02a15b82 100644 --- a/datapath/brcompat.c +++ b/datapath/brcompat.c @@ -3,6 +3,7 @@ #include #include #include +#include #include #include diff --git a/datapath/linux-2.6/compat-2.6/include/linux/rtnetlink.h b/datapath/linux-2.6/compat-2.6/include/linux/rtnetlink.h index 449afde3..8bc51560 100644 --- a/datapath/linux-2.6/compat-2.6/include/linux/rtnetlink.h +++ b/datapath/linux-2.6/compat-2.6/include/linux/rtnetlink.h @@ -19,6 +19,11 @@ static inline void rtnl_set_sk_err(struct net *net, u32 group, int error) { netlink_set_err(rtnl, 0, group, error); } -#endif /* linux kernel < 2.6.19 */ +#elif LINUX_VERSION_CODE < KERNEL_VERSION(2,6,25) +#define rtnl_notify(skb, net, pid, group, nlh, flags) \ + ((void) (net), rtnl_notify(skb, pid, group, nlh, flags)) +#define rtnl_set_sk_err(net, group, error) \ + ((void) (net), rtnl_set_sk_err(group, error)) +#endif /* linux kernel < 2.6.25 */ #endif /* linux/rtnetlink.h wrapper */