@@ -15,43 +15,42 @@
enum uds_status_codes {
/* Successful return */
UDS_SUCCESS = 0,
-
/* Used as a base value for reporting internal errors */
UDS_ERROR_CODE_BASE = 1024,
/* Index overflow */
- UDS_OVERFLOW = UDS_ERROR_CODE_BASE + 0,
+ UDS_OVERFLOW = UDS_ERROR_CODE_BASE,
/* Invalid argument passed to internal routine */
- UDS_INVALID_ARGUMENT = UDS_ERROR_CODE_BASE + 1,
+ UDS_INVALID_ARGUMENT,
/* UDS data structures are in an invalid state */
- UDS_BAD_STATE = UDS_ERROR_CODE_BASE + 2,
+ UDS_BAD_STATE,
/* Attempt to enter the same name into an internal structure twice */
- UDS_DUPLICATE_NAME = UDS_ERROR_CODE_BASE + 3,
+ UDS_DUPLICATE_NAME,
/* An assertion failed */
- UDS_ASSERTION_FAILED = UDS_ERROR_CODE_BASE + 4,
+ UDS_ASSERTION_FAILED,
/* A request has been queued for later processing (not an error) */
- UDS_QUEUED = UDS_ERROR_CODE_BASE + 5,
+ UDS_QUEUED,
/* A problem has occurred with a buffer */
- UDS_BUFFER_ERROR = UDS_ERROR_CODE_BASE + 6,
+ UDS_BUFFER_ERROR,
/* No directory was found where one was expected */
- UDS_NO_DIRECTORY = UDS_ERROR_CODE_BASE + 7,
+ UDS_NO_DIRECTORY,
/* This error range has already been registered */
- UDS_ALREADY_REGISTERED = UDS_ERROR_CODE_BASE + 8,
+ UDS_ALREADY_REGISTERED,
/* Attempt to read or write data outside the valid range */
- UDS_OUT_OF_RANGE = UDS_ERROR_CODE_BASE + 9,
+ UDS_OUT_OF_RANGE,
/* Could not load modules */
- UDS_EMODULE_LOAD = UDS_ERROR_CODE_BASE + 10,
+ UDS_EMODULE_LOAD,
/* The index session is disabled */
- UDS_DISABLED = UDS_ERROR_CODE_BASE + 11,
+ UDS_DISABLED,
/* Unknown error */
- UDS_UNKNOWN_ERROR = UDS_ERROR_CODE_BASE + 12,
+ UDS_UNKNOWN_ERROR,
/* The index configuration or volume format is no longer supported */
- UDS_UNSUPPORTED_VERSION = UDS_ERROR_CODE_BASE + 13,
+ UDS_UNSUPPORTED_VERSION,
/* Some index structure is corrupt */
- UDS_CORRUPT_DATA = UDS_ERROR_CODE_BASE + 14,
+ UDS_CORRUPT_DATA,
/* No index state found */
- UDS_NO_INDEX = UDS_ERROR_CODE_BASE + 15,
+ UDS_NO_INDEX,
/* Attempt to access incomplete index save data */
- UDS_INDEX_NOT_SAVED_CLEANLY = UDS_ERROR_CODE_BASE + 16,
+ UDS_INDEX_NOT_SAVED_CLEANLY,
/* One more than the last UDS_INTERNAL error code */
UDS_ERROR_CODE_LAST,
/* One more than the last error this block will ever use */
@@ -12,14 +12,12 @@ enum {
UDS_BLOCK_SIZE = UDS_ERROR_CODE_BLOCK_END - UDS_ERROR_CODE_BASE,
VDO_BLOCK_START = UDS_ERROR_CODE_BLOCK_END,
VDO_BLOCK_END = VDO_BLOCK_START + UDS_BLOCK_SIZE,
- PRP_BLOCK_START = VDO_BLOCK_END,
- PRP_BLOCK_END = PRP_BLOCK_START + UDS_BLOCK_SIZE,
};
/* VDO-specific status codes. */
enum vdo_status_codes {
/* successful result */
- VDO_SUCCESS,
+ VDO_SUCCESS = UDS_SUCCESS,
/* base of all VDO errors */
VDO_STATUS_CODE_BASE = VDO_BLOCK_START,
/* we haven't written this yet */