Skip to content

ionic: Add direct verbs for provider detection, UDMA, express doorbell, GDA, and extended CQ - #1771

Open
abhijitG-xlnx wants to merge 14 commits into
linux-rdma:masterfrom
abhijitG-xlnx:dv_apis
Open

ionic: Add direct verbs for provider detection, UDMA, express doorbell, GDA, and extended CQ#1771
abhijitG-xlnx wants to merge 14 commits into
linux-rdma:masterfrom
abhijitG-xlnx:dv_apis

Conversation

@abhijitG-xlnx

Copy link
Copy Markdown
Contributor

Add 14 new ionic direct verb APIs with man pages, symbol exports under IONIC_1.1, and debian packaging updates.

ionic_dv_is_ionic_ctx;
ionic_dv_is_ionic_pd;
ionic_dv_is_ionic_cq;
ionic_dv_is_ionic_qp;
ionic_dv_cq_get_udma_mask;
ionic_dv_qp_get_udma_idx;
ionic_dv_pd_set_expdb_mask;
ionic_dv_qp_set_gda;
ionic_dv_qp_get_send_dbell_data;
ionic_dv_qp_get_recv_dbell_data;
ionic_dv_get_ctx;
ionic_dv_get_cq;
ionic_dv_get_qp;
ionic_dv_create_cq_ex

@abhijitG-xlnx
abhijitG-xlnx force-pushed the dv_apis branch 3 times, most recently from 1e57167 to d931bc8 Compare July 16, 2026 06:48
Add ionic_dv_is_ionic_ctx() to test whether a device context belongs
to the ionic provider. This allows multi-provider applications to
safely guard ionic-specific direct verb calls.

Signed-off-by: Abhijit Gangurde <abhijit.gangurde@amd.com>
Add ionic_dv_is_ionic_pd() to test whether a protection domain
belongs to the ionic provider.

Signed-off-by: Abhijit Gangurde <abhijit.gangurde@amd.com>
Add ionic_dv_is_ionic_cq() to test whether a completion queue
belongs to the ionic provider.

Signed-off-by: Abhijit Gangurde <abhijit.gangurde@amd.com>
Add ionic_dv_is_ionic_qp() to test whether a queue pair belongs
to the ionic provider.

Signed-off-by: Abhijit Gangurde <abhijit.gangurde@amd.com>
Add ionic_dv_cq_get_udma_mask() to query the UDMA pipeline bitmask
assigned to a completion queue. This complements the existing UDMA
pipeline query APIs for contexts and protection domains.

Signed-off-by: Abhijit Gangurde <abhijit.gangurde@amd.com>
Add ionic_dv_qp_get_udma_idx() to query the UDMA pipeline index
assigned to a queue pair. This complements ionic_dv_cq_get_udma_mask()
and the existing UDMA query APIs.

Signed-off-by: Abhijit Gangurde <abhijit.gangurde@amd.com>
Add ionic_dv_pd_set_expdb_mask() to configure express doorbell WQE
size preferences on a protection domain. This allows applications to
enable express doorbell for WQE sizes beyond the default 64-byte.

Add expdb_mask field to ionic_pd and update
ionic_expdb_wqe_size_supported to intersect the PD mask with the
device capability mask.

Signed-off-by: Abhijit Gangurde <abhijit.gangurde@amd.com>
Add ionic_dv_qp_set_gda() to enable GPU-Direct Async on a queue pair,
allowing GPU-initiated RDMA operations. The function validates that the
QP has not been used and that GDA is supported by the device context.

Add bool gda field to struct ionic_rq and struct ionic_sq for tracking
GPU-Direct Async enablement per queue. Skip doorbell ringing on send
and receive paths when GDA is enabled, as the GPU is responsible for
ringing the doorbell via ionic_dv_qp_get_send/recv_dbell_data.

Signed-off-by: Abhijit Gangurde <abhijit.gangurde@amd.com>
Add ionic_dv_qp_get_send_dbell_data() to retrieve the send queue
doorbell data value for GPU-Direct Async mode. The GPU writes this
value to the doorbell register to trigger data transfers.

Signed-off-by: Abhijit Gangurde <abhijit.gangurde@amd.com>
Add ionic_dv_qp_get_recv_dbell_data() to retrieve the receive queue
doorbell data value for GPU-Direct Async mode. The GPU writes this
value to the doorbell register to make receive buffers available.

Signed-off-by: Abhijit Gangurde <abhijit.gangurde@amd.com>
Add ionic_dv_get_ctx() to extract device context information for
GPU-initiated RDMA, including doorbell page pointers and queue type
identifiers. Introduce struct ionic_dv_ctx and struct ionic_dv_queue
as part of the GDA data access interface.

Export ionic_fw_types.h as a public header so that GDA applications
can interpret WQE and CQE structures in hardware format when accessing
queue memory directly.

Signed-off-by: Abhijit Gangurde <abhijit.gangurde@amd.com>
Add ionic_dv_get_cq() to extract completion queue descriptor information
for a specific UDMA pipeline, enabling GPU-initiated CQ access. Introduce
struct ionic_dv_cq and the internal ionic_dv_get_queue helper.

Signed-off-by: Abhijit Gangurde <abhijit.gangurde@amd.com>
Add ionic_dv_get_qp() to extract send and receive queue descriptor
information for GPU-initiated RDMA. Introduce struct ionic_dv_qp to
hold both queue descriptors. This completes the GDA data access
interface together with ionic_dv_get_ctx() and ionic_dv_get_cq().

Signed-off-by: Abhijit Gangurde <abhijit.gangurde@amd.com>
Add ionic_dv_create_cq_ex() to create completion queues with
vendor-specific attributes such as compact CQE (CCQE) mode.

Refactor the internal ionic_create_cq_ex() into
ionic_create_cq_ex_common() which accepts an optional
ionic_cq_init_attr_ex parameter. The original verb function
becomes a thin wrapper passing NULL.

Introduce enum ionic_cq_init_attr_mask, enum ionic_cq_init_attr_flags,
and struct ionic_cq_init_attr_ex in the public header. Add IONIC_1.1
version to the symbol map.

Signed-off-by: Abhijit Gangurde <abhijit.gangurde@amd.com>
@abhijitG-xlnx

Copy link
Copy Markdown
Contributor Author

^ rebased

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant