diff mbox series

[v6,2/2] manual: Add description of AArch64-specific pkey flags

Message ID 20241101121709.2227463-3-yury.khrustalev@arm.com
State New
Headers show
Series aarch64: Add support for memory protection keys | expand

Commit Message

Yury Khrustalev Nov. 1, 2024, 12:17 p.m. UTC
Describe AArch64 specific flags PKEY_DISABLE_READ and PKEY_DISABLE_EXECUTE that
are available on AArch64 systems with enabled Stage 1 permission overlays feature
introduced in Armv8.9 / 9.4 (FEAT_S1POE).
---
 manual/memory.texi | 16 +++++++++++++++-
 1 file changed, 15 insertions(+), 1 deletion(-)

Comments

Adhemerval Zanella Netto Nov. 18, 2024, 8:39 p.m. UTC | #1
On 01/11/24 09:17, Yury Khrustalev wrote:
> Describe AArch64 specific flags PKEY_DISABLE_READ and PKEY_DISABLE_EXECUTE that
> are available on AArch64 systems with enabled Stage 1 permission overlays feature
> introduced in Armv8.9 / 9.4 (FEAT_S1POE).

LGTM, thanks.

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>


> ---
>  manual/memory.texi | 16 +++++++++++++++-
>  1 file changed, 15 insertions(+), 1 deletion(-)
> 
> diff --git a/manual/memory.texi b/manual/memory.texi
> index 58683ee93d..e939f6a504 100644
> --- a/manual/memory.texi
> +++ b/manual/memory.texi
> @@ -3261,6 +3261,12 @@ applied.  Otherwise, @var{rights} is a combination of the following
>  flags:
>  
>  @vtable @code
> +@item PKEY_DISABLE_READ
> +@standards{Linux, sys/mman.h}
> +Subsequent attempts to read from memory with the specified protection
> +key will fault.  At present only AArch64 platforms with enabled Stage 1
> +permission overlays feature support this type of restriction.
> +
>  @item PKEY_DISABLE_WRITE
>  @standards{Linux, sys/mman.h}
>  Subsequent attempts to write to memory with the specified protection
> @@ -3269,7 +3275,15 @@ key will fault.
>  @item PKEY_DISABLE_ACCESS
>  @standards{Linux, sys/mman.h}
>  Subsequent attempts to write to or read from memory with the specified
> -protection key will fault.
> +protection key will fault.  On AArch64 platforms with enabled Stage 1
> +permission overlays feature this restriction value has the same effect
> +as combination of @code{PKEY_DISABLE_READ} and @code{PKEY_DISABLE_WRITE}.
> +
> +@item PKEY_DISABLE_EXECUTE
> +@standards{Linux, sys/mman.h}
> +Subsequent attempts to execute from memory with the specified protection
> +key will fault.  At present only AArch64 platforms with enabled Stage 1
> +permission overlays feature support this type of restriction.
>  @end vtable
>  
>  Operations not specified as flags are not restricted.  In particular,
diff mbox series

Patch

diff --git a/manual/memory.texi b/manual/memory.texi
index 58683ee93d..e939f6a504 100644
--- a/manual/memory.texi
+++ b/manual/memory.texi
@@ -3261,6 +3261,12 @@  applied.  Otherwise, @var{rights} is a combination of the following
 flags:
 
 @vtable @code
+@item PKEY_DISABLE_READ
+@standards{Linux, sys/mman.h}
+Subsequent attempts to read from memory with the specified protection
+key will fault.  At present only AArch64 platforms with enabled Stage 1
+permission overlays feature support this type of restriction.
+
 @item PKEY_DISABLE_WRITE
 @standards{Linux, sys/mman.h}
 Subsequent attempts to write to memory with the specified protection
@@ -3269,7 +3275,15 @@  key will fault.
 @item PKEY_DISABLE_ACCESS
 @standards{Linux, sys/mman.h}
 Subsequent attempts to write to or read from memory with the specified
-protection key will fault.
+protection key will fault.  On AArch64 platforms with enabled Stage 1
+permission overlays feature this restriction value has the same effect
+as combination of @code{PKEY_DISABLE_READ} and @code{PKEY_DISABLE_WRITE}.
+
+@item PKEY_DISABLE_EXECUTE
+@standards{Linux, sys/mman.h}
+Subsequent attempts to execute from memory with the specified protection
+key will fault.  At present only AArch64 platforms with enabled Stage 1
+permission overlays feature support this type of restriction.
 @end vtable
 
 Operations not specified as flags are not restricted.  In particular,