diff --git a/drivers/intel/iavf/iavf-4.9.5-zc/src/iavf_txrx.c b/drivers/intel/iavf/iavf-4.9.5-zc/src/iavf_txrx.c index 694a940ba..fdd92a537 100644 --- a/drivers/intel/iavf/iavf-4.9.5-zc/src/iavf_txrx.c +++ b/drivers/intel/iavf/iavf-4.9.5-zc/src/iavf_txrx.c @@ -2286,7 +2286,11 @@ static int iavf_clean_rx_irq(struct iavf_ring *rx_ring, int budget) } if (xdp_xmit & IAVF_XDP_REDIR) - xdp_do_flush(); //xdp_do_flush_map(); +#ifdef HAVE_XDP_DO_FLUSH_MAP + xdp_do_flush_map(); +#else + xdp_do_flush(); +#endif if (xdp_xmit & IAVF_XDP_TX) { struct iavf_ring *xdp_ring = diff --git a/drivers/intel/iavf/iavf-4.9.5-zc/src/kcompat-generator.sh b/drivers/intel/iavf/iavf-4.9.5-zc/src/kcompat-generator.sh index c182cdd32..84dee96eb 100644 --- a/drivers/intel/iavf/iavf-4.9.5-zc/src/kcompat-generator.sh +++ b/drivers/intel/iavf/iavf-4.9.5-zc/src/kcompat-generator.sh @@ -132,6 +132,7 @@ function gen-ethtool() { function gen-filter() { fh='include/linux/filter.h' gen NEED_NO_NETDEV_PROG_XDP_WARN_ACTION if fun bpf_warn_invalid_xdp_action lacks 'struct net_device \\*' in "$fh" + gen HAVE_XDP_DO_FLUSH_MAP if fun xdp_do_flush_map in "$fh" gen NEED_XDP_DO_FLUSH if fun xdp_do_flush absent in "$fh" }