---
name: "rpma_conn_get_qp_num"
section: "3"
platform: "linux"
package: "librpma-dev"
version: "1.3.0-2+b3"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/rpma_conn_get_qp_num"
---

# rpma\_conn\_get\_qp\_num(3)

get the connection's qp\_num

## NAME

**rpma\_conn\_get\_qp\_num** - get the connection's qp\_num

## SYNOPSIS

```
      #include <librpma.h>
      struct rpma_conn;
      int rpma_conn_get_qp_num(const struct rpma_conn *conn, uint32_t *qp_num);
```

## DESCRIPTION

**rpma\_conn\_get\_qp\_num**() obtains the unique identifier of the connection.

## RETURN VALUE

The **rpma\_conn\_get\_qp\_num**() function returns 0 on success or a negative error code on failure. **rpma\_conn\_get\_qp\_num**() does not set \*qp\_num value on failure.

## ERRORS

**rpma\_conn\_get\_qp\_num**() can fail with the following error:

- •

  RPMA\_E\_INVAL - conn or qp\_num is NULL

## SEE ALSO

[**rpma\_conn\_req\_new**(3)](/rpma_conn_req_new/3.md), [**rpma\_ep\_next\_conn\_req**(3)](/rpma_ep_next_conn_req/3.md), [**rpma\_conn\_req\_connect**(3)](/rpma_conn_req_connect/3.md), [**librpma**(7)](/librpma/7.md) and https://pmem.io/rpma/
