From 2d704464b73914485273b4a185b343abe285c930 Mon Sep 17 00:00:00 2001
From: Alex Klyubin <klyubin@google.com>
Date: Mon, 10 Apr 2017 11:40:53 -0700
Subject: [PATCH] Grant audioserver access to /system/lib64/hw

audioserver uses an always-passthrough Allocator HAL (ashmem / mapper)
whose .so is loaded from /system/lib64/hw.

Test: Modify hal_client_domain macro to not associate client of X HAL
      with hal_x attribute. Play Google Play Movies move -- no denials
      and AV playback works.
Bug: 37160141

Change-Id: I7b88b222aba5361a6c7f0f6bb89705503255a4b1
---
 private/audioserver.te | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/private/audioserver.te b/private/audioserver.te
index 61ccefcd4..b5bfe39a0 100644
--- a/private/audioserver.te
+++ b/private/audioserver.te
@@ -13,6 +13,9 @@ binder_call(audioserver, appdomain)
 binder_service(audioserver)
 
 hal_client_domain(audioserver, hal_allocator)
+# /system/lib64/hw for always-passthrough Allocator HAL ashmem / mapper .so
+r_dir_file(audioserver, system_file)
+
 hal_client_domain(audioserver, hal_audio)
 
 userdebug_or_eng(`
-- 
GitLab