Error Code Reference

QV-REF-ERR Rev 1.0 — January 2026 Reference

Complete reference for all error codes, status codes, and failure responses across every QuantaVirt subsystem — hypervisor core, VM lifecycle, CPU virtualization, memory management, storage, networking, PQC cryptography, QUAC 100 hardware, live migration, REST API, and CLI exit codes. Each entry includes the numeric value, symbolic name, human-readable description, common causes, and recommended recovery actions.

Error Code Overview #

QuantaVirt uses a unified error code system across all subsystems. Error codes are negative 32-bit signed integers organized by subsystem range. A value of 0 always indicates success.

RangeSubsystemPrefixHeader
0Success—quantavirt/error.h
-1 to -99Hypervisor CoreQV_ERR_quantavirt/error.h
-100 to -199PQC SubsystemPQC_ERR_quantavirt/pqc_error.h
-200 to -299QUAC 100 DriverQUAC100_ERR_quantavirt/quac100_error.h
-300 to -399MigrationQV_MIG_ERR_quantavirt/migration_error.h
-400 to -499StorageQV_STR_ERR_quantavirt/storage_error.h
-500 to -599NetworkQV_NET_ERR_quantavirt/network_error.h

Error Code Format #

Error codes appear in logs, CLI output, and API responses in a consistent format:

/* Log format */
[ERROR] quantavirt::vm: VM start failed: QV_ERR_NOVMX (-3): hardware virtualization not enabled in BIOS

/* CLI output */
$ quantavirt vm start my-vm
Error: QV_ERR_NOVMX (-3): Intel VMX / AMD SVM not available — enable in BIOS/UEFI

/* REST API JSON response */
{
  "error": {
    "code": -3,
    "name": "QV_ERR_NOVMX",
    "message": "Intel VMX / AMD SVM not available",
    "detail": "Enable hardware virtualization in BIOS/UEFI settings",
    "subsystem": "hypervisor"
  }
}

/* C API */
int ret = qv_vm_start(vm);
if (ret < 0) {
    fprintf(stderr, "Failed: %s (%d): %s\n",
            qv_strerror_name(ret), ret, qv_strerror(ret));
}

Hypervisor Core (QV_ERR_*) #

General hypervisor errors returned by core subsystem operations.

CodeNameDescriptionCommon CauseRecovery
0QV_SUCCESSOperation completed successfully——
-1QV_ERR_GENERICUnspecified internal errorBug or unexpected stateCheck logs, report issue
-2QV_ERR_NOMEMInsufficient host memoryHost RAM exhausted; hugepage pool depletedFree memory or reduce VM sizes; check hugepage allocation
-3QV_ERR_NOVMXHardware virtualization not availableIntel VMX / AMD SVM disabled in BIOS or not supportedEnable VT-x/AMD-V in BIOS/UEFI; verify CPU model supports virtualization
-4QV_ERR_NOIOMMUIOMMU not availableIntel VT-d / AMD-Vi disabled or not presentEnable IOMMU in BIOS; add intel_iommu=on or amd_iommu=on to kernel cmdline
-5QV_ERR_INVALInvalid parameter or argumentMalformed config, out-of-range value, type mismatchValidate configuration against schema; check parameter constraints
-6QV_ERR_NOENTResource not foundVM name, disk path, network, or key not foundVerify resource name/path exists; check spelling
-7QV_ERR_EXISTResource already existsDuplicate VM name, conflicting network nameUse a unique name or delete the existing resource
-8QV_ERR_BUSYResource is busy or lockedDisk locked by another VM; operation in progressWait for current operation to complete; check for stale locks
-9QV_ERR_PERMPermission deniedInsufficient privileges; file permission issueRun as root or with quantavirt group membership; check file ownership
-10QV_ERR_NODEVDevice not found or not availablePCI device missing; QUAC 100 not detectedCheck lspci; reseat card; verify driver loaded
-11QV_ERR_IOI/O errorDisk read/write failure; device communication timeoutCheck disk health (smartctl); verify device connectivity
-12QV_ERR_TIMEOUTOperation timed outVM failed to respond within deadline; device stallIncrease timeout; check for system load; verify device health
-13QV_ERR_AGAINTry again (transient failure)Temporary resource contentionRetry the operation after a brief delay
-14QV_ERR_NOSPCNo space leftStorage pool full; no available VM slotsFree disk space; remove unused VMs or snapshots
-15QV_ERR_UNSUPPORTEDFeature not supportedRequested capability not available on this hardware/firmwareCheck quantavirt system capabilities; upgrade firmware
-16QV_ERR_STATEInvalid state transitionOperation not allowed in current VM state (e.g. migrate a stopped VM)Check VM state with quantavirt vm show; follow valid state transitions
-17QV_ERR_CONFIGConfiguration errorInvalid JSON, missing required field, schema violationValidate config with quantavirt vm validate --config <file>
-18QV_ERR_LIMITResource limit exceededMax VMs, max vCPUs, max NICs, max disks reachedRemove unused resources or increase limits in system config
-19QV_ERR_AUTHAuthentication failedInvalid API token; expired credentialsRe-authenticate; generate new token with quantavirt system token create
-20QV_ERR_VERSIONVersion incompatibilityConfig schema version mismatch; incompatible firmwareUpdate configuration to current schema version; upgrade firmware

VM Lifecycle Errors #

CodeNameDescriptionRecovery
-21QV_ERR_VM_CREATEVM creation failedCheck config validation; verify resource availability
-22QV_ERR_VM_STARTVM start failedCheck VMCS/VMCB allocation; verify hardware virtualization
-23QV_ERR_VM_STOPVM stop failedForce stop with --force; check for stuck state
-24QV_ERR_VM_DESTROYVM destruction failedStop VM first; check for active migration or snapshot
-25QV_ERR_VM_PAUSEVM pause failedVerify VM is running; check hypervisor state
-26QV_ERR_VM_RESUMEVM resume failedVerify VM is paused; check resource availability
-27QV_ERR_VM_SNAPSHOTSnapshot creation failedCheck disk space; verify qcow2 format (raw disks don't support snapshots)
-28QV_ERR_VM_RESTORESnapshot restore failedStop VM first; verify snapshot exists and isn't corrupted
-29QV_ERR_VM_CLONEVM clone failedCheck disk space; stop source VM if using linked clone
-30QV_ERR_VM_STUCKVM is in unresponsive stateForce destroy: quantavirt vm destroy --force <name>

CPU Virtualization Errors #

CodeNameDescriptionRecovery
-31QV_ERR_VMCS_ALLOCFailed to allocate VMCS (Intel) structureFree memory; reduce running VM count
-32QV_ERR_VMCB_ALLOCFailed to allocate VMCB (AMD) structureFree memory; reduce running VM count
-33QV_ERR_VMLAUNCHVMLAUNCH instruction failedCheck VMCS fields; dmesg for VMX abort; verify nested virtualization
-34QV_ERR_VMRESUMEVMRESUME instruction failedCheck VM-exit reason in logs; verify VMCS consistency
-35QV_ERR_VMEXITUnexpected VM-exitLog exit reason; check guest for triple fault or invalid instructions
-36QV_ERR_EPT_SETUPEPT (Intel) setup failedCheck memory available for page tables; verify EPT support in CPUID
-37QV_ERR_NPT_SETUPNPT (AMD) setup failedCheck memory for page tables; verify NPT support
-38QV_ERR_EPT_VIOLATIONUnhandled EPT violationGuest accessed unmapped memory; check memory config
-39QV_ERR_CPUIDCPUID emulation errorUnsupported leaf; check CPU model configuration
-40QV_ERR_MSRMSR access errorGuest accessed forbidden MSR; check MSR bitmap configuration
-41QV_ERR_PINvCPU pinning failedSpecified pCPU doesn't exist or is offline; verify CPU topology
-42QV_ERR_TOPOLOGYCPU topology validation failedsockets × cores × threads must equal vCPU count
-43QV_ERR_TRIPLE_FAULTGuest triggered triple faultGuest OS crashed; check guest boot config and kernel

Memory Subsystem Errors #

CodeNameDescriptionRecovery
-51QV_ERR_HUGEPAGEHugepage allocation failedPre-allocate: echo N > /proc/sys/vm/nr_hugepages
-52QV_ERR_BALLOONBalloon driver communication failedInstall VirtIO balloon driver in guest; check guest agent
-53QV_ERR_HOTPLUG_MEMMemory hot-add failedGuest kernel must support ACPI memory hotplug; check max_size
-54QV_ERR_MEM_ENCRYPTMemory encryption setup failedVerify AMD SEV or Intel TDX support on host; check firmware
-55QV_ERR_NUMANUMA allocation failedRequested NUMA node doesn't exist or has insufficient memory

Storage Subsystem Errors #

CodeNameDescriptionRecovery
-400QV_STR_ERR_OPENFailed to open disk imageCheck file path, permissions, and format
-401QV_STR_ERR_FORMATUnrecognized or corrupt disk formatVerify format; run qemu-img check for qcow2
-402QV_STR_ERR_LOCKDisk image locked by another processCheck for other VMs using this disk; remove stale lock files
-403QV_STR_ERR_READONLYWrite to read-only diskSet "readonly": false or use a writable disk
-404QV_STR_ERR_FULLDisk image or storage pool fullExpand disk image; free host filesystem space
-405QV_STR_ERR_IODisk I/O errorCheck host disk health; verify NFS/iSCSI connectivity
-406QV_STR_ERR_QCOW2_CORRUPTQCOW2 metadata corruption detectedRun qemu-img check --repair; restore from backup
-407QV_STR_ERR_SNAPSHOTSnapshot operation failedCheck qcow2 integrity; ensure sufficient disk space
-408QV_STR_ERR_ENCRYPT_KEYDisk encryption key unavailableEnsure PQC subsystem is running; check keystore
-409QV_STR_ERR_ENCRYPT_FAILDisk encryption/decryption failedVerify key correctness; check QUAC 100 status
-410QV_STR_ERR_CONTROLLERStorage controller initialization failedCheck controller type compatibility; reduce queue count
-411QV_STR_ERR_DISCARDTRIM/discard operation failedVerify host filesystem supports discard; check VirtIO config

Network Subsystem Errors #

CodeNameDescriptionRecovery
-500QV_NET_ERR_CREATENetwork creation failedCheck for IP conflicts; verify bridge/TAP permissions
-501QV_NET_ERR_BRIDGEBridge interface errorVerify bridge exists: ip link show <bridge>; check permissions
-502QV_NET_ERR_TAPTAP device creation failedCheck /dev/net/tun permissions; load tun kernel module
-503QV_NET_ERR_VHOSTvhost-net activation failedLoad vhost_net module; check /dev/vhost-net permissions
-504QV_NET_ERR_VHOST_USERvhost-user socket connection failedVerify DPDK application is running; check socket path and permissions
-505QV_NET_ERR_DHCPDHCP server startup failedCheck for port conflicts; verify network subnet configuration
-506QV_NET_ERR_NATNAT/masquerade setup failedCheck iptables/nftables; verify IP forwarding is enabled
-507QV_NET_ERR_MACInvalid or duplicate MAC addressUse valid MAC format; let QuantaVirt auto-generate
-508QV_NET_ERR_MTUMTU configuration failedVerify host NIC supports requested MTU; check jumbo frame support
-509QV_NET_ERR_PQC_TUNNELPQC tunnel establishment failedCheck PQC subsystem status; verify remote endpoint supports PQC
-510QV_NET_ERR_FIREWALLFirewall rule application failedCheck iptables/nftables syntax; verify rule conflicts

PQC Subsystem (PQC_ERR_*) #

CodeNameDescriptionRecovery
-100PQC_ERR_INITPQC subsystem initialization failedCheck QUAC 100 driver loaded; verify /dev/quac100 exists
-101PQC_ERR_KEYGENKey generation failedCheck QRNG health; verify algorithm parameters
-102PQC_ERR_ENCAPSML-KEM encapsulation failedVerify public key validity; check input sizes
-103PQC_ERR_DECAPSML-KEM decapsulation failedVerify secret key matches; check ciphertext integrity
-104PQC_ERR_SIGNML-DSA signing failedVerify secret key; check message size
-105PQC_ERR_VERIFYML-DSA signature verification failedSignature invalid — possible tampering or key mismatch
-106PQC_ERR_ENCRYPTAEAD encryption failedCheck key and nonce; verify input length
-107PQC_ERR_DECRYPTAEAD decryption failed (auth tag mismatch)Data integrity violation — ciphertext tampered or wrong key
-108PQC_ERR_KEYSTOREKeystore access errorCheck keystore file permissions; verify keystore isn't locked
-109PQC_ERR_KEY_NOT_FOUNDReferenced key ID not found in keystoreList keys: quantavirt crypto key list; re-import key
-110PQC_ERR_KEY_EXPIREDKey has passed its expiration dateRotate key: quantavirt crypto key rotate
-111PQC_ERR_ALGORITHMUnsupported or invalid algorithm identifierUse valid strings: ML-KEM-512, ML-KEM-768, ML-KEM-1024, etc.
-112PQC_ERR_PARAM_SETInvalid parameter set for algorithmVerify parameter set matches algorithm (e.g. ML-DSA-44/65/87)
-113PQC_ERR_QRNGQRNG entropy unavailableCheck QRNG health: quantavirt crypto qrng status; wait for pool refill
-114PQC_ERR_SELF_TESTPQC self-test failedHardware/firmware fault — run diagnostics; contact support
-115PQC_ERR_ATTESTATIONVM attestation failedMeasurement mismatch — VM image may have been modified; re-attest
-116PQC_ERR_FALLBACKSoftware fallback failedBoth hardware and software backends unavailable; check installation
-117PQC_ERR_KDFKey derivation failedInvalid inputs to HKDF; check salt and info strings

QUAC 100 Hardware (QUAC100_ERR_*) #

Driver-level errors when communicating with the QUAC 100 PCIe card.

CodeNameDescriptionRecovery
-200QUAC100_ERR_NOT_FOUNDQUAC 100 device not detected on PCIe busReseat card; check lspci | grep 1DB7; verify power cable
-201QUAC100_ERR_DRIVERDriver initialization failedReload: modprobe quac100; check dmesg for errors
-202QUAC100_ERR_FW_VERSIONFirmware version incompatible with driverUpdate firmware: quantavirt crypto quac100 fw-update <image>
-203QUAC100_ERR_MMIOBAR0 MMIO mapping failedCheck IOMMU configuration; verify no address conflict in PCIe
-204QUAC100_ERR_RING_INITCommand/response ring initialization failedCheck DMA-capable memory allocation; verify IOMMU passthrough
-205QUAC100_ERR_RING_FULLCommand ring is fullWait for completions; increase ring size; check for stalled commands
-206QUAC100_ERR_DMADMA transfer failedCheck IOMMU mappings; verify physical address validity
-207QUAC100_ERR_INTERRUPTMSI-X interrupt delivery failureCheck interrupt allocation; verify MSI-X not exhausted
-208QUAC100_ERR_OVERTEMPDevice thermal throttling — operation rejectedImprove cooling; check fan operation; reduce workload
-209QUAC100_ERR_WATCHDOGHardware watchdog expiredDevice may be hung — reset: quantavirt crypto quac100 reset
-210QUAC100_ERR_SELF_TESTHardware self-test failedPower cycle system; if persistent, RMA the card
-211QUAC100_ERR_FW_UPDATEFirmware update failedDevice reverts to previous bank; retry update with verified image
-212QUAC100_ERR_NTTNTT engine errorReset NTT engine; check polynomial parameters
-213QUAC100_ERR_QRNG_HEALTHQRNG health test failedEntropy source degraded; device will auto-recover or use software RNG fallback
-214QUAC100_ERR_POWERAuxiliary power not connectedConnect 6-pin PCIe power cable to the QUAC 100

QUAC 100 Response Codes #

These are the 16-bit status codes returned in hardware response descriptors (see QUAC 100 Register Map → Response Codes). The driver translates them to QUAC100_ERR_* codes above.

CodeNameDescriptionMaps To
0x0000QUAC100_RESP_SUCCESSOperation completed successfullyQV_SUCCESS (0)
0x0001QUAC100_RESP_INVALID_OPCODEUnknown or unsupported opcodeQV_ERR_UNSUPPORTED (-15)
0x0002QUAC100_RESP_INVALID_PARAMInvalid parameter set or key handleQV_ERR_INVAL (-5)
0x0003QUAC100_RESP_INVALID_LENInput or output length out of rangeQV_ERR_INVAL (-5)
0x0004QUAC100_RESP_DMA_ERRORDMA read/write failedQUAC100_ERR_DMA (-206)
0x0005QUAC100_RESP_CRYPTO_FAILCryptographic operation failedPQC_ERR_DECRYPT (-107)
0x0006QUAC100_RESP_KEY_NOT_FOUNDKey ID not in hardware keystorePQC_ERR_KEY_NOT_FOUND (-109)
0x0007QUAC100_RESP_BUSYEngine busy — retry laterQV_ERR_AGAIN (-13)
0x0008QUAC100_RESP_TIMEOUTOperation timed out (watchdog)QUAC100_ERR_WATCHDOG (-209)
0x0009QUAC100_RESP_SELF_TEST_FAILSelf-test detected internal errorQUAC100_ERR_SELF_TEST (-210)
0x000AQUAC100_RESP_QRNG_DEPLETEDQRNG entropy pool emptyPQC_ERR_QRNG (-113)
0x000BQUAC100_RESP_QRNG_HEALTH_FAILQRNG health test failedQUAC100_ERR_QRNG_HEALTH (-213)
0x000CQUAC100_RESP_OVERTEMPRejected due to thermal throttlingQUAC100_ERR_OVERTEMP (-208)
0x000DQUAC100_RESP_FW_ERRORFirmware internal errorQV_ERR_GENERIC (-1)
0x00FFQUAC100_RESP_UNKNOWNUnknown error — hardware faultQV_ERR_GENERIC (-1)

Migration Errors #

CodeNameDescriptionRecovery
-300QV_MIG_ERR_CONNECTFailed to connect to destination hostCheck network connectivity; verify destination hypervisor is running
-301QV_MIG_ERR_AUTHMigration authentication failedVerify PQC key exchange; ensure both hosts share trust domain
-302QV_MIG_ERR_CPU_COMPATCPU model incompatible between hostsUse a named CPU model instead of "host"; match CPU features
-303QV_MIG_ERR_MEM_TRANSFERMemory page transfer failedCheck bandwidth; increase timeout; reduce dirty page rate
-304QV_MIG_ERR_CONVERGEDirty page rate exceeds transfer rate — migration cannot convergeEnable auto_converge; reduce guest I/O; increase bandwidth
-305QV_MIG_ERR_DOWNTIMEEstimated downtime exceeds max_downtime_msIncrease max_downtime_ms; reduce VM memory; use postcopy mode
-306QV_MIG_ERR_CANCELMigration was cancelledMigration aborted by user or policy — VM continues on source
-307QV_MIG_ERR_PQC_KEYPQC key exchange for migration channel failedVerify QUAC 100 or software PQC backend on both hosts
-308QV_MIG_ERR_STORAGEShared storage not accessible from destinationEnsure NFS/iSCSI/CEPH is mounted on both hosts
-309QV_MIG_ERR_RDMARDMA transport initialization failedVerify RDMA NICs and ibverbs; fall back to TCP transport
-310QV_MIG_ERR_DEVICEDevice state migration failedCheck device compatibility; hot-unplug problematic devices first

REST API Error Responses #

The REST API returns standard HTTP status codes with a JSON error body containing the internal error code.

HTTP StatusMeaningInternal CodesExample
400Bad RequestQV_ERR_INVAL, QV_ERR_CONFIGMalformed JSON, invalid parameter
401UnauthorizedQV_ERR_AUTHMissing or invalid API token
403ForbiddenQV_ERR_PERMToken lacks required permission scope
404Not FoundQV_ERR_NOENTVM, network, or disk not found
409ConflictQV_ERR_EXIST, QV_ERR_STATE, QV_ERR_BUSYName conflict; invalid state transition; resource locked
422Unprocessable EntityQV_ERR_CONFIG, QV_ERR_TOPOLOGYValid JSON but fails schema validation
429Too Many RequestsQV_ERR_LIMITAPI rate limit exceeded
500Internal Server ErrorQV_ERR_GENERICUnexpected internal error
503Service UnavailableQV_ERR_AGAIN, QUAC100_ERR_NOT_FOUNDHypervisor restarting; hardware unavailable
507Insufficient StorageQV_ERR_NOSPC, QV_ERR_NOMEMDisk space or memory exhausted
/* Example 409 Conflict response */
HTTP/1.1 409 Conflict
Content-Type: application/json

{
  "error": {
    "code": -16,
    "name": "QV_ERR_STATE",
    "message": "Invalid state transition",
    "detail": "Cannot migrate VM 'web-server': current state is STOPPED (must be RUNNING)",
    "subsystem": "hypervisor",
    "request_id": "req-7a3b4c5d"
  }
}

CLI Exit Codes #

The quantavirt CLI maps internal error codes to standard Unix exit codes (0–125).

Exit CodeMeaningInternal Errors
0SuccessQV_SUCCESS
1General errorQV_ERR_GENERIC, any unmapped error
2Invalid arguments / usageQV_ERR_INVAL, QV_ERR_CONFIG
3Resource not foundQV_ERR_NOENT
4Permission deniedQV_ERR_PERM, QV_ERR_AUTH
5Resource conflictQV_ERR_EXIST, QV_ERR_BUSY, QV_ERR_STATE
6Hardware not availableQV_ERR_NOVMX, QV_ERR_NODEV, QUAC100_ERR_NOT_FOUND
7Insufficient resourcesQV_ERR_NOMEM, QV_ERR_NOSPC, QV_ERR_LIMIT
8I/O errorQV_ERR_IO, QV_STR_ERR_IO
9TimeoutQV_ERR_TIMEOUT
10PQC / crypto errorPQC_ERR_* (any)
11Migration errorQV_MIG_ERR_* (any)
12Connection errorAPI socket unreachable
125Feature not supportedQV_ERR_UNSUPPORTED

Linux errno Mapping #

When QuantaVirt errors originate from system calls, the original errno is preserved and mapped.

errnoNameQuantaVirt Mapping
1EPERMQV_ERR_PERM (-9)
2ENOENTQV_ERR_NOENT (-6)
5EIOQV_ERR_IO (-11)
11EAGAINQV_ERR_AGAIN (-13)
12ENOMEMQV_ERR_NOMEM (-2)
13EACCESQV_ERR_PERM (-9)
16EBUSYQV_ERR_BUSY (-8)
17EEXISTQV_ERR_EXIST (-7)
19ENODEVQV_ERR_NODEV (-10)
22EINVALQV_ERR_INVAL (-5)
28ENOSPCQV_ERR_NOSPC (-14)
110ETIMEDOUTQV_ERR_TIMEOUT (-12)

Diagnostic Commands #

Commands for investigating errors and collecting diagnostic information.

Look Up Error Code

$ quantavirt system error-lookup -3
QV_ERR_NOVMX (-3)
  Description: Intel VMX / AMD SVM hardware virtualization not available
  Subsystem:   hypervisor
  Severity:    fatal
  Common Causes:
    - Hardware virtualization disabled in BIOS/UEFI
    - CPU does not support VT-x (Intel) or AMD-V (AMD)
    - Another hypervisor (VirtualBox, VMware) has locked VMX
  Recovery:
    1. Enable VT-x/AMD-V in BIOS/UEFI firmware settings
    2. Verify: grep -c 'vmx\|svm' /proc/cpuinfo
    3. Unload conflicting hypervisors: rmmod kvm_intel kvm

Search Logs by Error Code

$ quantavirt log tail --level error --last 1h
[2026-01-15 14:32:01 UTC] [ERROR] storage: QV_STR_ERR_LOCK (-402): /var/lib/quantavirt/disks/web.qcow2 locked by VM 'web-prod' (pid 4821)
[2026-01-15 14:32:01 UTC] [ERROR] vm: QV_ERR_VM_START (-22): VM 'web-staging' start failed: disk locked

$ quantavirt log tail --grep "PQC_ERR" --last 24h
[2026-01-15 10:15:43 UTC] [WARN] pqc: PQC_ERR_QRNG (-113): QRNG pool depleted, waiting for refill (pool: 0/4096 bytes)
[2026-01-15 10:15:44 UTC] [INFO] pqc: QRNG pool recovered (pool: 2048/4096 bytes)

Generate Support Bundle

$ quantavirt system support-bundle --output /tmp/diag.tar.gz
Collecting system info...         done
Collecting hypervisor logs...     done (42 MB)
Collecting VM configurations...   done (14 VMs)
Collecting QUAC 100 diagnostics.. done
Collecting kernel messages...     done
Collecting network state...       done
Redacting sensitive data...       done

Support bundle: /tmp/diag.tar.gz (8.2 MB compressed)
Upload to: support@dyber.org

C API Error Handling Functions

/* Error introspection API */
const char* qv_strerror(int code);         // Human-readable description
const char* qv_strerror_name(int code);    // Symbolic name (e.g. "QV_ERR_NOMEM")
const char* qv_strerror_subsystem(int code); // Subsystem name
int         qv_error_is_transient(int code); // 1 if retryable (AGAIN, BUSY, TIMEOUT)
int         qv_error_to_errno(int code);     // Map to closest Linux errno

/* Example usage */
int ret = qv_vm_create(&vm, config);
if (ret < 0) {
    if (qv_error_is_transient(ret)) {
        sleep(1);
        ret = qv_vm_create(&vm, config);  // retry
    } else {
        fprintf(stderr, "Fatal: %s (%d): %s\n",
                qv_strerror_name(ret), ret, qv_strerror(ret));
        return EXIT_FAILURE;
    }
}