include: sbi: Use scratch pointer as parmeter in HART feature APIs

It makes more sense to have scratch pointer as parameter in
HART feature APIs because:
1. We already have scratch pointer at places where these APIs
   are used.
2. This is consistent with lot of other APIs in sbi_hart.h

Signed-off-by: Anup Patel <anup.patel@wdc.com>
Reviewed-by: Atish Patra <atish.patra@wdc.com>
This commit is contained in:
Anup Patel authored and Anup Patel committed 2020-05-19 09:19:42 +05:30
1 parent 3a8fc81357
commit 63b0f5f71a
5 files changed
+32 -31

No files matched your search

+1 -1
View File
@@ -114,7 +114,7 @@ int sbi_timer_init(struct sbi_scratch *scratch, bool cold_boot)
if (ret)
return ret;
if (sbi_hart_has_feature(current_hartid(), SBI_HART_HAS_TIME))
if (sbi_hart_has_feature(scratch, SBI_HART_HAS_TIME))
get_time_val = get_ticks;
else if (sbi_platform_has_timer_value(plat))
get_time_val = sbi_platform_timer_value;