---
name: "libnvmf_context_set_io_queues-libnvme3"
section: "2"
platform: "linux"
package: "nvme-cli"
version: "3.2-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/libnvmf_context_set_io_queues-libnvme3"
---

# libnvmf\_context\_set\_io\_queues-libnvme3(2)

Set I/O queue topology for context

## NAME

libnvmf\_context\_set\_io\_queues - Set I/O queue topology for context

## SYNOPSIS

**int libnvmf\_context\_set\_io\_queues** **(struct libnvmf\_context \*fctx** *,* **int nr\_io\_queues** *,* **int nr\_write\_queues** *,* **int nr\_poll\_queues** *,* **int queue\_size** *,* **bool disable\_sqflow** *);*

## ARGUMENTS

- fctx

  Fabrics context

- nr\_io\_queues

  Number of I/O queues

- nr\_write\_queues

  Number of write-only queues

- nr\_poll\_queues

  Number of polling queues

- queue\_size

  Number of entries per I/O queue (SQSIZE in Connect command)

- disable\_sqflow

  Disable SQ flow control negotiation

## DESCRIPTION

Convenience setter for the five parameters that together define the I/O queue structure used when establishing a controller connection. All five feed directly into the Connect command at queue creation time. *nr\_write\_queues* and *nr\_poll\_queues* are additive: total I/O queues is *nr\_io\_queues* + *nr\_write\_queues* + *nr\_poll\_queues*.

Individual **libnvmf\_context\_set\_nr\_io\_queues**, **\_set\_nr\_write\_queues**, **\_set\_nr\_poll\_queues**, **\_set\_queue\_size**, and **\_set\_disable\_sqflow** accessors are also available when only a subset needs to change.

## RETURN

0 on success, negative error code otherwise.
