From 58438db241099abf0f8f407e4fa2931ce66f0395 Mon Sep 17 00:00:00 2001 From: Jakob Bornecrantz Date: Tue, 17 May 2022 18:45:34 +0100 Subject: [PATCH] xrt: Add some error messages --- src/xrt/auxiliary/util/u_pretty_print.c | 6 ++++++ src/xrt/include/xrt/xrt_results.h | 24 ++++++++++++++++++++++++ 2 files changed, 30 insertions(+) diff --git a/src/xrt/auxiliary/util/u_pretty_print.c b/src/xrt/auxiliary/util/u_pretty_print.c index d2c790a82..40e0142fc 100644 --- a/src/xrt/auxiliary/util/u_pretty_print.c +++ b/src/xrt/auxiliary/util/u_pretty_print.c @@ -273,6 +273,12 @@ u_pp_xrt_result(struct u_pp_delegate dg, xrt_result_t xret) case XRT_ERROR_THREADING_INIT_FAILURE: DG("XRT_ERROR_THREADING_INIT_FAILURE"); return; case XRT_ERROR_IPC_SESSION_NOT_CREATED: DG("XRT_ERROR_IPC_SESSION_NOT_CREATED"); return; case XRT_ERROR_IPC_SESSION_ALREADY_CREATED: DG("XRT_ERROR_IPC_SESSION_ALREADY_CREATED"); return; + case XRT_ERROR_PROBER_NOT_SUPPORTED: DG("XRT_ERROR_PROBER_NOT_SUPPORTED"); return; + case XRT_ERROR_PROBER_CREATION_FAILED: DG("XRT_ERROR_PROBER_CREATION_FAILED"); return; + case XRT_ERROR_PROBER_LIST_LOCKED: DG("XRT_ERROR_PROBER_LIST_LOCKED"); return; + case XRT_ERROR_PROBER_LIST_NOT_LOCKED: DG("XRT_ERROR_PROBER_LIST_NOT_LOCKED"); return; + case XRT_ERROR_PROBING_FAILED: DG("XRT_ERROR_PROBING_FAILED"); return; + case XRT_ERROR_DEVICE_CREATION_FAILED: DG("XRT_ERROR_DEVICE_CREATION_FAILED"); return; // clang-format on default: break; } diff --git a/src/xrt/include/xrt/xrt_results.h b/src/xrt/include/xrt/xrt_results.h index e494dc1bc..a4d4ca227 100644 --- a/src/xrt/include/xrt/xrt_results.h +++ b/src/xrt/include/xrt/xrt_results.h @@ -78,4 +78,28 @@ typedef enum xrt_result * The client has already created a session on this IPC connection. */ XRT_ERROR_IPC_SESSION_ALREADY_CREATED = -16, + /*! + * The prober list has not been locked before this call. + */ + XRT_ERROR_PROBER_NOT_SUPPORTED = -17, + /*! + * Creating the @ref xrt_prober failed. + */ + XRT_ERROR_PROBER_CREATION_FAILED = -18, + /*! + * The prober list is locked (already). + */ + XRT_ERROR_PROBER_LIST_LOCKED = -19, + /*! + * The prober list has not been locked before this call. + */ + XRT_ERROR_PROBER_LIST_NOT_LOCKED = -20, + /*! + * The probring failed. + */ + XRT_ERROR_PROBING_FAILED = -21, + /*! + * Creating a @ref xrt_device failed. + */ + XRT_ERROR_DEVICE_CREATION_FAILED = -22, } xrt_result_t;