From 3579408c72a45c7db77649de9ee04f14bd58d9de Mon Sep 17 00:00:00 2001 From: Xiaoxu Zeng Date: Thu, 6 Jul 2023 15:33:24 +0800 Subject: [PATCH] core: arm64: add dsb_osh() Implement the use of osh data barrier to ensure that all data access and modifications have been completed before executing subsequent instructions. Signed-off-by: Xiaoxu Zeng Reviewed-by: Jerome Forissier Reviewed-by: Jens Wiklander --- core/arch/arm/include/arm64.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/core/arch/arm/include/arm64.h b/core/arch/arm/include/arm64.h index 790a3cc8bdb..44460742b60 100644 --- a/core/arch/arm/include/arm64.h +++ b/core/arch/arm/include/arm64.h @@ -296,6 +296,11 @@ static inline __noprof void dsb_ishst(void) asm volatile ("dsb ishst" : : : "memory"); } +static inline __noprof void dsb_osh(void) +{ + asm volatile ("dsb osh" : : : "memory"); +} + static inline __noprof void sev(void) { asm volatile ("sev" : : : "memory");