Skip to content

Commit

Permalink
include/rdma: add FI_PEER as a capability
Browse files Browse the repository at this point in the history
The FI_PEER bit is already defined as a flag for the calls to import
shared resources into peers. Extend this flag to be defined as a
primary capability which indicates that the provider supports being
used as a peer through the peer API flow. The subset of the peer API
defined for the FI_PEER capability is the minimum needed for peer support:
CQ, counter, and shared receive queues

Signed-off-by: Alexia Ingerson <[email protected]>
  • Loading branch information
aingerson committed Aug 27, 2024
1 parent 88f4fcc commit d731157
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 2 deletions.
2 changes: 1 addition & 1 deletion include/ofi.h
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ ofi_poll_del(struct fid_poll *pollset, struct fid *event_fid, uint64_t flags)
(FI_MULTI_RECV | FI_TRIGGER | FI_RMA_PMEM | FI_SOURCE | \
FI_RMA_EVENT | FI_SOURCE_ERR)

#define OFI_DOMAIN_PRIMARY_CAPS FI_AV_USER_ID
#define OFI_DOMAIN_PRIMARY_CAPS (FI_AV_USER_ID | FI_PEER)
#define OFI_DOMAIN_SECONDARY_CAPS \
(FI_SHARED_AV | FI_REMOTE_COMM | FI_LOCAL_COMM)

Expand Down
5 changes: 5 additions & 0 deletions man/fi_domain.3.md
Original file line number Diff line number Diff line change
Expand Up @@ -719,6 +719,11 @@ The following are support primary capabilities:
FI_AV_USER_ID can still be supported through the AV insert calls without
this domain capability set. See [`fi_av`(3)](fi_av.3.html).

*FI_PEER*
: Specifies that the domain must support importing resources to be used in the
the peer API flow. The domain must support importing owner_ops when opening
a CQ, counter, and shared receive queue.

The following are supported secondary capabilities:

*FI_LOCAL_COMM*
Expand Down
8 changes: 7 additions & 1 deletion man/fi_getinfo.3.md
Original file line number Diff line number Diff line change
Expand Up @@ -338,6 +338,11 @@ additional optimizations.
allow an initiator to target (or name) a specific receive context as
part of a data transfer operation.

*FI_PEER*
: Specifies that the provider must support being used as a peer provider in
the peer API flow. The provider must support importing owner_ops when opening
a CQ, counter, and shared receive queue.

*FI_READ*
: Indicates that the user requires an endpoint capable of initiating
reads against remote memory regions. This flag requires that FI_RMA
Expand Down Expand Up @@ -457,7 +462,8 @@ may optionally report non-selected secondary capabilities if doing so
would not compromise performance or security.

Primary capabilities: FI_MSG, FI_RMA, FI_TAGGED, FI_ATOMIC, FI_MULTICAST,
FI_NAMED_RX_CTX, FI_DIRECTED_RECV, FI_HMEM, FI_COLLECTIVE, FI_XPU, FI_AV_USER_ID
FI_NAMED_RX_CTX, FI_DIRECTED_RECV, FI_HMEM, FI_COLLECTIVE, FI_XPU,
FI_AV_USER_ID, FI_PEER

Primary modifiers: FI_READ, FI_WRITE, FI_RECV, FI_SEND,
FI_REMOTE_READ, FI_REMOTE_WRITE
Expand Down
1 change: 1 addition & 0 deletions src/fi_tostr.c
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,7 @@ static void ofi_tostr_caps(char *buf, size_t len, uint64_t caps)
IFFLAGSTRN(caps, FI_NAMED_RX_CTX, len);
IFFLAGSTRN(caps, FI_DIRECTED_RECV, len);
IFFLAGSTRN(caps, FI_AV_USER_ID, len);
IFFLAGSTRN(caps, FI_PEER, len);
IFFLAGSTRN(caps, FI_HMEM, len);

ofi_remove_comma(buf);
Expand Down

0 comments on commit d731157

Please sign in to comment.