.\" Extracted by src2man from /build/rpma-11eW7Q/rpma-1.3.0/src/include/librpma.h .\" Text automatically generated by txt2man .TH rpma_peer_new 3 "29 May 2023" "RPMA" "RPMA Programmer's Manual" .SH NAME \fBrpma_peer_new \fP- create a peer object .SH SYNOPSIS .nf .fam C #include struct ibv_context; struct rpma_peer; int \fBrpma_peer_new\fP(struct ibv_context *ibv_ctx, struct rpma_peer **peer_ptr); .fam T .fi .fam T .fi .SH DESCRIPTION \fBrpma_peer_new\fP() creates a new peer object. .SH RETURN VALUE The \fBrpma_peer_new\fP() function returns 0 on success or a negative error code on failure. \fBrpma_peer_new\fP() does not set *peer_ptr value on failure. .SH ERRORS \fBrpma_peer_new\fP() can fail with the following errors: .IP \(bu 3 RPMA_E_INVAL - ibv_ctx or peer_ptr is NULL .IP \(bu 3 RPMA_E_NOMEM - creating a verbs protection domain failed with ENOMEM. .IP \(bu 3 RPMA_E_PROVIDER - creating a verbs protection domain failed with error other than ENOMEM. .IP \(bu 3 RPMA_E_UNKNOWN - creating a verbs protection domain failed without error value. .IP \(bu 3 RPMA_E_NOMEM - out of memory .SH SEE ALSO \fBrpma_conn_req_new\fP(3), \fBrpma_ep_listen\fP(3), \fBrpma_mr_reg\fP(3), \fBrpma_peer_delete\fP(3), \fBrpma_utils_get_ibv_context\fP(3), \fBlibrpma\fP(7) and https://pmem.io/rpma/