summaryrefslogtreecommitdiff
path: root/include/sbi
diff options
context:
space:
mode:
authorAnup Patel <anup.patel@wdc.com>2021-02-01 13:43:03 +0300
committerAnup Patel <anup@brainfault.org>2021-03-03 07:47:41 +0300
commit8df1f9a0d33f295fc9f9cd5f6b9b723be96ba13b (patch)
tree601583c4879a1cd4e8d0ef0716d375e8bb7eef8a /include/sbi
parent5487cf095daecf72c81e2813dcce13e203398a55 (diff)
downloadopensbi-8df1f9a0d33f295fc9f9cd5f6b9b723be96ba13b.tar.xz
lib: sbi: Use SBI_HSM_STATE_xyz defines instead of SBI_STATE_xyz defines
We replace the use of SBI_STATE_xyz defines with SBI_HSM_STATE_xyz defines because the HSM state defines are complete enough to implement HSM state machine in OpenSBI. As a result of this, we can now remove sbi_hsm_hart_state_to_status() function because it is now redundant and sbi_hsm_hart_get_state() can directly return HSM state or error. Signed-off-by: Anup Patel <anup.patel@wdc.com> Reviewed-by: Atish Patra <atish.patra@wdc.com>
Diffstat (limited to 'include/sbi')
-rw-r--r--include/sbi/sbi_hsm.h8
1 files changed, 0 insertions, 8 deletions
diff --git a/include/sbi/sbi_hsm.h b/include/sbi/sbi_hsm.h
index 4823383..69ddee7 100644
--- a/include/sbi/sbi_hsm.h
+++ b/include/sbi/sbi_hsm.h
@@ -12,13 +12,6 @@
#include <sbi/sbi_types.h>
-/** Hart state values **/
-#define SBI_HART_STOPPED 0
-#define SBI_HART_STOPPING 1
-#define SBI_HART_STARTING 2
-#define SBI_HART_STARTED 3
-#define SBI_HART_UNKNOWN 4
-
struct sbi_domain;
struct sbi_scratch;
@@ -30,7 +23,6 @@ int sbi_hsm_hart_start(struct sbi_scratch *scratch,
u32 hartid, ulong saddr, ulong smode, ulong priv);
int sbi_hsm_hart_stop(struct sbi_scratch *scratch, bool exitnow);
int sbi_hsm_hart_get_state(const struct sbi_domain *dom, u32 hartid);
-int sbi_hsm_hart_state_to_status(int state);
int sbi_hsm_hart_started_mask(const struct sbi_domain *dom,
ulong hbase, ulong *out_hmask);
void sbi_hsm_prepare_next_jump(struct sbi_scratch *scratch, u32 hartid);