diff --git a/sys/dev/mlx4/mlx4_en/mlx4_en_tx.c b/sys/dev/mlx4/mlx4_en/mlx4_en_tx.c index 9a73c7571fd7..d45ccacd7499 100644 --- a/sys/dev/mlx4/mlx4_en/mlx4_en_tx.c +++ b/sys/dev/mlx4/mlx4_en/mlx4_en_tx.c @@ -688,7 +688,7 @@ int mlx4_en_xmit(struct mlx4_en_priv *priv, int tx_ind, struct mbuf **mbp) dseg = &tx_desc->data; /* send a copy of the frame to the BPF listener, if any */ - if (ifp != NULL && if_getbpf(ifp) != NULL) + if (ifp != NULL) ETHER_BPF_MTAP(ifp, mb); /* get default flags */ diff --git a/sys/dev/mlx5/mlx5_en/mlx5_en_tx.c b/sys/dev/mlx5/mlx5_en/mlx5_en_tx.c index 1f2820abc30e..3f70e8a818ea 100644 --- a/sys/dev/mlx5/mlx5_en/mlx5_en_tx.c +++ b/sys/dev/mlx5/mlx5_en/mlx5_en_tx.c @@ -745,7 +745,7 @@ mlx5e_sq_xmit(struct mlx5e_sq *sq, struct mbuf **mbp) mb = *mbp; /* Send a copy of the frame to the BPF listener, if any */ - if (ifp != NULL && if_getbpf(ifp) != NULL) + if (ifp != NULL) ETHER_BPF_MTAP(ifp, mb); if (mb->m_pkthdr.csum_flags & (CSUM_IP | CSUM_TSO)) {