Hello, On Wed, 25 Mar 2015, Rafał Miłecki wrote: > Including net/ip_vs.h without CONFIG_IP_VS was causing: > include/net/ip_vs.h: In function 'net_ipvs': > include/net/ip_vs.h:35:12: error: 'struct net' has no member named 'ipvs' > > Fixes: 8b4d14d8eb368 ("netns: exclude ipvs from struct net when IPVS disabled") > Signed-off-by: Rafał Miłecki > --- > V2: Disable function totally instead of returning NULL. While this version is better, the commit message looks scary, it should explain that problem happens only for modules out of kernel tree, we do not want other admins to wonder whether they need this commit for their trees. And of course, it is better to implement your own ip_vs_check_diff4 version, it is some inline stuff... > --- > include/net/ip_vs.h | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/include/net/ip_vs.h b/include/net/ip_vs.h > index 615b20b..e6f2f2a 100644 > --- a/include/net/ip_vs.h > +++ b/include/net/ip_vs.h > @@ -29,11 +29,13 @@ > #endif > #include /* Netw namespace */ > > +#if IS_ENABLED(CONFIG_IP_VS) > /* Generic access of ipvs struct */ > static inline struct netns_ipvs *net_ipvs(struct net* net) > { > return net->ipvs; > } > +#endif > > /* Get net ptr from skb in traffic cases > * use skb_sknet when call is from userland (ioctl or netlink) > -- > 1.8.4.5 Regards -- Julian Anastasov