diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/sbi/sbi_scratch.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/sbi/sbi_scratch.h b/include/sbi/sbi_scratch.h index e848900..8086207 100644 --- a/include/sbi/sbi_scratch.h +++ b/include/sbi/sbi_scratch.h @@ -113,6 +113,12 @@ extern struct sbi_scratch *hartid_to_scratch_table[]; #define sbi_hartid_to_scratch(__hartid) \ hartid_to_scratch_table[__hartid] +/** Last HART id having a sbi_scratch pointer */ +extern u32 last_hartid_having_scratch; + +/** Get last HART id having a sbi_scratch pointer */ +#define sbi_scratch_last_hartid() last_hartid_having_scratch + #endif #endif |