Equal stride super-buffer Rx datapath does not support tunnels, code to
parse tunnel packet types and inner checksum offload is not required and
it is important to be able to compile it out on build time to avoid
extra CPU load.
Cutting of tunnels support relies on compiler optimizaitons to
be able to drop extra checks and branches if tun_ptype is always 0.
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Ivan Malov <ivan.malov@oktetlabs.ru>
#include "sfc_dp_rx.h"
#include "sfc_kvargs.h"
#include "sfc_ef10.h"
+
+#define SFC_EF10_RX_EV_ENCAP_SUPPORT 1
#include "sfc_ef10_rx_ev.h"
#define sfc_ef10_rx_err(dpq, ...) \
if (unlikely(EFX_TEST_QWORD_BIT(rx_ev, ESF_DZ_RX_PARSE_INCOMPLETE_LBN)))
goto done;
+#if SFC_EF10_RX_EV_ENCAP_SUPPORT
switch (EFX_QWORD_FIELD(rx_ev, ESF_EZ_RX_ENCAP_HDR)) {
default:
/* Unexpected encapsulation tag class */
tun_ptype = RTE_PTYPE_TUNNEL_NVGRE;
break;
}
+#endif
if (tun_ptype == 0) {
ip_csum_err_bit = ESF_DZ_RX_IPCKSUM_ERR_LBN;