Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 63edc66f authored by Kalesh Singh's avatar Kalesh Singh
Browse files

init: Remove obsolete kptr_restrict builtin



Remove the SetKptrRestrictAction builtin from init and set the
kptr_restrict value directly in init.rc.

The builtin action attempted to set kptr_restrict to a maximum value of 4.
This was a carryover from legacy 4.4 kernels that included out-of-tree
Android patches to support values 3 and 4 for additional pointer
filtering.

Since 4.9 android kernels follow the upstream Linux kernel, which only
supports values 0, 1, and 2 for this sysctl. The previous builtin
was therefore attempting to set invalid values.

Remove the obsolete builtin action and raise kptr_restrict to 2 directly
in init.rc in the 'on init' trigger, where the other sysctls are set.

Bug: 440136658
Bug: 419635765
Test: Boot; check /proc/sys/kernel/kptr_restrict is 2.
Change-Id: If4d3c2671efb12de974a8139a549a4a39916a573
Signed-off-by: default avatarKalesh Singh <kaleshsingh@google.com>
parent d9430da5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment