From 899e65b942bef4dec7fec6383a7f45e270fbc463 Mon Sep 17 00:00:00 2001 From: Tariq Kurd Date: Tue, 28 May 2024 11:22:45 +0200 Subject: [PATCH] remove the M-bit from AP --- src/cap-description.adoc | 14 ++++++++------ src/img/cap-encoding-xlen32.edn | 2 +- src/img/cap-encoding-xlen64.edn | 7 ++++--- 3 files changed, 13 insertions(+), 10 deletions(-) diff --git a/src/cap-description.adoc b/src/cap-description.adoc index 7147e0f0..8fb57f89 100644 --- a/src/cap-description.adoc +++ b/src/cap-description.adoc @@ -136,8 +136,8 @@ Therefore, it is only possible to encode a subset of all combinations. [#perms_bit_width,options=header,align="center",width="80%",cols="^13%,^27%,<60%"] |============================================================================== ^| MXLEN | Permissions width | Comment -^| 32 | {cap_rv32_perms_width} | Encodes some combinations of 5 permission bits and the <> -^| 64 | {cap_rv64_perms_width} | Separate bits for each permission and the <> +^| 32 | {cap_rv32_perms_width} | Encodes some combinations of 5 permission bits and _includes_ the <> in quadrant 1 (see <>) +^| 64 | {cap_rv32_perms_width} | Separate bits for each permission, _excluding_ the <> |============================================================================== For MXLEN=32, the permissions encoding is split into four quadrants. @@ -206,12 +206,14 @@ permission. | 2 | <> | 3 | <> | 4 | <> -| 5 | <> +//| 5 | <> |============================================================================== -For both MXLEN=32 and MXLEN=64, the <> is only assigned meaning when the -implementation supports {cheri_default_ext_name}, otherwise the bit is reserved -and must be 0 in valid capabilities. +The <> is only assigned meaning when the +implementation supports {cheri_default_ext_name} _and_ <> is set. + +. For MXLEN=64, the bit assigned to the <> must be zero if <> isn't set. +. For MXLEN=32, the <> is only encoded in quadrant 1 and does _not_ exist in the other quadrants. ===== Permission Transitions diff --git a/src/img/cap-encoding-xlen32.edn b/src/img/cap-encoding-xlen32.edn index 83bc6594..1478b500 100644 --- a/src/img/cap-encoding-xlen32.edn +++ b/src/img/cap-encoding-xlen32.edn @@ -9,7 +9,7 @@ (draw-column-headers {:height 50 :font-size 26 :labels (reverse ["0" "1" "2" "" "" "" "" "" "" "9" "10" "11" "12" "" "" "" "" "17" "18" "19" "20" "21" "" "" "24" "25" "" "" "" "29" "30" "31"])}) (draw-box "SDP" {:span 2}) -(draw-box "AP" {:span 5}) +(draw-box "AP, M" {:span 5}) (draw-box "Reserved" {:span 4}) (draw-box "S" {:span 1}) (draw-box "EF" {:span 1}) diff --git a/src/img/cap-encoding-xlen64.edn b/src/img/cap-encoding-xlen64.edn index 67319396..d9e3af04 100644 --- a/src/img/cap-encoding-xlen64.edn +++ b/src/img/cap-encoding-xlen64.edn @@ -6,12 +6,13 @@ (def left-margin 100) (def right-margin 100) (def boxes-per-row 32) -(draw-column-headers {:height 50 :font-size 26 :labels (reverse ["0" "2" "3" "" "" "" "13" "14" "16" "17" "" "" "25" "26" "27" "28" "" "" "" "" "" "" "" "46" "47" "52" "53" "56" "57" "" "" "63"])}) +(draw-column-headers {:height 50 :font-size 26 :labels (reverse ["0" "2" "3" "" "" "" "13" "14" "16" "17" "" "" "25" "26" "27" "28" "" "" "" "" "" "46" "" "47" "51" "52" "53" "56" "57" "" "" "63"])}) (draw-box "Reserved" {:span 4}) (draw-box "SDP" {:span 2}) -(draw-box "AP" {:span 2}) -(draw-box "Reserved" {:span 9}) +(draw-box "M" {:span 1}) +(draw-box "AP" {:span 3}) +(draw-box "Reserved" {:span 7}) (draw-box "S" {:span 1}) (draw-box "EF" {:span 1}) (draw-box "T[11:3]" {:span 4})