From: Joe Damato <joe@dama.to>
To: Leon Romanovsky <leon@kernel.org>
Cc: netdev@vger.kernel.org, michael.chan@broadcom.com,
pavan.chebbi@broadcom.com, linux-kernel@vger.kernel.org,
Marek Szyprowski <m.szyprowski@samsung.com>
Subject: Re: [RFC net-next v2 00/12] Add TSO map-once DMA helpers and bnxt SW USO support
Date: Mon, 16 Mar 2026 14:02:26 -0700 [thread overview]
Message-ID: <abhv4mjRyJooCjun@devvm20253.cco0.facebook.com> (raw)
In-Reply-To: <20260316194419.GH61385@unreal>
On Mon, Mar 16, 2026 at 09:44:19PM +0200, Leon Romanovsky wrote:
> On Thu, Mar 12, 2026 at 03:34:37PM -0700, Joe Damato wrote:
> > Greetings:
> >
> > This series extends net/tso to add a data structure and some helpers allowing
> > drivers to DMA map headers and packet payloads a single time. The helpers can
> > then be used to reference slices of shared mapping for each segment. This
> > helps to avoid the cost of repeated DMA mappings, especially on systems which
> > use an IOMMU.
>
> In modern kernels, it is done by using DMA IOVA API, see NVMe
> driver/block layer for the most comprehensive example.
>
> The pseudo code is:
> if (with_iommu)
> use dma_iova_link/dma_iova_unlink
> else
> use dma_map_phys()
>
> https://lore.kernel.org/all/cover.1746424934.git.leon@kernel.org/
> https://lore.kernel.org/all/20250623141259.76767-1-hch@lst.de/
> https://lwn.net/Articles/997563/
Thanks for the pointer.
I agree it's the right approach. Batching the IOVA allocation and IOTLB sync
across all regions is a clear win over the per-region
dma_map_single/skb_frag_dma_map calls I had in v2.
I'll submit a v3 with the tso_dma_map internals updated to use
dma_iova_try_alloc + dma_iova_link + dma_iova_sync, with a
dma_map_phys fallback.
prev parent reply other threads:[~2026-03-16 21:02 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-12 22:34 [RFC net-next v2 00/12] Add TSO map-once DMA helpers and bnxt SW USO support Joe Damato
2026-03-12 22:34 ` [RFC net-next v2 01/12] net: tso: Introduce tso_dma_map Joe Damato
2026-03-12 22:34 ` [RFC net-next v2 02/12] net: tso: Add tso_dma_map helpers Joe Damato
2026-03-12 22:34 ` [RFC net-next v2 03/12] net: bnxt: Export bnxt_xmit_get_cfa_action Joe Damato
2026-03-12 22:34 ` [RFC net-next v2 04/12] net: bnxt: Add a helper for tx_bd_ext Joe Damato
2026-03-12 22:34 ` [RFC net-next v2 05/12] net: bnxt: Use dma_unmap_len for TX completion unmapping Joe Damato
2026-03-12 22:34 ` [RFC net-next v2 06/12] net: bnxt: Add TX inline buffer infrastructure Joe Damato
2026-03-12 22:34 ` [RFC net-next v2 07/12] net: bnxt: Add boilerplate GSO code Joe Damato
2026-03-12 22:34 ` [RFC net-next v2 08/12] net: bnxt: Implement software USO Joe Damato
2026-03-12 22:34 ` [RFC net-next v2 09/12] net: bnxt: Add SW GSO completion and teardown support Joe Damato
2026-03-12 22:34 ` [RFC net-next v2 10/12] net: bnxt: Dispatch to SW USO Joe Damato
2026-03-12 22:34 ` [RFC net-next v2 11/12] net: netdevsim: Add support for " Joe Damato
2026-03-12 22:34 ` [RFC net-next v2 12/12] selftests: drv-net: Add USO test Joe Damato
2026-03-16 19:44 ` [RFC net-next v2 00/12] Add TSO map-once DMA helpers and bnxt SW USO support Leon Romanovsky
2026-03-16 21:02 ` Joe Damato [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=abhv4mjRyJooCjun@devvm20253.cco0.facebook.com \
--to=joe@dama.to \
--cc=leon@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=m.szyprowski@samsung.com \
--cc=michael.chan@broadcom.com \
--cc=netdev@vger.kernel.org \
--cc=pavan.chebbi@broadcom.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox