Merge "pixel3_mainline: Add changes to get pixel3_mainline building a boot.img (v3)"
diff --git a/db845c.mk b/db845c.mk
index 8145405..e91d412 100644
--- a/db845c.mk
+++ b/db845c.mk
@@ -19,5 +19,10 @@
endif
ifeq ($(DB845C_USES_GKI), true)
-BOARD_GENERIC_RAMDISK_KERNEL_MODULES := $(wildcard $(DB845C_KERNEL_DIR)/*.ko)
+ DB845C_MODS := $(wildcard $(DB845C_KERNEL_DIR)/*.ko)
+ ifneq ($(DB845C_MODS),)
+ BOARD_VENDOR_KERNEL_MODULES += $(DB845C_MODS)
+ DB845C_ONLY_VENDOR := %/msm.ko
+ BOARD_VENDOR_RAMDISK_KERNEL_MODULES := $(filter-out $(DB845C_ONLY_VENDOR),$(DB845C_MODS))
+ endif
endif
diff --git a/device-common.mk b/device-common.mk
index 1ebe719..d0f540e 100644
--- a/device-common.mk
+++ b/device-common.mk
@@ -135,6 +135,9 @@
frameworks/av/media/libstagefright/data/media_codecs_google_video.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_video.xml \
frameworks/av/media/libstagefright/data/media_codecs_google_audio.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_audio.xml
+PRODUCT_COPY_FILES += \
+ $(LOCAL_PATH)/seccomp_policy/mediaswcodec.policy:$(TARGET_COPY_OUT_VENDOR)/etc/seccomp_policy/mediaswcodec.policy
+
# Memtrack
PRODUCT_PACKAGES += \
memtrack.default \
diff --git a/seccomp_policy/mediaswcodec.policy b/seccomp_policy/mediaswcodec.policy
new file mode 100644
index 0000000..4c148fb
--- /dev/null
+++ b/seccomp_policy/mediaswcodec.policy
@@ -0,0 +1,3 @@
+# device specific syscalls
+# extension of frameworks/av/services/mediacodec/seccomp_policy/mediaswcodec-arm64.policy
+sysinfo: 1
diff --git a/sepolicy/mediaserver.te b/sepolicy/mediaserver.te
new file mode 100644
index 0000000..922af2c
--- /dev/null
+++ b/sepolicy/mediaserver.te
@@ -0,0 +1 @@
+gpu_access(mediaserver)
diff --git a/sepolicy/mediaswcodec.te b/sepolicy/mediaswcodec.te
new file mode 100644
index 0000000..57fb75c
--- /dev/null
+++ b/sepolicy/mediaswcodec.te
@@ -0,0 +1,2 @@
+gpu_access(mediaswcodec)
+allow mediaswcodec gpu_device:chr_file { getattr ioctl map open read write };