summaryrefslogtreecommitdiff
path: root/include/sbi/sbi_error.h
diff options
context:
space:
mode:
authorAnup Patel <anup.patel@wdc.com>2019-04-03 07:54:03 +0300
committerAtish Patra <atishp04@gmail.com>2019-04-03 23:48:38 +0300
commit9dc95021dbf29b96a84e0b7dca491f768aa0ef0d (patch)
treeec694df5cafb17c992f3107336cbddc33dff7815 /include/sbi/sbi_error.h
parent6dc1b0f6e2f895f220c284d9166205400fc98428 (diff)
downloadopensbi-9dc95021dbf29b96a84e0b7dca491f768aa0ef0d.tar.xz
lib: More improvements to sbi_fifo
This patch does following improvements to sbi_fifo: 1. Use valid SBI_Exxxx error codes instead of -1 2. The sbi_fifo_is_full() and sbi_fifo_is_empty() did not acquire qlock before accessing head and tail hence fixed it 3. Added avail member for ease in debugging and simplifying head/tail updates. Due to above changes size of sbi_fifo changes from 48 bytes to 56 bytes. Signed-off-by: Anup Patel <anup.patel@wdc.com>
Diffstat (limited to 'include/sbi/sbi_error.h')
-rw-r--r--include/sbi/sbi_error.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/sbi/sbi_error.h b/include/sbi/sbi_error.h
index 68076e7..300ee74 100644
--- a/include/sbi/sbi_error.h
+++ b/include/sbi/sbi_error.h
@@ -21,5 +21,6 @@
#define SBI_ETIMEDOUT -8
#define SBI_EIO -9
#define SBI_EILL -10
+#define SBI_ENOSPC -11
#endif