rocr: Add hsa_amd_portable_export_dmabuf_v2

The original version of hsa_amd_portable_export_dmabuf() did not
consider the conditions under which a dmabuf could be shared.
In the new version (hsa_amd_portable_export_dmabuf_v2()), the caller
can specify the flag HSA_AMD_DMABUF_MAPPING_TYPE_PCIE, which means they
want to share the dmabuf over PCIe. In that case, the new code will check
that if it is a PCIe GPU and it is not in a XGMI Hive then if
large-BAR is not supported, we will return an error.
Dieser Commit ist enthalten in:
Chris Freehill
2025-06-05 16:38:38 -05:00
committet von Freehill, Chris
Ursprung 3a9d14bb66
Commit a34604bddb
2 geänderte Dateien mit 3 neuen und 3 gelöschten Zeilen
+1 -1
Datei anzeigen
@@ -234,7 +234,6 @@ global:
hsa_amd_spm_release;
hsa_amd_spm_set_dest_buffer;
hsa_amd_portable_export_dmabuf;
hsa_amd_portable_export_dmabuf_v2;
hsa_amd_portable_close_dmabuf;
hsa_amd_vmem_address_reserve;
hsa_amd_vmem_address_reserve_align;
@@ -260,6 +259,7 @@ global:
hsa_amd_queue_get_info;
hsa_amd_enable_logging;
hsa_amd_signal_wait_all;
hsa_amd_portable_export_dmabuf_v2;
local:
*;
};
+2 -2
Datei anzeigen
@@ -3155,9 +3155,9 @@ hsa_status_t hsa_amd_spm_set_dest_buffer(hsa_agent_t preferred_agent, size_t siz
*/
/**
* @brief Older version of hsa_amd_portable_export_dmabuf_v2
* @brief Older version of export dmabuf
*
* This is the same as calling hsa_amd_portable_export_dmabuf_v2() with the
* This is the same as calling the v2 version of export dmabuf with the
* flags argument set to HSA_AMD_DMABUF_MAPPING_TYPE_NONE.
*
* @param[in] ptr Pointer to the allocation being exported.