DAOS API: GURT

| DAOS API (v2.1 - dev)

Loading...
Searching...
No Matches
GURT

## Macros
#define | D_FOREACH_GURT_ERR(ACTION)
#define | D_FOREACH_DAOS_ERR(ACTION)
#define | D_FOREACH_ERR_RANGE(ACTION)
#define | D_DEFINE_ERRNO(name, desc)
#define | D_DEFINE_ERRSTR(name, desc)
#define | D_DEFINE_ERRDESC(name, desc)
#define | D_DEFINE_RANGE_ERRNO(name, base)

## Enumerations
enum | daos_errno { DER_SUCCESS = 0 , DER_LAST_VALID , DER_UNKNOWN = (DER_ERR_GURT_BASE + 500000) }

## Functions
const char * | d_errstr (int errnum)
const char * | d_errdesc (int errnum)

## Detailed Description

(C) Copyright 2016-2024 Intel Corporation. (C) Copyright 2025-2026 Hewlett Packard Enterprise Development LP

SPDX-License-Identifier: BSD-2-Clause-Patent DAOS Error numbers

## Macro Definition Documentation

## ◆ D_DEFINE_ERRDESC

#define D_DEFINE_ERRDESC | ( |  | name,
|  |  | desc )

Value:
#desc,

Preprocessor machinery for defining error descriptions

Definition at line 231 of file daos_errno.h.

## ◆ D_DEFINE_ERRNO

#define D_DEFINE_ERRNO | ( |  | name,
|  |  | desc )

Value:
name,

Preprocessor machinery for defining error numbers

Definition at line 227 of file daos_errno.h.

## ◆ D_DEFINE_ERRSTR

#define D_DEFINE_ERRSTR | ( |  | name,
|  |  | desc )

Value:
#name,

Preprocessor machinery for defining error number strings

Definition at line 229 of file daos_errno.h.

## ◆ D_DEFINE_RANGE_ERRNO

#define D_DEFINE_RANGE_ERRNO | ( |  | name,
|  |  | base )

Value:
DER_ERR_##name##_BASE = (base), D_FOREACH_##name##_ERR(D_DEFINE_ERRNO)
D_DEFINE_ERRNO
#define D_DEFINE_ERRNO(name, desc)
Definition daos_errno.h:227

Preprocessor machinery to define a consecutive range of error numbers

Definition at line 234 of file daos_errno.h.

## ◆ D_FOREACH_DAOS_ERR

#define D_FOREACH_DAOS_ERR | ( |  | ACTION | ) |

Preprocessor macro defining DAOS errno values and internal definition of d_errstr

Definition at line 126 of file daos_errno.h.

## ◆ D_FOREACH_ERR_RANGE

#define D_FOREACH_ERR_RANGE | ( |  | ACTION | ) |

Value:
ACTION(GURT, 1000) \
ACTION(DAOS, 2000)

Defines the gurt error codes

Definition at line 222 of file daos_errno.h.

## ◆ D_FOREACH_GURT_ERR

#define D_FOREACH_GURT_ERR | ( |  | ACTION | ) |

Preprocessor macro defining GURT errno values and internal definition of d_errstr

Definition at line 31 of file daos_errno.h.

## Enumeration Type Documentation

## ◆ daos_errno

enum daos_errno

The actual error codes

Enumerator
DER_SUCCESS | Return value representing success
DER_LAST_VALID | Last valid errno, used for dumping
DER_UNKNOWN | Unknown error value

Definition at line 238 of file daos_errno.h.

## Function Documentation

## ◆ d_errdesc()

const char * d_errdesc | ( | int | errnum | ) |

Return an error description string associated with a registered gurt errno.

Parameters

  [in] | errnum | The error code

Returns
  The error description string, or an "Unknown error nnn" message if the error number is unknown.

## ◆ d_errstr()

const char * d_errstr | ( | int | errnum | ) |

Return a string associated with a registered gurt errno

Parameters

  [in] | errnum | The error code

Returns
  String value for error code or DER_UNKNOWN