1# 2# Copyright (C) 2020 The Android Open-Source Project 3# 4# Licensed under the Apache License, Version 2.0 (the "License"); 5# you may not use this file except in compliance with the License. 6# You may obtain a copy of the License at 7# 8# http://www.apache.org/licenses/LICENSE-2.0 9# 10# Unless required by applicable law or agreed to in writing, software 11# distributed under the License is distributed on an "AS IS" BASIS, 12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13# See the License for the specific language governing permissions and 14# limitations under the License. 15# 16 17TARGET_USERIMAGES_USE_F2FS := true 18 19# define hardware platform 20PRODUCT_PLATFORM := sdm845 21 22# Enable updating of APEXes 23$(call inherit-product, $(SRC_TARGET_DIR)/product/updatable_apex.mk) 24 25include device/google/crosshatch/device.mk 26 27PRODUCT_PROPERTY_OVERRIDES += \ 28 ro.control_privapp_permissions=disable 29 30PRODUCT_ENFORCE_RRO_TARGETS := framework-res 31 32# Audio fluence, ns, aec property, voice volume steps 33PRODUCT_PROPERTY_OVERRIDES += \ 34 ro.qc.sdk.audio.fluencetype=fluencepro \ 35 persist.audio.fluence.voicecall=true \ 36 persist.audio.fluence.speaker=true \ 37 persist.audio.fluence.voicecomm=true \ 38 persist.audio.fluence.voicerec=false \ 39 ro.config.vc_call_vol_steps=7 40 41# Bug 77867216 42PRODUCT_PROPERTY_OVERRIDES += audio.adm.buffering.ms=3 43PRODUCT_PROPERTY_OVERRIDES += vendor.audio.adm.buffering.ms=3 44PRODUCT_PROPERTY_OVERRIDES += audio_hal.period_multiplier=2 45PRODUCT_PROPERTY_OVERRIDES += af.fast_track_multiplier=1 46 47# Enable HW Codec 2.0 as default service 48# Set all codec components are available with their normal ranks 49# Set OMX components's default rank large than Codec 2.0 HW components's default rank (0x100) 50PRODUCT_PROPERTY_OVERRIDES += debug.stagefright.ccodec=4 51PRODUCT_PROPERTY_OVERRIDES += debug.stagefright.omx_default_rank=512 52 53# Pixelstats broken mic detection 54PRODUCT_PROPERTY_OVERRIDES += vendor.audio.mic_break=true 55 56# Setting vendor SPL 57VENDOR_SECURITY_PATCH = $(PLATFORM_SECURITY_PATCH) 58 59# Set boot SPL 60BOOT_SECURITY_PATCH = $(PLATFORM_SECURITY_PATCH) 61 62# MIDI feature 63PRODUCT_COPY_FILES += \ 64 frameworks/native/data/etc/android.software.midi.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.midi.xml 65 66# Audio low latency feature 67PRODUCT_COPY_FILES += \ 68 frameworks/native/data/etc/android.hardware.audio.low_latency.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.audio.low_latency.xml 69 70# Pro audio feature 71PRODUCT_COPY_FILES += \ 72 frameworks/native/data/etc/android.hardware.audio.pro.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.audio.pro.xml 73 74# Enable AAudio MMAP/NOIRQ data path. 75# 1 is AAUDIO_POLICY_NEVER means only use Legacy path. 76# 2 is AAUDIO_POLICY_AUTO means try MMAP then fallback to Legacy path. 77# 3 is AAUDIO_POLICY_ALWAYS means only use MMAP path. 78PRODUCT_PROPERTY_OVERRIDES += aaudio.mmap_policy=2 79# 1 is AAUDIO_POLICY_NEVER means only use SHARED mode 80# 2 is AAUDIO_POLICY_AUTO means try EXCLUSIVE then fallback to SHARED mode. 81# 3 is AAUDIO_POLICY_ALWAYS means only use EXCLUSIVE mode. 82PRODUCT_PROPERTY_OVERRIDES += aaudio.mmap_exclusive_policy=2 83 84# Increase the apparent size of a hardware burst from 1 msec to 2 msec. 85# A "burst" is the number of frames processed at one time. 86# That is an increase from 48 to 96 frames at 48000 Hz. 87# The DSP will still be bursting at 48 frames but AAudio will think the burst is 96 frames. 88# A low number, like 48, might increase power consumption or stress the system. 89PRODUCT_PROPERTY_OVERRIDES += aaudio.hw_burst_min_usec=2000 90 91# Set lmkd options 92PRODUCT_PRODUCT_PROPERTIES += \ 93 ro.lmk.low=1001 \ 94 ro.lmk.medium=800 \ 95 ro.lmk.critical=0 \ 96 ro.lmk.critical_upgrade=false \ 97 ro.lmk.upgrade_pressure=100 \ 98 ro.lmk.downgrade_pressure=100 \ 99 ro.lmk.kill_heaviest_task=true \ 100 ro.lmk.kill_timeout_ms=100 \ 101 ro.lmk.use_minfree_levels=true \ 102 103# A2DP offload enabled for compilation 104AUDIO_FEATURE_ENABLED_A2DP_OFFLOAD := true 105 106# A2DP offload supported 107PRODUCT_PROPERTY_OVERRIDES += \ 108ro.bluetooth.a2dp_offload.supported=true 109 110# A2DP offload disabled (UI toggle property) 111PRODUCT_PROPERTY_OVERRIDES += \ 112persist.bluetooth.a2dp_offload.disabled=false 113 114# A2DP offload DSP supported encoder list 115PRODUCT_PROPERTY_OVERRIDES += \ 116persist.bluetooth.a2dp_offload.cap=sbc-aac-aptx-aptxhd-ldac 117 118# Modem loging file 119PRODUCT_COPY_FILES += \ 120 device/google/crosshatch/init.logging.rc:$(TARGET_COPY_OUT_VENDOR)/etc/init/hw/init.$(PRODUCT_PLATFORM).logging.rc 121 122# Dumpstate HAL 123PRODUCT_PACKAGES += \ 124 android.hardware.dumpstate@1.0-service.blueline 125 126# Dmabuf dump tool for bug reports 127PRODUCT_PACKAGES += \ 128 dmabuf_dump 129 130# whitelisted app 131PRODUCT_COPY_FILES += \ 132 device/google/crosshatch/qti_whitelist.xml:$(TARGET_COPY_OUT_PRODUCT)/etc/sysconfig/qti_whitelist.xml 133 134PRODUCT_PACKAGES += \ 135 llkd 136#PRODUCT_PROPERTY_OVERRIDES += \ 137# ro.khungtask.enable=false 138# 139 140# Enable retrofit dynamic partitions for all blueline 141# and blueline targets 142PRODUCT_USE_DYNAMIC_PARTITIONS := true 143PRODUCT_RETROFIT_DYNAMIC_PARTITIONS := true 144PRODUCT_PACKAGES += \ 145 android.hardware.boot@1.0-impl.recovery \ 146 bootctrl.sdm845 \ 147 bootctrl.sdm845.recovery \ 148 check_dynamic_partitions \ 149 150AB_OTA_POSTINSTALL_CONFIG += \ 151 RUN_POSTINSTALL_product=true \ 152 POSTINSTALL_PATH_product=bin/check_dynamic_partitions \ 153 FILESYSTEM_TYPE_product=ext4 \ 154 POSTINSTALL_OPTIONAL_product=false \ 155 156# Sepolicy for EVS 157BOARD_SEPOLICY_DIRS += packages/services/Car/evs/sepolicy 158