Date: Sun, 25 Feb 2018 11:29:55 +0000 (UTC) From: Hans Petter Selasky <hselasky@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r329982 - stable/10/sys/netinet Message-ID: <201802251129.w1PBTtuN044079@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: hselasky Date: Sun Feb 25 11:29:55 2018 New Revision: 329982 URL: https://svnweb.freebsd.org/changeset/base/329982 Log: Fix for LINT-{NOINET,NOINET6,NOIP} kernel builds. This is a direct commit. Reported by: rpokala@ Sponsored by: Mellanox Technologies Modified: stable/10/sys/netinet/toecore.c Modified: stable/10/sys/netinet/toecore.c ============================================================================== --- stable/10/sys/netinet/toecore.c Sun Feb 25 10:52:46 2018 (r329981) +++ stable/10/sys/netinet/toecore.c Sun Feb 25 11:29:55 2018 (r329982) @@ -41,6 +41,8 @@ __FBSDID("$FreeBSD$"); #include <sys/sysctl.h> #include <sys/socket.h> +#if defined(KLD_MODULE) || defined(INET) || defined(INET6) + #include <net/ethernet.h> #include <net/if.h> #include <net/if_types.h> @@ -357,12 +359,20 @@ toe_4tuple_check(struct in_conninfo *inc, struct tcphd struct inpcb *inp; if (inc->inc_flags & INC_ISIPV6) { +#if defined(KLD_MODULE) || defined(INET6) inp = in6_pcblookup(&V_tcbinfo, &inc->inc6_faddr, inc->inc_fport, &inc->inc6_laddr, inc->inc_lport, INPLOOKUP_WLOCKPCB, ifp); +#else + inp = NULL; +#endif } else { +#if defined(KLD_MODULE) || defined(INET) inp = in_pcblookup(&V_tcbinfo, inc->inc_faddr, inc->inc_fport, inc->inc_laddr, inc->inc_lport, INPLOOKUP_WLOCKPCB, ifp); +#else + inp = NULL; +#endif } if (inp != NULL) { INP_WLOCK_ASSERT(inp); @@ -641,5 +651,8 @@ static moduledata_t mod_data= { 0 }; -MODULE_VERSION(toecore, 1); DECLARE_MODULE(toecore, mod_data, SI_SUB_EXEC, SI_ORDER_ANY); +#endif /* defined(KLD_MODULE) || defined(INET) || defined(INET6) */ + +MODULE_VERSION(toecore, 1); +
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201802251129.w1PBTtuN044079>