summaryrefslogtreecommitdiff
path: root/tools/lib/python/kdoc/python_version.py
diff options
context:
space:
mode:
authorErfan Sharafzadeh <erfansh@meta.com>2026-10-13 14:09:54 -0700
committerJakub Kicinski <kuba@kernel.org>2026-10-20 13:22:38 -0700
commit69ab87acc614cbe0bd08a65ece6e1aabee805106 (patch)
treed9d339f762c4915040c7ccc8e35e3ebe90e3791e /tools/lib/python/kdoc/python_version.py
parent42ee6e77ab4592ab43a7724f57f1942a7267b505 (diff)
net: devmem: allow peer-to-peer dma-buf attach for bindings
net_devmem_bind_dmabuf() uses dma_buf_attach(), a static attachment with peer2peer false. Exporters must then keep the buffer reachable without P2P; amdgpu does so by placing it in GTT (system memory), so a device memory binding silently ends up in host memory. Use dma_buf_dynamic_attach() with allow_peer2peer set, so an exporter that can do P2P to the device keeps the buffer in device memory. Dynamic attachments are not pinned on map, and devmem cannot handle the buffer moving, so: - pin it with dma_buf_pin() before mapping, which keeps it in place for the lifetime of the binding, as before; - wait for the exporter's kernel fences after mapping, interruptibly, as the core does for static attachments. This follows the pinned RDMA umem path, including its limits: the binding cannot be revoked by the exporter, and once a P2P binding has pinned a buffer in device memory, a later attachment to the same buffer that cannot do P2P may fail to pin it. Exporters that cannot do P2P to the device place the buffer as before. RX and TX bindings both go through this function. Signed-off-by: Erfan Sharafzadeh <erfansh@meta.com> Acked-by: Stanislav Fomichev <sdf@fomichev.me> Link: https://patch.msgid.link/20261013210954.2170175-1-erfansh@meta.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'tools/lib/python/kdoc/python_version.py')
0 files changed, 0 insertions, 0 deletions