Skip to content

Commit

Permalink
sandbox: allow PR_GET_TAGGED_ADDR_CTRL
Browse files Browse the repository at this point in the history
prctl(PR_GET_TAGGED_ADDR_CTRL, ...) lets Chromium set and get the
current memory tagging mode via the partition allocator.

Also gates PR_PAC_RESET_KEYS to AArch64.

(cherry picked from commit 2845592)

(cherry picked from commit 4c46052)

Bug: 1137393, 1445768
Change-Id: I4412a7f8bf483de778b21aa71a24c33474fed519
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4526176
Reviewed-by: Matthew Denton <mpdenton@chromium.org>
Commit-Queue: Matthew Denton <mpdenton@chromium.org>
Cr-Original-Original-Commit-Position: refs/heads/main@{#1145071}
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4543018
Reviewed-by: Erhu Akpobaro <eakpobaro@google.com>
Commit-Queue: Erhu Akpobaro <eakpobaro@google.com>
Reviewed-by: Nate Fischer <ntfschr@chromium.org>
Reviewed-by: Will Harris <wfh@chromium.org>
Commit-Queue: Krishna Govind <govind@chromium.org>
Cr-Original-Commit-Position: refs/branch-heads/5672@{#1233}
Cr-Original-Branched-From: 5f2a724-refs/heads/main@{#1121455}
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4545208
Reviewed-by: Krishna Govind <govind@chromium.org>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Owners-Override: Krishna Govind <govind@chromium.org>
Cr-Commit-Position: refs/branch-heads/5672_131@{#3}
Cr-Branched-From: 6f44fe7-refs/branch-heads/5672@{#1207}
Cr-Branched-From: 5f2a724-refs/heads/main@{#1121455}
  • Loading branch information
richard-townsend-arm authored and Krishna Govind committed May 17, 2023
1 parent 345664c commit 007c5f6
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,10 @@ ResultExpr RestrictPrctl() {
.Cases({PR_GET_NAME, PR_SET_NAME, PR_GET_DUMPABLE, PR_SET_DUMPABLE
#if BUILDFLAG(IS_ANDROID)
, PR_SET_VMA, PR_SET_PTRACER, PR_SET_TIMERSLACK
, PR_GET_NO_NEW_PRIVS, PR_PAC_RESET_KEYS
, PR_GET_NO_NEW_PRIVS
#if defined(ARCH_CPU_ARM64)
, PR_PAC_RESET_KEYS, PR_GET_TAGGED_ADDR_CTRL
#endif

// Enable PR_SET_TIMERSLACK_PID, an Android custom prctl which is used in:
// https://android.googlesource.com/platform/system/core/+/lollipop-release/libcutils/sched_policy.c.
Expand Down

0 comments on commit 007c5f6

Please sign in to comment.