|
| 1 | +/** |
| 2 | + * Copyright (c) NVIDIA CORPORATION & AFFILIATES, 2025. ALL RIGHTS RESERVED. |
| 3 | + * See file LICENSE for terms. |
| 4 | + */ |
| 5 | + |
| 6 | +#ifndef UCT_GDAKI_CUH_H |
| 7 | +#define UCT_GDAKI_CUH_H |
| 8 | + |
| 9 | +/* |
| 10 | + * Stub implementation for GDAKI (GPU Direct Async Kernel Interface). |
| 11 | + * This file provides stub functions when DOCA GPUNetIO package is not available. |
| 12 | + * If DOCA GPUNetIO is installed, the real implementation from that package |
| 13 | + * will be used instead (via higher priority include path). |
| 14 | + */ |
| 15 | + |
| 16 | +#include "gdaki_dev.h" |
| 17 | +#include <ucs/sys/device_code.h> |
| 18 | +#include <ucs/type/status.h> |
| 19 | + |
| 20 | +/** |
| 21 | + * Stub implementation: put_single operation |
| 22 | + * Returns UCS_ERR_UNSUPPORTED as GDAKI is not available |
| 23 | + */ |
| 24 | +template<ucs_device_level_t level> |
| 25 | +UCS_F_DEVICE ucs_status_t uct_rc_mlx5_gda_ep_put_single( |
| 26 | + uct_device_ep_h tl_ep, const uct_device_mem_element_t *tl_mem_elem, |
| 27 | + const void *address, uint64_t remote_address, size_t length, |
| 28 | + uint64_t flags, uct_device_completion_t *comp) |
| 29 | +{ |
| 30 | + return UCS_ERR_UNSUPPORTED; |
| 31 | +} |
| 32 | + |
| 33 | +/** |
| 34 | + * Stub implementation: atomic_add operation |
| 35 | + * Returns UCS_ERR_UNSUPPORTED as GDAKI is not available |
| 36 | + */ |
| 37 | +template<ucs_device_level_t level> |
| 38 | +UCS_F_DEVICE ucs_status_t uct_rc_mlx5_gda_ep_atomic_add( |
| 39 | + uct_device_ep_h tl_ep, const uct_device_mem_element_t *tl_mem_elem, |
| 40 | + uint64_t value, uint64_t remote_address, uint64_t flags, |
| 41 | + uct_device_completion_t *comp) |
| 42 | +{ |
| 43 | + return UCS_ERR_UNSUPPORTED; |
| 44 | +} |
| 45 | + |
| 46 | +/** |
| 47 | + * Stub implementation: put_multi operation |
| 48 | + * Returns UCS_ERR_UNSUPPORTED as GDAKI is not available |
| 49 | + */ |
| 50 | +template<ucs_device_level_t level> |
| 51 | +UCS_F_DEVICE ucs_status_t uct_rc_mlx5_gda_ep_put_multi( |
| 52 | + uct_device_ep_h tl_ep, const uct_device_mem_element_t *tl_mem_list, |
| 53 | + unsigned mem_list_count, void *const *addresses, |
| 54 | + const uint64_t *remote_addresses, const size_t *lengths, |
| 55 | + uint64_t counter_inc_value, uint64_t counter_remote_address, |
| 56 | + uint64_t flags, uct_device_completion_t *tl_comp) |
| 57 | +{ |
| 58 | + return UCS_ERR_UNSUPPORTED; |
| 59 | +} |
| 60 | + |
| 61 | +/** |
| 62 | + * Stub implementation: put_multi_partial operation |
| 63 | + * Returns UCS_ERR_UNSUPPORTED as GDAKI is not available |
| 64 | + */ |
| 65 | +template<ucs_device_level_t level> |
| 66 | +UCS_F_DEVICE ucs_status_t uct_rc_mlx5_gda_ep_put_multi_partial( |
| 67 | + uct_device_ep_h tl_ep, const uct_device_mem_element_t *tl_mem_list, |
| 68 | + const unsigned *mem_list_indices, unsigned mem_list_count, |
| 69 | + void *const *addresses, const uint64_t *remote_addresses, |
| 70 | + const size_t *local_offsets, const size_t *remote_offsets, |
| 71 | + const size_t *lengths, unsigned counter_index, |
| 72 | + uint64_t counter_inc_value, uint64_t counter_remote_address, |
| 73 | + uint64_t flags, uct_device_completion_t *tl_comp) |
| 74 | +{ |
| 75 | + return UCS_ERR_UNSUPPORTED; |
| 76 | +} |
| 77 | + |
| 78 | +/** |
| 79 | + * Stub implementation: endpoint progress |
| 80 | + * No-op as GDAKI is not available |
| 81 | + */ |
| 82 | +template<ucs_device_level_t level> |
| 83 | +UCS_F_DEVICE void uct_rc_mlx5_gda_ep_progress(uct_device_ep_h tl_ep) |
| 84 | +{ |
| 85 | + /* No-op stub */ |
| 86 | +} |
| 87 | + |
| 88 | +/** |
| 89 | + * Stub implementation: check completion |
| 90 | + * Returns UCS_ERR_UNSUPPORTED as GDAKI is not available |
| 91 | + */ |
| 92 | +template<ucs_device_level_t level> |
| 93 | +UCS_F_DEVICE ucs_status_t uct_rc_mlx5_gda_ep_check_completion( |
| 94 | + uct_device_ep_h tl_ep, uct_device_completion_t *tl_comp) |
| 95 | +{ |
| 96 | + return UCS_ERR_UNSUPPORTED; |
| 97 | +} |
| 98 | + |
| 99 | +#endif /* UCT_GDAKI_CUH_H */ |
| 100 | + |
0 commit comments