Re: [PATCH net v2 3/3] octeontx2-pf: Do xdp_do_flush() after redirects.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2023-09-18 10:58:39 [-0700], Kui-Feng Lee wrote:
> > diff --git a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_txrx.c b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_txrx.c
> > index e77d438489557..53b2a4ef52985 100644
> > --- a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_txrx.c
> > +++ b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_txrx.c
> > @@ -1391,8 +1396,10 @@ static bool otx2_xdp_rcv_pkt_handler(struct otx2_nic *pfvf,
> >   		otx2_dma_unmap_page(pfvf, iova, pfvf->rbsize,
> >   				    DMA_FROM_DEVICE);
> > -		if (!err)
> > +		if (!err) {
> > +			*need_xdp_flush = true;
> 
> Is it possible to call xdp_do_flush() at the first place (here)?

It shouldn't be wrong. All drivers, except for cpsw, invoke
xdp_do_flush() after completing their NAPI loop and then flushing all
possible packets at once.

> >   			return true;
> > +		}
> >   		put_page(page);
> >   		break;
> >   	default:

Sebastian




[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux