Linux PCI Non-Transparent Bridge framework and drivers
 help / color / mirror / Atom feed
* [PATCH 0/2] Add 'tx_memcpy_offload' option to ntb_transport
@ 2025-10-23  7:21 Koichiro Den
  2025-10-23  7:21 ` [PATCH 1/2] NTB: ntb_transport: Remove unused 'retries' field from ntb_queue_entry Koichiro Den
  2025-10-23  7:21 ` [PATCH 2/2] NTB: ntb_transport: Add 'tx_memcpy_offload' module option Koichiro Den
  0 siblings, 2 replies; 8+ messages in thread
From: Koichiro Den @ 2025-10-23  7:21 UTC (permalink / raw)
  To: ntb, linux-kernel; +Cc: jdmason, dave.jiang, allenbh

This patch set adds an optional TX CPU memcpy offload path to ntb_transport
and does a small cleanup. The new module parameter:

    tx_memcpy_offload=<bool> (default: N)

When enabled, ntb_transport creates a per-QP kernel thread and schedules TX
memcpy_toio() work onto it.

On some platforms (e.g. Renesas R-Car S4), using a DMA engine in the TX
path does not always improve throughput, and memcpy_toio() becomes the
bottleneck on the CPU. Offloading the memcpy_toio() and the subsequent
descriptor writes to a per-QP kthread can raise the achievable throughput
by keeping the data path hot while letting the worker thread perform the
copy.


Koichiro Den (2):
  NTB: ntb_transport: Remove unused 'retries' field from ntb_queue_entry
  NTB: ntb_transport: Add 'tx_memcpy_offload' module option

 drivers/ntb/ntb_transport.c | 115 ++++++++++++++++++++++++++++++++----
 1 file changed, 102 insertions(+), 13 deletions(-)

-- 
2.48.1


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2025-10-27  3:20 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-23  7:21 [PATCH 0/2] Add 'tx_memcpy_offload' option to ntb_transport Koichiro Den
2025-10-23  7:21 ` [PATCH 1/2] NTB: ntb_transport: Remove unused 'retries' field from ntb_queue_entry Koichiro Den
2025-10-23 14:59   ` Dave Jiang
2025-10-23  7:21 ` [PATCH 2/2] NTB: ntb_transport: Add 'tx_memcpy_offload' module option Koichiro Den
2025-10-23 15:18   ` Dave Jiang
2025-10-24 16:41     ` Koichiro Den
2025-10-24 17:05       ` Dave Jiang
2025-10-27  3:20         ` Koichiro Den

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox