From eee8e04b92d98d018ab702c8720565336bc0ab14 Mon Sep 17 00:00:00 2001 From: JJ Lee Date: Mon, 18 Mar 2024 10:56:05 +0000 Subject: [PATCH 1/4] Dumpstate: add DVFSA32 and lengthen timeouts for memory_votes_* Bug: 328362738 Test: build pass Change-Id: I0db129604911794e0fbdaf91b67b2e6fbda07e4d Signed-off-by: JJ Lee --- aoc/dump_aoc.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/aoc/dump_aoc.cpp b/aoc/dump_aoc.cpp index b3827c8..baf056e 100644 --- a/aoc/dump_aoc.cpp +++ b/aoc/dump_aoc.cpp @@ -29,9 +29,10 @@ int main() { runCommand("AoC logging wake", "timeout 0.1 cat /sys/devices/platform/*.aoc/control/logging_wakeup"); runCommand("AoC hotword wake", "timeout 0.1 cat /sys/devices/platform/*.aoc/control/hotword_wakeup"); runCommand("AoC memory exception wake", "timeout 0.1 cat /sys/devices/platform/*.aoc/control/memory_exception"); - runCommand("AoC memory votes", "timeout 0.1 cat /sys/devices/platform/*.aoc/control/memory_votes_a32"); - runCommand("AoC memory votes", "timeout 0.1 cat /sys/devices/platform/*.aoc/control/memory_votes_ff1"); + runCommand("AoC memory votes", "timeout 0.5 cat /sys/devices/platform/*.aoc/control/memory_votes_a32"); + runCommand("AoC memory votes", "timeout 0.5 cat /sys/devices/platform/*.aoc/control/memory_votes_ff1"); runCommand("clean AoC buffer","echo ' ' > /dev/acd-debug; timeout 0.1 cat /dev/acd-debug"); + runCommand("AoC DVFS (A32)", "echo 'dbg info -c 1 DVFSA32' > /dev/acd-debug; timeout 0.1 cat /dev/acd-debug"); runCommand("AoC DVFS (FF1)", "echo 'dbg info -c 2 DVFSFF1' > /dev/acd-debug; timeout 0.1 cat /dev/acd-debug"); runCommand("AoC Monitor Mode Status", "echo 'monitor_mode status' > /dev/acd-debug; timeout 0.1 cat /dev/acd-debug"); return 0; From 0d885504869cbc7023b46067ac104e0c54d6831a Mon Sep 17 00:00:00 2001 From: samou Date: Tue, 12 Mar 2024 06:17:26 +0000 Subject: [PATCH 2/4] sepolicy: allow the communication between audio and battery_mitigation hal Bug: 330302105 Change-Id: I28a3b67594319d857a8c46bc8c02cddc539caaf8 Signed-off-by: samou --- audio/sepolicy/aidl/hal_audio_default.te | 3 +++ battery_mitigation/sepolicy/vendor/battery_mitigation.te | 2 ++ 2 files changed, 5 insertions(+) diff --git a/audio/sepolicy/aidl/hal_audio_default.te b/audio/sepolicy/aidl/hal_audio_default.te index 2512a17..1ae90c7 100644 --- a/audio/sepolicy/aidl/hal_audio_default.te +++ b/audio/sepolicy/aidl/hal_audio_default.te @@ -1 +1,4 @@ add_service(hal_audio_default, hal_audio_ext_service) +# Allow audio-hal to register battery_mitigation service +allow hal_audio_default hal_battery_mitigation_service:service_manager find; +binder_call(hal_audio_default, battery_mitigation) diff --git a/battery_mitigation/sepolicy/vendor/battery_mitigation.te b/battery_mitigation/sepolicy/vendor/battery_mitigation.te index 7552bd2..3133ab5 100644 --- a/battery_mitigation/sepolicy/vendor/battery_mitigation.te +++ b/battery_mitigation/sepolicy/vendor/battery_mitigation.te @@ -31,3 +31,5 @@ binder_use(battery_mitigation) wakelock_use(battery_mitigation) # Allow battery_mitigation to run aidl service add_service(battery_mitigation, hal_battery_mitigation_service) +# Allow battery_mitigation to run audio mitigation callback +binder_call(battery_mitigation, hal_audio_default) From 78662f83566787beaca9a1b4f2dcf2d269b69bea Mon Sep 17 00:00:00 2001 From: Mitch Phillips Date: Wed, 20 Mar 2024 15:36:14 +0100 Subject: [PATCH 3/4] Revert "Enable MTE workaround for b/324412910" This reverts commit 442f99acafa6a00cd2757f8149ace28f485f89d3. Re-enable MTE in this process now that the underlying issue has been fixed. Bug: 324412910 Test: Boot the device, observe no crashes. Change-Id: I8b9e093f25b33b94e0c9635815d9b0a6e2f91b70 --- mte/fullmte-pixel.mk | 3 --- 1 file changed, 3 deletions(-) diff --git a/mte/fullmte-pixel.mk b/mte/fullmte-pixel.mk index 6cc525d..ac2aba8 100644 --- a/mte/fullmte-pixel.mk +++ b/mte/fullmte-pixel.mk @@ -3,6 +3,3 @@ include build/make/target/product/fullmte.mk PRODUCT_MODULE_BUILD_FROM_SOURCE := true BOARD_KERNEL_CMDLINE += bootloader.pixel.MTE_FORCE_ON -# TODO(b/324412910): Remove this when the stack-buffer-overflow is fixed. -PRODUCT_PRODUCT_PROPERTIES += \ - arm64.memtag.process.android.hardware.composer.hwc3-service.pixel=off \ No newline at end of file From 9357dd1314a7917567fcc6b2a91704de393775ee Mon Sep 17 00:00:00 2001 From: Devika Krishnadas Date: Tue, 19 Mar 2024 01:53:36 +0000 Subject: [PATCH 4/4] Add pixel mapper service context Bug: 267352318 Test: Build & check SELinux denials Change-Id: I763f49d2ef38ae0ab5c1ee1652957f6512f8fbc6 Signed-off-by: Devika Krishnadas --- gpu/sepolicy/service_contexts | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 gpu/sepolicy/service_contexts diff --git a/gpu/sepolicy/service_contexts b/gpu/sepolicy/service_contexts new file mode 100644 index 0000000..88ee08c --- /dev/null +++ b/gpu/sepolicy/service_contexts @@ -0,0 +1,4 @@ +# Note that native/passthrough HALs use the "{type}/{instance}" pattern from +# SEPolicy perspective and are looked up via the corresponding filename +# "{type}.{instance}.so". +mapper/pixel u:object_r:hal_graphics_mapper_service:s0