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 <zajec5@xxxxxxxxx> --- include/net/ip_vs.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/net/ip_vs.h b/include/net/ip_vs.h index 615b20b..cd3942f 100644 --- a/include/net/ip_vs.h +++ b/include/net/ip_vs.h @@ -32,7 +32,10 @@ /* Generic access of ipvs struct */ static inline struct netns_ipvs *net_ipvs(struct net* net) { +#if IS_ENABLED(CONFIG_IP_VS) return net->ipvs; +#endif + return NULL; } /* Get net ptr from skb in traffic cases -- 1.8.4.5 -- To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html