riscv: introduce nops and __nops macros for NOP sequences
From: Heiko Stuebner <heiko@...> Date: Mon, 16 May 2022 23:48:56 +0200
Commit-Message
NOP sequences tend to get used for padding out alternative sections This change adds macros for generating these sequences as both inline asm blocks, but also as strings suitable for embedding in other asm blocks directly. It essentially mimics similar functionality from arm64 introduced by Wil Deacon in commit f99a250cb6a3 ("arm64: barriers: introduce nops and __nops macros for NOP sequences"). Signed-off-by: Heiko Stuebner <heiko@...>
Patch-Comment
arch/riscv/include/asm/asm.h | 15 +++++++++++++++ arch/riscv/include/asm/barrier.h | 2 ++ 2 files changed, 17 insertions(+)
Statistics
- 17 lines added
- 0 lines removed