On Wed, Sep 28, 2022 at 04:31:42PM +0100, Kevin Brodsky wrote:
Add a new uapi header to define generic CHERI concepts with arm64-specific values.
To start with, provide a macro representing the VMem software permission, as defined in the PCuABI specification. The macro name matches CheriBSD, facilitating its use in a (somewhat) OS-agnostic way.
Signed-off-by: Kevin Brodsky kevin.brodsky@arm.com
arch/arm64/include/uapi/asm/cheri.h | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 arch/arm64/include/uapi/asm/cheri.h
diff --git a/arch/arm64/include/uapi/asm/cheri.h b/arch/arm64/include/uapi/asm/cheri.h new file mode 100644 index 000000000000..8f2b8f885fda --- /dev/null +++ b/arch/arm64/include/uapi/asm/cheri.h @@ -0,0 +1,7 @@ +/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ +#ifndef _UAPI__ASM_CHERI_H +#define _UAPI__ASM_CHERI_H
+#define CHERI_PERM_SW_VMEM (1 << 2) /* User[0] permission */
This is Morello specific software permission bit, in somewhat generic header, but I do appreciate it's arch specific so there should be no confusion there, still it made be ... pause for a moment there. Not sure if adding a comment would make much difference here though.
--- BR B.
+#endif /* _UAPI__ASM_CHERI_H */
2.34.1
linux-morello mailing list -- linux-morello@op-lists.linaro.org To unsubscribe send an email to linux-morello-leave@op-lists.linaro.org