]> asedeno.scripts.mit.edu Git - linux.git/commit
cxgb4/chcr: update SGL DMA unmap for USO
authorRahul Lakkireddy <rahul.lakkireddy@chelsio.com>
Fri, 22 Nov 2019 01:00:01 +0000 (06:30 +0530)
committerJakub Kicinski <jakub.kicinski@netronome.com>
Sat, 23 Nov 2019 00:44:39 +0000 (16:44 -0800)
commit0ed96b46c0ac26ebcdd2ee95c2479ef8cf94bbd6
tree6293d25b2c0ee2d7f4ede7967f44e61a102ea6af
parenta9f852e92e40992c4ff09ac3940f7725e016317a
cxgb4/chcr: update SGL DMA unmap for USO

The FW_ETH_TX_EO_WR used for sending UDP Segmentation Offload (USO)
requests expects the headers to be part of the descriptor and the
payload to be part of the SGL containing the DMA mapped addresses.
Hence, the DMA address in the first entry of the SGL can start after
the packet headers. Currently, unmap_sgl() tries to unmap from this
wrong offset, instead of the originally mapped DMA address.

So, use existing unmap_skb() instead, which takes originally saved DMA
addresses as input. Update all necessary Tx paths to save the original
DMA addresses, so that unmap_skb() can unmap them properly.

v2:
- No change.

Signed-off-by: Rahul Lakkireddy <rahul.lakkireddy@chelsio.com>
Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
drivers/crypto/chelsio/chcr_ipsec.c
drivers/net/ethernet/chelsio/cxgb4/cxgb4.h
drivers/net/ethernet/chelsio/cxgb4/cxgb4_tc_mqprio.c
drivers/net/ethernet/chelsio/cxgb4/sge.c