Skip to content

Commit

Permalink
prov/cxi: Remove disable_dmabuf_cuda and disable_dmabuf_rocr
Browse files Browse the repository at this point in the history
Remove unneeded disable_dmabuf_cuda and disable_dmabuf_rocr
environment variables.

NETCASSINI-6844

Signed-off-by: Chuck Fossen <[email protected]>
  • Loading branch information
Chuck Fossen authored and iziemba committed Oct 31, 2024
1 parent 97422ba commit 15b4487
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 19 deletions.
13 changes: 0 additions & 13 deletions prov/cxi/src/cxip_info.c
Original file line number Diff line number Diff line change
Expand Up @@ -608,8 +608,6 @@ struct cxip_environment cxip_env = {
.force_odp = false,
.ats = false,
.iotlb = true,
.disable_dmabuf_cuda = false,
.disable_dmabuf_rocr = false,
.ats_mlock_mode = CXIP_ATS_MLOCK_ALL,
.fork_safe_requested = false,
.rx_match_mode = CXIP_PTLTE_DEFAULT_MODE,
Expand Down Expand Up @@ -770,17 +768,6 @@ static void cxip_env_init(void)
"Enables the NIC IOTLB (default %d).", cxip_env.iotlb);
fi_param_get_bool(&cxip_prov, "iotlb", &cxip_env.iotlb);

fi_param_define(&cxip_prov, "disable_dmabuf_cuda", FI_PARAM_BOOL,
"Disables the DMABUF interface for CUDA (default %d).",
cxip_env.disable_dmabuf_cuda);
fi_param_get_bool(&cxip_prov, "disable_dmabuf_cuda",
&cxip_env.disable_dmabuf_cuda);

fi_param_define(&cxip_prov, "disable_dmabuf_rocr", FI_PARAM_BOOL,
"Disables the DMABUF interface for ROCR (default %d).",
cxip_env.disable_dmabuf_rocr);
fi_param_get_bool(&cxip_prov, "disable_dmabuf_rocr",
&cxip_env.disable_dmabuf_rocr);

/* Disable cuda DMABUF by default - honors the env if already set */
ret = setenv("FI_HMEM_CUDA_USE_DMABUF", "0", 0);
Expand Down
6 changes: 0 additions & 6 deletions prov/cxi/src/cxip_iomm.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,6 @@ static int cxip_dmabuf_hints(enum fi_hmem_iface iface, void *iov_base,
return -FI_ENOSYS;
}

if (iface == FI_HMEM_CUDA && cxip_env.disable_dmabuf_cuda)
return FI_SUCCESS;

if (iface == FI_HMEM_ROCR && cxip_env.disable_dmabuf_rocr)
return FI_SUCCESS;

ret = ofi_hmem_get_base_addr(iface, iov_base, len, (void*)&base, &size);
if (ret)
return ret;
Expand Down

0 comments on commit 15b4487

Please sign in to comment.