[PATCH v1 3/6] peci: Add support for PECI CC 0x83 retry condition
From: Changhuang Liang
Date: Thu Sep 03 2026 - 09:51:58 EST
Some PECI client devices may return completion code 0x83 (CMD_TIMEOUT)
under certain conditions, which is not currently handled by the driver.
Add PECI_CC_CMD_TIMEOUT definition and map it to -EAGAIN so that the
request will be retried appropriately, similar to other retryable
completion codes (0x80, 0x81, 0x82).
Signed-off-by: Changhuang Liang <changhuang.liang@xxxxxxxxxxxxxxxx>
---
drivers/peci/request.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/peci/request.c b/drivers/peci/request.c
index db2cc30a42a4..2bf8b6a255d4 100644
--- a/drivers/peci/request.c
+++ b/drivers/peci/request.c
@@ -71,6 +71,7 @@
#define PECI_CC_NEED_RETRY 0x80
#define PECI_CC_OUT_OF_RESOURCE 0x81
#define PECI_CC_UNAVAIL_RESOURCE 0x82
+#define PECI_CC_CMD_TIMEOUT 0x83
#define PECI_CC_INVALID_REQ 0x90
#define PECI_CC_MCA_ERROR 0x91
#define PECI_CC_CATASTROPHIC_MCA_ERROR 0x93
@@ -112,6 +113,7 @@ int peci_request_status(struct peci_request *req)
case PECI_CC_NEED_RETRY:
case PECI_CC_OUT_OF_RESOURCE:
case PECI_CC_UNAVAIL_RESOURCE:
+ case PECI_CC_CMD_TIMEOUT:
return -EAGAIN;
case PECI_CC_INVALID_REQ:
return -EINVAL;
--
2.25.1