On Wed, 22 Apr 2020 18:08:52 +0200 Jesper Dangaard Brouer wrote: > The netronome nfp driver use PAGE_SIZE when xdp_prog is set, but > xdp.data_hard_start begins at offset NFP_NET_RX_BUF_HEADROOM. > Thus, adjust for this when setting xdp.frame_sz, as it counts > from data_hard_start. > > When doing XDP_TX this driver is smart and instead of a full DMA-map > does a DMA-sync on with packet length. As xdp_adjust_tail can now > grow packet length, add checks to make sure that grow size is within > the DMA-mapped size. > > Cc: Jakub Kicinski <kuba@xxxxxxxxxx> > Signed-off-by: Jesper Dangaard Brouer <brouer@xxxxxxxxxx> Reviewed-by: Jakub Kicinski <kuba@xxxxxxxxxx>