From 3d335bc54b453dd69b269c8841657876fb48f15f Mon Sep 17 00:00:00 2001
From: Atish Patra <atish.patra@wdc.com>
Date: Wed, 2 Oct 2019 13:59:36 -0700
Subject: lib: Align error codes as per SBI specification.

Follow the SBI specification for error codes.

Signed-off-by: Atish Patra <atish.patra@wdc.com>
Reviewed-by: Anup Patel <anup.patel@wdc.com>
---
 include/sbi/sbi_error.h | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/include/sbi/sbi_error.h b/include/sbi/sbi_error.h
index 3ad78db..4b7dd12 100644
--- a/include/sbi/sbi_error.h
+++ b/include/sbi/sbi_error.h
@@ -13,11 +13,11 @@
 /* clang-format off */
 
 #define SBI_OK		0
-#define SBI_EUNKNOWN	-1
-#define SBI_EFAIL	-2
+#define SBI_EFAIL	-1
+#define SBI_ENOTSUPP	-2
 #define SBI_EINVAL	-3
-#define SBI_ENOENT	-4
-#define SBI_ENOTSUPP	-5
+#define SBI_DENIED	-4
+#define SBI_INVALID_ADDR -5
 #define SBI_ENODEV	-6
 #define SBI_ENOSYS	-7
 #define SBI_ETIMEDOUT	-8
@@ -26,6 +26,8 @@
 #define SBI_ENOSPC	-11
 #define SBI_ENOMEM	-12
 #define SBI_ETRAP	-13
+#define SBI_EUNKNOWN	-14
+#define SBI_ENOENT	-15
 
 /* clang-format on */
 
-- 
cgit v1.2.3