Merge sm6250-common into miatoll

Change-Id: I870ee30f1c9b8e612ec4acf1e33654ec2f6eb9fd
This commit is contained in:
Alexander Winkowski 2022-11-13 11:42:10 +00:00
commit f6df761250
No known key found for this signature in database
GPG Key ID: 72762A66704CDE44
124 changed files with 20091 additions and 42 deletions

View File

@ -17,4 +17,101 @@ LOCAL_PATH := $(call my-dir)
ifeq ($(TARGET_DEVICE),miatoll)
include $(call all-makefiles-under,$(LOCAL_PATH))
include $(CLEAR_VARS)
FIRMWARE_MOUNT_POINT := $(TARGET_OUT_VENDOR)/firmware_mnt
$(FIRMWARE_MOUNT_POINT): $(LOCAL_INSTALLED_MODULE)
@echo "Creating $(FIRMWARE_MOUNT_POINT)"
@mkdir -p $(TARGET_OUT_VENDOR)/firmware_mnt
BT_FIRMWARE_MOUNT_POINT := $(TARGET_OUT_VENDOR)/bt_firmware
$(BT_FIRMWARE_MOUNT_POINT): $(LOCAL_INSTALLED_MODULE)
@echo "Creating $(BT_FIRMWARE_MOUNT_POINT)"
@mkdir -p $(TARGET_OUT_VENDOR)/bt_firmware
DSP_MOUNT_POINT := $(TARGET_OUT_VENDOR)/dsp
$(DSP_MOUNT_POINT): $(LOCAL_INSTALLED_MODULE)
@echo "Creating $(DSP_MOUNT_POINT)"
@mkdir -p $(TARGET_OUT_VENDOR)/dsp
ALL_DEFAULT_INSTALLED_MODULES += $(FIRMWARE_MOUNT_POINT) $(BT_FIRMWARE_MOUNT_POINT) $(DSP_MOUNT_POINT)
RFS_MSM_ADSP_SYMLINKS := $(TARGET_OUT_VENDOR)/rfs/msm/adsp/
$(RFS_MSM_ADSP_SYMLINKS): $(LOCAL_INSTALLED_MODULE)
@echo "Creating RFS MSM ADSP folder structure: $@"
@rm -rf $@/*
@mkdir -p $(dir $@)/readonly/vendor
$(hide) ln -sf /data/vendor/tombstones/rfs/lpass $@/ramdumps
$(hide) ln -sf /mnt/vendor/persist/rfs/msm/adsp $@/readwrite
$(hide) ln -sf /mnt/vendor/persist/rfs/shared $@/shared
$(hide) ln -sf /mnt/vendor/persist/hlos_rfs/shared $@/hlos
$(hide) ln -sf /vendor/firmware_mnt $@/readonly/firmware
$(hide) ln -sf /vendor/firmware $@/readonly/vendor/firmware
RFS_MSM_CDSP_SYMLINKS := $(TARGET_OUT_VENDOR)/rfs/msm/cdsp/
$(RFS_MSM_CDSP_SYMLINKS): $(LOCAL_INSTALLED_MODULE)
@echo "Creating RFS MSM CDSP folder structure: $@"
@rm -rf $@/*
@mkdir -p $(dir $@)/readonly/vendor
$(hide) ln -sf /data/vendor/tombstones/rfs/cdsp $@/ramdumps
$(hide) ln -sf /mnt/vendor/persist/rfs/msm/cdsp $@/readwrite
$(hide) ln -sf /mnt/vendor/persist/rfs/shared $@/shared
$(hide) ln -sf /mnt/vendor/persist/hlos_rfs/shared $@/hlos
$(hide) ln -sf /vendor/firmware_mnt $@/readonly/firmware
$(hide) ln -sf /vendor/firmware $@/readonly/vendor/firmware
RFS_MSM_MPSS_SYMLINKS := $(TARGET_OUT_VENDOR)/rfs/msm/mpss/
$(RFS_MSM_MPSS_SYMLINKS): $(LOCAL_INSTALLED_MODULE)
@echo "Creating RFS MSM MPSS folder structure: $@"
@rm -rf $@/*
@mkdir -p $(dir $@)/readonly/vendor
$(hide) ln -sf /data/vendor/tombstones/rfs/modem $@/ramdumps
$(hide) ln -sf /mnt/vendor/persist/rfs/msm/mpss $@/readwrite
$(hide) ln -sf /mnt/vendor/persist/rfs/shared $@/shared
$(hide) ln -sf /mnt/vendor/persist/hlos_rfs/shared $@/hlos
$(hide) ln -sf /vendor/firmware_mnt $@/readonly/firmware
$(hide) ln -sf /vendor/firmware $@/readonly/vendor/firmware
RFS_MSM_SLPI_SYMLINKS := $(TARGET_OUT_VENDOR)/rfs/msm/slpi/
$(RFS_MSM_SLPI_SYMLINKS): $(LOCAL_INSTALLED_MODULE)
@echo "Creating RFS MSM SLPI folder structure: $@"
@rm -rf $@/*
@mkdir -p $(dir $@)/readonly/vendor
$(hide) ln -sf /data/vendor/tombstones/rfs/slpi $@/ramdumps
$(hide) ln -sf /mnt/vendor/persist/rfs/msm/slpi $@/readwrite
$(hide) ln -sf /mnt/vendor/persist/rfs/shared $@/shared
$(hide) ln -sf /mnt/vendor/persist/hlos_rfs/shared $@/hlos
$(hide) ln -sf /vendor/firmware_mnt $@/readonly/firmware
$(hide) ln -sf /vendor/firmware $@/readonly/vendor/firmware
WIFI_FIRMWARE_SYMLINKS := $(TARGET_OUT_VENDOR)/firmware/wlan/qca_cld/
$(WIFI_FIRMWARE_SYMLINKS): $(LOCAL_INSTALLED_MODULE)
@echo "Creating wifi firmware symlinks: $@"
mkdir -p $@
$(hide) ln -sf /vendor/etc/wifi/WCNSS_qcom_cfg.ini $@/WCNSS_qcom_cfg.ini
ALL_DEFAULT_INSTALLED_MODULES += $(RFS_MSM_ADSP_SYMLINKS) $(RFS_MSM_CDSP_SYMLINKS) $(RFS_MSM_MPSS_SYMLINKS) $(RFS_MSM_SLPI_SYMLINKS)
ALL_DEFAULT_INSTALLED_MODULES += $(WIFI_FIRMWARE_SYMLINKS)
# Symlinks
EGL_LIBRARIES := \
libEGL_adreno.so \
libGLESv2_adreno.so \
libq3dtools_adreno.so
EGL_32_SYMLINKS := $(addprefix $(TARGET_OUT_VENDOR)/lib/,$(notdir $(EGL_LIBRARIES)))
$(EGL_32_SYMLINKS): $(LOCAL_INSTALLED_MODULE)
@echo "EGL 32 lib link: $@"
@mkdir -p $(dir $@)
@rm -rf $@
$(hide) ln -sf egl/$(notdir $@) $@
EGL_64_SYMLINKS := $(addprefix $(TARGET_OUT_VENDOR)/lib64/,$(notdir $(EGL_LIBRARIES)))
$(EGL_64_SYMLINKS): $(LOCAL_INSTALLED_MODULE)
@echo "EGL lib link: $@"
@mkdir -p $(dir $@)
@rm -rf $@
$(hide) ln -sf egl/$(notdir $@) $@
endif

View File

@ -4,15 +4,77 @@
# SPDX-License-Identifier: Apache-2.0
#
# Inherit from sm6250-common
include device/xiaomi/sm6250-common/BoardConfigCommon.mk
DEVICE_PATH := device/xiaomi/miatoll
# HIDL
ODM_MANIFEST_SKUS += \
nfc
BUILD_BROKEN_DUP_RULES := true
BUILD_BROKEN_ELF_PREBUILT_PRODUCT_COPY_FILES := true
# Architecture
TARGET_ARCH := arm64
TARGET_ARCH_VARIANT := armv8-2a
TARGET_CPU_ABI := arm64-v8a
TARGET_CPU_ABI2 :=
TARGET_CPU_VARIANT := cortex-a76
TARGET_2ND_ARCH := arm
TARGET_2ND_ARCH_VARIANT := armv8-a
TARGET_2ND_CPU_ABI := armeabi-v7a
TARGET_2ND_CPU_ABI2 := armeabi
TARGET_2ND_CPU_VARIANT := cortex-a76
# Audio
AUDIO_FEATURE_ENABLED_AHAL_EXT := false
AUDIO_FEATURE_ENABLED_DLKM := true
AUDIO_FEATURE_ENABLED_DS2_DOLBY_DAP := false
AUDIO_FEATURE_ENABLED_DTS_EAGLE := false
AUDIO_FEATURE_ENABLED_DYNAMIC_LOG := false
AUDIO_FEATURE_ENABLED_EXTENDED_COMPRESS_FORMAT := true
AUDIO_FEATURE_ENABLED_GEF_SUPPORT := true
AUDIO_FEATURE_ENABLED_HW_ACCELERATED_EFFECTS := false
AUDIO_FEATURE_ENABLED_INSTANCE_ID := true
AUDIO_FEATURE_ENABLED_PROXY_DEVICE := true
AUDIO_FEATURE_ENABLED_SSR := true
AUDIO_FEATURE_ENABLED_SVA_MULTI_STAGE := true
BOARD_SUPPORTS_OPENSOURCE_STHAL := true
BOARD_SUPPORTS_SOUND_TRIGGER := true
BOARD_USES_ALSA_AUDIO := true
USE_CUSTOM_AUDIO_POLICY := 1
# Bluetooth
BOARD_BLUETOOTH_BDROID_BUILDCFG_INCLUDE_DIR := $(DEVICE_PATH)/bluetooth/include
# Bootloader
TARGET_BOOTLOADER_BOARD_NAME := atoll
TARGET_NO_BOOTLOADER := true
# Camera
TARGET_DISABLED_UBWC := true
# Display
TARGET_SCREEN_DENSITY := 440
TARGET_USES_COLOR_METADATA := true
TARGET_USES_DISPLAY_RENDER_INTENTS := true
TARGET_USES_DRM_PP := true
TARGET_USES_GRALLOC1 := true
TARGET_USES_GRALLOC4 := true
TARGET_USES_HWC2 := true
TARGET_USES_ION := true
# Filesystem
TARGET_FS_CONFIG_GEN := $(DEVICE_PATH)/config.fs
# FM
BOARD_HAVE_QCOM_FM := true
# HIDL
DEVICE_FRAMEWORK_COMPATIBILITY_MATRIX_FILE := \
hardware/qcom-caf/common/vendor_framework_compatibility_matrix.xml \
$(DEVICE_PATH)/device_framework_matrix.xml \
$(DEVICE_PATH)/lineage_device_framework_matrix.xml
DEVICE_MATRIX_FILE := $(DEVICE_PATH)/compatibility_matrix.xml
DEVICE_MANIFEST_FILE := $(DEVICE_PATH)/manifest.xml
ODM_MANIFEST_SKUS += nfc
ODM_MANIFEST_NFC_FILES := $(DEVICE_PATH)/manifest_nfc.xml
# Init
@ -20,10 +82,134 @@ TARGET_INIT_VENDOR_LIB := //$(DEVICE_PATH):init_xiaomi_miatoll
TARGET_RECOVERY_DEVICE_MODULES := init_xiaomi_miatoll
# Kernel
BOARD_KERNEL_BASE := 0x00000000
BOARD_KERNEL_IMAGE_NAME := Image
BOARD_KERNEL_PAGESIZE := 4096
BOARD_KERNEL_SEPARATED_DTBO := true
BOARD_BOOT_HEADER_VERSION := 2
BOARD_MKBOOTIMG_ARGS += --header_version $(BOARD_BOOT_HEADER_VERSION)
BOARD_INCLUDE_DTB_IN_BOOTIMG := true
TARGET_KERNEL_ADDITIONAL_FLAGS += LD=ld.lld AR=llvm-ar NM=llvm-nm STRIP=llvm-strip OBJCOPY=llvm-objcopy OBJDUMP=llvm-objdump
TARGET_KERNEL_CONFIG := vendor/xiaomi/miatoll_defconfig
TARGET_KERNEL_SOURCE := kernel/xiaomi/sm6250
BOARD_KERNEL_CMDLINE := androidboot.console=ttyMSM0
BOARD_KERNEL_CMDLINE += androidboot.hardware=qcom
BOARD_KERNEL_CMDLINE += androidboot.memcg=1
BOARD_KERNEL_CMDLINE += androidboot.usbcontroller=a600000.dwc3
BOARD_KERNEL_CMDLINE += cgroup.memory=nokmem,nosocket
BOARD_KERNEL_CMDLINE += console=ttyMSM0,115200n8
BOARD_KERNEL_CMDLINE += earlycon=msm_geni_serial,0xa88000
BOARD_KERNEL_CMDLINE += loop.max_part=7
BOARD_KERNEL_CMDLINE += lpm_levels.sleep_disabled=1
BOARD_KERNEL_CMDLINE += msm_rtb.enabled=1
BOARD_KERNEL_CMDLINE += msm_rtb.filter=0x237
BOARD_KERNEL_CMDLINE += service_locator.enable=1
BOARD_KERNEL_CMDLINE += swiotlb=1
BOARD_KERNEL_CMDLINE += video=vfb:640x400,bpp=32,memsize=3072000
# OTA assert
TARGET_OTA_ASSERT_DEVICE := curtana,excalibur,gram,joyeuse,miatoll
# Partitions
BOARD_BOOTIMAGE_PARTITION_SIZE := 134217728
BOARD_CACHEIMAGE_PARTITION_SIZE := 402653184
BOARD_DTBOIMG_PARTITION_SIZE := 8388608
BOARD_RECOVERYIMAGE_PARTITION_SIZE := 134217728
BOARD_SUPER_PARTITION_SIZE := 8589934592
BOARD_USERDATAIMAGE_PARTITION_SIZE := 112421842944
BOARD_SUPER_PARTITION_GROUPS := qti_dynamic_partitions
BOARD_QTI_DYNAMIC_PARTITIONS_PARTITION_LIST := system system_ext vendor product
BOARD_QTI_DYNAMIC_PARTITIONS_SIZE := 8585740288
BOARD_CACHEIMAGE_FILE_SYSTEM_TYPE := ext4
BOARD_PRODUCTIMAGE_FILE_SYSTEM_TYPE := ext4
BOARD_SYSTEM_EXTIMAGE_FILE_SYSTEM_TYPE := ext4
BOARD_SYSTEMIMAGE_FILE_SYSTEM_TYPE := ext4
BOARD_USERDATAIMAGE_FILE_SYSTEM_TYPE := f2fs
BOARD_VENDORIMAGE_FILE_SYSTEM_TYPE := ext4
BOARD_PRODUCTIMAGE_EXTFS_INODE_COUNT := -1
BOARD_PRODUCTIMAGE_PARTITION_RESERVED_SIZE := 1887436800
BOARD_SYSTEMIMAGE_EXTFS_INODE_COUNT := -1
BOARD_SYSTEMIMAGE_PARTITION_RESERVED_SIZE := 1887436800
BOARD_SYSTEM_EXTIMAGE_EXTFS_INODE_COUNT := -1
BOARD_SYSTEM_EXTIMAGE_PARTITION_RESERVED_SIZE := 104857600
BOARD_VENDORIMAGE_PARTITION_RESERVED_SIZE := 104857600
TARGET_COPY_OUT_SYSTEM_EXT := system_ext
TARGET_COPY_OUT_VENDOR := vendor
TARGET_COPY_OUT_PRODUCT := product
BOARD_USES_METADATA_PARTITION := true
BOARD_FLASH_BLOCK_SIZE := 131072
# Platform
BOARD_USES_QCOM_HARDWARE := true
BOARD_VENDOR := xiaomi
TARGET_BOARD_PLATFORM := atoll
# Power
TARGET_TAP_TO_WAKE_NODE := "/sys/touchpanel/double_tap"
# Properties
TARGET_ODM_PROP += $(DEVICE_PATH)/odm.prop
TARGET_SYSTEM_PROP += $(DEVICE_PATH)/system.prop
TARGET_VENDOR_PROP += $(DEVICE_PATH)/vendor.prop
# Recovery
BOARD_INCLUDE_RECOVERY_DTBO := true
TARGET_RECOVERY_FSTAB := $(DEVICE_PATH)/rootdir/etc/fstab.qcom
TARGET_RECOVERY_PIXEL_FORMAT := "RGBX_8888"
TARGET_USERIMAGES_USE_EXT4 := true
TARGET_USERIMAGES_USE_F2FS := true
# Releasetools
TARGET_RELEASETOOLS_EXTENSIONS := $(DEVICE_PATH)
# RIL
ENABLE_VENDOR_RIL_SERVICE := true
# Security patch level
VENDOR_SECURITY_PATCH := 2022-06-05
# Sepolicy
include device/qcom/sepolicy_vndr/SEPolicy.mk
SYSTEM_EXT_PRIVATE_SEPOLICY_DIRS += $(DEVICE_PATH)/sepolicy/private
BOARD_SEPOLICY_DIRS += $(DEVICE_PATH)/sepolicy/vendor
# Verified Boot
BOARD_AVB_ENABLE := true
BOARD_AVB_MAKE_VBMETA_IMAGE_ARGS += --flags 3
BOARD_AVB_RECOVERY_KEY_PATH := external/avb/test/data/testkey_rsa4096.pem
BOARD_AVB_RECOVERY_ALGORITHM := SHA256_RSA4096
BOARD_AVB_RECOVERY_ROLLBACK_INDEX := $(PLATFORM_SECURITY_PATCH_TIMESTAMP)
BOARD_AVB_RECOVERY_ROLLBACK_INDEX_LOCATION := 1
BOARD_AVB_VBMETA_SYSTEM := system system_ext product
BOARD_AVB_VBMETA_SYSTEM_KEY_PATH := external/avb/test/data/testkey_rsa4096.pem
BOARD_AVB_VBMETA_SYSTEM_ALGORITHM := SHA256_RSA4096
BOARD_AVB_VBMETA_SYSTEM_ROLLBACK_INDEX := $(PLATFORM_SECURITY_PATCH_TIMESTAMP)
BOARD_AVB_VBMETA_SYSTEM_ROLLBACK_INDEX_LOCATION := 1
# WiFi
BOARD_WLAN_DEVICE := qcwcn
BOARD_HOSTAPD_DRIVER := NL80211
BOARD_HOSTAPD_PRIVATE_LIB := lib_driver_cmd_$(BOARD_WLAN_DEVICE)
BOARD_WPA_SUPPLICANT_DRIVER := NL80211
BOARD_WPA_SUPPLICANT_PRIVATE_LIB := lib_driver_cmd_$(BOARD_WLAN_DEVICE)
QC_WIFI_HIDL_FEATURE_DUAL_AP := true
WIFI_DRIVER_DEFAULT := qca_cld3
WIFI_DRIVER_STATE_CTRL_PARAM := "/dev/wlan"
WIFI_DRIVER_STATE_OFF := "OFF"
WIFI_DRIVER_STATE_ON := "ON"
WIFI_HIDL_FEATURE_AWARE := true
WIFI_HIDL_FEATURE_DUAL_INTERFACE := true
WIFI_HIDL_UNIFIED_SUPPLICANT_SERVICE_RC_ENTRY := true
WPA_SUPPLICANT_VERSION := VER_0_8_X
# Inherit proprietary blobs
include vendor/xiaomi/miatoll/BoardConfigVendor.mk

116
audio/audio_effects.xml Normal file
View File

@ -0,0 +1,116 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--- Copyright (c) 2018-2019, The Linux Foundation. All rights reserved. -->
<!--- -->
<!--- Redistribution and use in source and binary forms, with or without -->
<!--- modification, are permitted provided that the following conditions are -->
<!--- met: -->
<!--- * Redistributions of source code must retain the above copyright -->
<!--- notice, this list of conditions and the following disclaimer. -->
<!--- * Redistributions in binary form must reproduce the above -->
<!--- copyright notice, this list of conditions and the following -->
<!--- disclaimer in the documentation and/or other materials provided -->
<!--- with the distribution. -->
<!--- * Neither the name of The Linux Foundation nor the names of its -->
<!--- contributors may be used to endorse or promote products derived -->
<!--- from this software without specific prior written permission. -->
<!--- -->
<!--- THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED -->
<!--- WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -->
<!--- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT -->
<!--- ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS -->
<!--- BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -->
<!--- CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF -->
<!--- SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR -->
<!--- BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -->
<!--- WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE -->
<!--- OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN -->
<!--- IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -->
<audio_effects_conf version="2.0" xmlns="http://schemas.android.com/audio/audio_effects_conf/v2_0">
<libraries>
<library name="bundle" path="libbundlewrapper.so"/>
<library name="reverb" path="libreverbwrapper.so"/>
<library name="visualizer_sw" path="libvisualizer.so"/>
<library name="visualizer_hw" path="libqcomvisualizer.so"/>
<library name="downmix" path="libdownmix.so"/>
<library name="loudness_enhancer" path="libldnhncr.so"/>
<library name="dynamics_processing" path="libdynproc.so"/>
<library name="proxy" path="libeffectproxy.so"/>
<library name="offload_bundle" path="libqcompostprocbundle.so"/>
<library name="audio_pre_processing" path="libqcomvoiceprocessing.so"/>
<library name="volume_listener" path="libvolumelistener.so"/>
<library name="audiosphere" path="libasphere.so"/>
<library name="shoebox" path="libshoebox.so"/>
</libraries>
<effects>
<effectProxy name="bassboost" library="proxy" uuid="14804144-a5ee-4d24-aa88-0002a5d5c51b">
<libsw library="bundle" uuid="8631f300-72e2-11df-b57e-0002a5d5c51b"/>
<libhw library="offload_bundle" uuid="2c4a8c24-1581-487f-94f6-0002a5d5c51b"/>
</effectProxy>
<effectProxy name="virtualizer" library="proxy" uuid="d3467faa-acc7-4d34-acaf-0002a5d5c51b">
<libsw library="bundle" uuid="1d4033c0-8557-11df-9f2d-0002a5d5c51b"/>
<libhw library="offload_bundle" uuid="509a4498-561a-4bea-b3b1-0002a5d5c51b"/>
</effectProxy>
<effectProxy name="equalizer" library="proxy" uuid="c8e70ecd-48ca-456e-8a4f-0002a5d5c51b">
<libsw library="bundle" uuid="ce772f20-847d-11df-bb17-0002a5d5c51b"/>
<libhw library="offload_bundle" uuid="a0dac280-401c-11e3-9379-0002a5d5c51b"/>
</effectProxy>
<effect name="volume" library="bundle" uuid="119341a0-8469-11df-81f9-0002a5d5c51b"/>
<effectProxy name="reverb_env_aux" library="proxy" uuid="48404ac9-d202-4ccc-bf84-0002a5d5c51b">
<libsw library="reverb" uuid="4a387fc0-8ab3-11df-8bad-0002a5d5c51b"/>
<libhw library="offload_bundle" uuid="79a18026-18fd-4185-8233-0002a5d5c51b"/>
</effectProxy>
<effectProxy name="reverb_env_ins" library="proxy" uuid="b707403a-a1c1-4291-9573-0002a5d5c51b">
<libsw library="reverb" uuid="c7a511a0-a3bb-11df-860e-0002a5d5c51b"/>
<libhw library="offload_bundle" uuid="eb64ea04-973b-43d2-8f5e-0002a5d5c51b"/>
</effectProxy>
<effectProxy name="reverb_pre_aux" library="proxy" uuid="1b78f587-6d1c-422e-8b84-0002a5d5c51b">
<libsw library="reverb" uuid="f29a1400-a3bb-11df-8ddc-0002a5d5c51b"/>
<libhw library="offload_bundle" uuid="6987be09-b142-4b41-9056-0002a5d5c51b"/>
</effectProxy>
<effectProxy name="reverb_pre_ins" library="proxy" uuid="f3e178d2-ebcb-408e-8357-0002a5d5c51b">
<libsw library="reverb" uuid="172cdf00-a3bc-11df-a72f-0002a5d5c51b"/>
<libhw library="offload_bundle" uuid="aa2bebf6-47cf-4613-9bca-0002a5d5c51b"/>
</effectProxy>
<effectProxy name="visualizer" library="proxy" uuid="1d0a1a53-7d5d-48f2-8e71-27fbd10d842c">
<libsw library="visualizer_sw" uuid="d069d9e0-8329-11df-9168-0002a5d5c51b"/>
<libhw library="visualizer_hw" uuid="7a8044a0-1a71-11e3-a184-0002a5d5c51b"/>
</effectProxy>
<effect name="downmix" library="downmix" uuid="93f04452-e4fe-41cc-91f9-e475b6d1d69f"/>
<effect name="hw_acc" library="offload_bundle" uuid="7d1580bd-297f-4683-9239-e475b6d1d69f"/>
<effect name="loudness_enhancer" library="loudness_enhancer" uuid="fa415329-2034-4bea-b5dc-5b381c8d1e2c"/>
<effect name="dynamics_processing" library="dynamics_processing" uuid="e0e6539b-1781-7261-676f-6d7573696340"/>
<effect name="aec" library="audio_pre_processing" uuid="0f8d0d2a-59e5-45fe-b6e4-248c8a799109"/>
<effect name="ns" library="audio_pre_processing" uuid="1d97bb0b-9e2f-4403-9ae3-58c2554306f8"/>
<effect name="music_helper" library="volume_listener" uuid="08b8b058-0590-11e5-ac71-0025b32654a0"/>
<effect name="ring_helper" library="volume_listener" uuid="0956df94-0590-11e5-bdbe-0025b32654a0"/>
<effect name="alarm_helper" library="volume_listener" uuid="09f303e2-0590-11e5-8fdb-0025b32654a0"/>
<effect name="voice_helper" library="volume_listener" uuid="0ace5c08-0590-11e5-ae9e-0025b32654a0"/>
<effect name="notification_helper" library="volume_listener" uuid="0b776dde-0590-11e5-81ba-0025b32654a0"/>
<effect name="audiosphere" library="audiosphere" uuid="184e62ab-2d19-4364-9d1b-c0a40733866c"/>
<effect name="shoebox" library="shoebox" uuid="1eab784c-1a36-4b2a-b7fc-e34c44cab89e"/>
</effects>
<postprocess>
<stream type="music">
<apply effect="music_helper"/>
</stream>
<stream type="ring">
<apply effect="ring_helper"/>
</stream>
<stream type="alarm">
<apply effect="alarm_helper"/>
</stream>
<stream type="voice_call">
<apply effect="voice_helper"/>
</stream>
<stream type="notification">
<apply effect="notification_helper"/>
</stream>
</postprocess>
<preprocess>
<stream type="voice_communication">
<apply effect="aec"/>
<apply effect="ns"/>
</stream>
</preprocess>
</audio_effects_conf>

126
audio/audio_io_policy.conf Normal file
View File

@ -0,0 +1,126 @@
# List of profiles for the output device session where stream is routed.
# A stream opened with the inputs attributes which match the "flags" and
# "formats" as specified in the profile is routed to a device at
# sample rate specified under "sampling_rates" and bit width under
# "bit_width" and the topology extracted from the acdb data against
# the "app_type".
#
# the flags and formats are specified using the strings corresponding to
# enums in audio.h and audio_policy.h. They are concatenated with "|"
# without space or "\n".
# the flags and formats should match the ones in "audio_policy.conf"
outputs {
default {
flags AUDIO_OUTPUT_FLAG_PRIMARY
formats AUDIO_FORMAT_PCM_16_BIT
sampling_rates 48000
bit_width 16
app_type 69937
}
proaudio {
flags AUDIO_OUTPUT_FLAG_FAST|AUDIO_OUTPUT_FLAG_RAW
formats AUDIO_FORMAT_PCM_16_BIT
sampling_rates 48000
bit_width 16
app_type 69943
}
voip_rx {
flags AUDIO_OUTPUT_FLAG_VOIP_RX|AUDIO_OUTPUT_FLAG_DIRECT
formats AUDIO_FORMAT_PCM_16_BIT
sampling_rates 8000|16000|32000|48000
bit_width 16
app_type 69946
}
deep_buffer {
flags AUDIO_OUTPUT_FLAG_DEEP_BUFFER
formats AUDIO_FORMAT_PCM_16_BIT
sampling_rates 48000
bit_width 16
app_type 69936
}
direct_pcm_16 {
flags AUDIO_OUTPUT_FLAG_DIRECT
formats AUDIO_FORMAT_PCM_16_BIT|AUDIO_FORMAT_PCM_24_BIT_PACKED|AUDIO_FORMAT_PCM_8_24_BIT|AUDIO_FORMAT_PCM_32_BIT
sampling_rates 44100|48000|88200|96000|176400|192000
bit_width 16
app_type 69936
}
direct_pcm_24 {
flags AUDIO_OUTPUT_FLAG_DIRECT
formats AUDIO_FORMAT_PCM_24_BIT_PACKED|AUDIO_FORMAT_PCM_8_24_BIT|AUDIO_FORMAT_PCM_32_BIT
sampling_rates 44100|48000|88200|96000|176400|192000|352800|384000
bit_width 24
app_type 69940
}
direct_pcm_32 {
flags AUDIO_OUTPUT_FLAG_DIRECT
formats AUDIO_FORMAT_PCM_32_BIT
sampling_rates 44100|48000|88200|96000|176400|192000|352800|384000
bit_width 32
app_type 69942
}
compress_passthrough {
flags AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD|AUDIO_OUTPUT_FLAG_NON_BLOCKING|AUDIO_OUTPUT_FLAG_COMPRESS_PASSTHROUGH
formats AUDIO_FORMAT_DTS|AUDIO_FORMAT_DTS_HD|AUDIO_FORMAT_DSD
sampling_rates 32000|44100|48000|88200|96000|176400|192000|352800
bit_width 16
app_type 69941
}
compress_offload_16 {
flags AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD|AUDIO_OUTPUT_FLAG_NON_BLOCKING
formats AUDIO_FORMAT_MP3|AUDIO_FORMAT_PCM_16_BIT_OFFLOAD|AUDIO_FORMAT_PCM_24_BIT_OFFLOAD|AUDIO_FORMAT_FLAC|AUDIO_FORMAT_ALAC|AUDIO_FORMAT_APE|AUDIO_FORMAT_AAC_LC|AUDIO_FORMAT_AAC_HE_V1|AUDIO_FORMAT_AAC_HE_V2|AUDIO_FORMAT_WMA|AUDIO_FORMAT_WMA_PRO|AUDIO_FORMAT_VORBIS|AUDIO_FORMAT_AAC_ADTS_LC|AUDIO_FORMAT_AAC_ADTS_HE_V1|AUDIO_FORMAT_AAC_ADTS_HE_V2
sampling_rates 44100|48000|88200|96000|176400|192000
bit_width 16
app_type 69936
}
compress_offload_24 {
flags AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD|AUDIO_OUTPUT_FLAG_NON_BLOCKING
formats AUDIO_FORMAT_PCM_24_BIT_OFFLOAD|AUDIO_FORMAT_FLAC|AUDIO_FORMAT_ALAC|AUDIO_FORMAT_APE|AUDIO_FORMAT_VORBIS|AUDIO_FORMAT_WMA|AUDIO_FORMAT_WMA_PRO
sampling_rates 44100|48000|88200|96000|176400|192000
bit_width 24
app_type 69940
}
}
inputs {
record_16bit {
formats AUDIO_FORMAT_PCM_16_BIT
sampling_rates 8000|16000|32000|44100|48000|88200|96000|176400|192000
bit_width 16
app_type 69938
}
record_24bit {
formats AUDIO_FORMAT_PCM_24_BIT_PACKED|AUDIO_FORMAT_PCM_24_BIT
sampling_rates 44100|48000|88200|96000|176400|192000
bit_width 24
app_type 69948
}
record_32bit {
formats AUDIO_FORMAT_PCM_32_BIT|AUDIO_FORMAT_PCM_FLOAT
sampling_rates 44100|48000|88200|96000|176400|192000
bit_width 32
app_type 69949
}
record_compress_16 {
flags AUDIO_INPUT_FLAG_COMPRESS
formats AUDIO_FORMAT_PCM_16_BIT
sampling_rates 8000|16000|32000|44100|48000|88200|96000|176400|192000
bit_width 16
app_type 69938
}
record_compress_24 {
flags AUDIO_INPUT_FLAG_COMPRESS
formats AUDIO_FORMAT_PCM_24_BIT_PACKED|AUDIO_FORMAT_PCM_24_BIT
sampling_rates 44100|48000|88200|96000|176400|192000
bit_width 24
app_type 69948
}
record_compress_32 {
flags AUDIO_INPUT_FLAG_COMPRESS
formats AUDIO_FORMAT_PCM_32_BIT|AUDIO_FORMAT_PCM_FLOAT
sampling_rates 44100|48000|88200|96000|176400|192000
bit_width 32
app_type 69949
}
}

View File

@ -0,0 +1,407 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!-- Copyright (c) 2014, 2016-2020, The Linux Foundation. All rights reserved. -->
<!-- -->
<!-- Redistribution and use in source and binary forms, with or without -->
<!-- modification, are permitted provided that the following conditions are -->
<!-- met: -->
<!-- * Redistributions of source code must retain the above copyright -->
<!-- notice, this list of conditions and the following disclaimer. -->
<!-- * Redistributions in binary form must reproduce the above -->
<!-- copyright notice, this list of conditions and the following -->
<!-- disclaimer in the documentation and/or other materials provided -->
<!-- with the distribution. -->
<!-- * Neither the name of The Linux Foundation nor the names of its -->
<!-- contributors may be used to endorse or promote products derived -->
<!-- from this software without specific prior written permission. -->
<!-- -->
<!-- THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED -->
<!-- WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -->
<!-- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT -->
<!-- ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS -->
<!-- BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -->
<!-- CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF -->
<!-- SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR -->
<!-- BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -->
<!-- OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN -->
<!-- IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -->
<audio_platform_info>
<bit_width_configs>
<device name="SND_DEVICE_OUT_SPEAKER" bit_width="24"/>
</bit_width_configs>
<interface_names>
<device name="AUDIO_DEVICE_IN_BUILTIN_MIC" interface="TX_CDC_DMA_TX_3" codec_type="internal"/>
<device name="AUDIO_DEVICE_IN_BACK_MIC" interface="TX_CDC_DMA_TX_3" codec_type="internal"/>
</interface_names>
<pcm_ids>
<usecase name="USECASE_AUDIO_PLAYBACK_LOW_LATENCY" type="out" id="9"/>
<usecase name="USECASE_AUDIO_PLAYBACK_OFFLOAD" type="out" id="7"/>
<usecase name="USECASE_AUDIO_PLAYBACK_OFFLOAD2" type="out" id="11"/>
<usecase name="USECASE_AUDIO_PLAYBACK_OFFLOAD3" type="out" id="12"/>
<usecase name="USECASE_AUDIO_PLAYBACK_OFFLOAD4" type="out" id="24"/>
<usecase name="USECASE_AUDIO_PLAYBACK_OFFLOAD5" type="out" id="25"/>
<usecase name="USECASE_AUDIO_PLAYBACK_OFFLOAD6" type="out" id="26"/>
<usecase name="USECASE_AUDIO_PLAYBACK_OFFLOAD7" type="out" id="27"/>
<usecase name="USECASE_AUDIO_PLAYBACK_OFFLOAD8" type="out" id="28"/>
<usecase name="USECASE_VOICEMMODE1_CALL" type="in" id="2"/>
<usecase name="USECASE_VOICEMMODE1_CALL" type="out" id="2"/>
<usecase name="USECASE_VOICEMMODE2_CALL" type="in" id="15"/>
<usecase name="USECASE_VOICEMMODE2_CALL" type="out" id="15"/>
<usecase name="USECASE_VOWLAN_CALL" type="in" id="-1"/>
<usecase name="USECASE_VOWLAN_CALL" type="out" id="-1"/>
<usecase name="USECASE_AUDIO_PLAYBACK_FM" type="out" id="30"/>
<usecase name="USECASE_AUDIO_PLAYBACK_FM" type="in" id="38"/>
<usecase name="USECASE_AUDIO_SPKR_CALIB_RX" type="out" id="30"/>
<usecase name="USECASE_AUDIO_SPKR_CALIB_TX" type="in" id="33"/>
<usecase name="USECASE_AUDIO_PLAYBACK_AFE_PROXY" type="out" id="5"/>
<usecase name="USECASE_AUDIO_RECORD_AFE_PROXY" type="in" id="6"/>
<usecase name="USECASE_AUDIO_RECORD_LOW_LATENCY" type="in" id="13" />
<usecase name="USECASE_AUDIO_PLAYBACK_ULL" type="out" id="13" />
<usecase name="USECASE_AUDIO_PLAYBACK_SILENCE" type="out" id="23" />
<usecase name="USECASE_AUDIO_PLAYBACK_VOIP" type="out" id="12" />
<usecase name="USECASE_AUDIO_RECORD_VOIP" type="in" id="12" />
<usecase name="USECASE_AUDIO_HFP_SCO" type="in" id="12" />
<usecase name="USECASE_AUDIO_HFP_SCO_WB" type="in" id="12" />
<usecase name="USECASE_AUDIO_PLAYBACK_MMAP" type="out" id="29" />
<usecase name="USECASE_AUDIO_RECORD_MMAP" type="in" id="29" />
<usecase name="USECASE_AUDIO_A2DP_ABR_FEEDBACK" type="in" id="36" />
<usecase name="USECASE_AUDIO_A2DP_ABR_FEEDBACK" type="out" id="36" />
<usecase name="USECASE_INCALL_MUSIC_UPLINK" type="out" id="23" />
<usecase name="USECASE_INCALL_MUSIC_UPLINK2" type="out" id="23" />
<usecase name="USECASE_AUDIO_RECORD_COMPRESS2" type="in" id="37" />
<usecase name="USECASE_INCALL_REC_UPLINK" type="in" id="23" />
<usecase name="USECASE_INCALL_REC_DOWNLINK" type="in" id="23" />
<usecase name="USECASE_INCALL_REC_UPLINK_AND_DOWNLINK" type="in" id="23" />
</pcm_ids>
<config_params>
<!-- In the below value string, the value indicates default mono -->
<!-- speaker. It can be set to either left or right -->
<param key="mono_speaker" value="left"/>
<param key="spkr_1_tz_name" value="wsatz.13"/>
<param key="spkr_2_tz_name" value="wsatz.14"/>
<param key="true_32_bit" value="true"/>
<param key="hifi_filter" value="false"/>
<param key="native_audio_mode" value="multiple_mix_dsp"/>
<param key="hfp_pcm_dev_id" value="39"/>
<param key="input_mic_max_count" value="4"/>
</config_params>
<acdb_ids>
<device name="SND_DEVICE_OUT_SPEAKER" acdb_id="10011"/>
<device name="SND_DEVICE_OUT_SPEAKER_REVERSE" acdb_id="10011"/>
<device name="SND_DEVICE_OUT_SPEAKER_PROTECTED" acdb_id="124"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_PROTECTED" acdb_id="101"/>
<device name="SND_DEVICE_OUT_SPEAKER_PROTECTED_VBAT" acdb_id="124"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_PROTECTED_VBAT" acdb_id="101"/>
<device name="SND_DEVICE_IN_CAPTURE_VI_FEEDBACK" acdb_id="102"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_2_PROTECTED" acdb_id="150"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_2_PROTECTED_VBAT" acdb_id="150"/>
<device name="SND_DEVICE_IN_CAPTURE_VI_FEEDBACK_MONO_1" acdb_id="151"/>
<device name="SND_DEVICE_IN_CAPTURE_VI_FEEDBACK_MONO_2" acdb_id="152"/>
<device name="SND_DEVICE_OUT_SPEAKER_EXTERNAL_1" acdb_id="14"/>
<device name="SND_DEVICE_OUT_SPEAKER_EXTERNAL_2" acdb_id="14"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_HEADPHONES_EXTERNAL_1" acdb_id="10"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_HEADPHONES_EXTERNAL_2" acdb_id="10"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_USB_HEADSET" acdb_id="45"/>
<device name="SND_DEVICE_IN_UNPROCESSED_MIC" acdb_id="143"/>
<device name="SND_DEVICE_IN_UNPROCESSED_STEREO_MIC" acdb_id="144"/>
<device name="SND_DEVICE_IN_UNPROCESSED_THREE_MIC" acdb_id="145"/>
<device name="SND_DEVICE_IN_UNPROCESSED_QUAD_MIC" acdb_id="146"/>
<device name="SND_DEVICE_IN_UNPROCESSED_HEADSET_MIC" acdb_id="147"/>
<device name="SND_DEVICE_IN_HANDSET_GENERIC_QMIC" acdb_id="157"/>
<device name="SND_DEVICE_OUT_HEADPHONES" acdb_id="10012"/>
<device name="SND_DEVICE_OUT_HEADPHONES_44_1" acdb_id="10012"/>
<device name="SND_DEVICE_OUT_USB_HEADSET" acdb_id="10012"/>
<device name="SND_DEVICE_OUT_USB_HEADPHONES" acdb_id="10012"/>
<device name="SND_DEVICE_IN_VOICE_SPEAKER_MIC" acdb_id="11"/>
</acdb_ids>
<backend_names>
<device name="SND_DEVICE_OUT_HEADPHONES" backend="headphones" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_HEADPHONES_HIFI_FILTER" backend="headphones" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_HEADPHONES_44_1" backend="headphones-44.1" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_BT_SCO_WB" backend="bt-sco-wb" interface="SLIMBUS_7_RX"/>
<device name="SND_DEVICE_OUT_BT_SCO" backend="bt-sco" interface="SLIMBUS_7_RX"/>
<device name="SND_DEVICE_OUT_BT_A2DP" backend="bt-a2dp" interface="SLIMBUS_7_RX"/>
<device name="SND_DEVICE_OUT_LINE" backend="headphones" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_ANC_HEADSET" backend="headphones" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_HEADPHONES" backend="speaker-and-headphones" interface="TERT_MI2S_RX-and-RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_HEADPHONES_HIFI_FILTER" backend="speaker-and-headphones" interface="TERT_MI2S_RX-and-RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_HEADPHONES_CE" backend="speaker-and-headphones" interface="TERT_MI2S_RX-and-RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_HEADPHONES_NO_CE" backend="speaker-and-headphones" interface="TERT_MI2S_RX-and-RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_LINE" backend="speaker-and-headphones" interface="TERT_MI2S_RX-and-RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_ANC_HEADSET" backend="speaker-and-headphones" interface="TERT_MI2S_RX-and-RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_VOICE_HEADPHONES" backend="headphones" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_VOICE_HEADSET" backend="headset" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_VOICE_ANC_HEADSET" backend="headphones" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_VOICE_LINE" backend="headphones" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_VOICE_TTY_FULL_HEADPHONES" backend="headphones" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_VOICE_TTY_FULL_HEADSET" backend="headset" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_VOICE_TTY_VCO_HEADPHONES" backend="headphones" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_VOICE_TTY_VCO_HEADSET" backend="headset" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_HANDSET" backend="handset" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_SPEAKER" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_SPEAKER_EXTERNAL_1" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_SPEAKER_EXTERNAL_2" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_SPEAKER_REVERSE" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_SPEAKER_VBAT" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_HEADPHONES_EXTERNAL_1" interface="TERT_MI2S_RX-and-RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_HEADPHONES_EXTERNAL_2" interface="TERT_MI2S_RX-and-RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_VOICE_HANDSET" backend="handset" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_VOICE_HANDSET_TMUS" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_IN_HANDSET_GENERIC_QMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_STEREO" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_VBAT" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_2" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_2_VBAT" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_HDMI" interface="TERT_MI2S_RX-and-HDMI"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_DISPLAY_PORT" interface="TERT_MI2S_RX-and-DISPLAY_PORT"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_BT_A2DP" interface="TERT_MI2S_RX-and-SLIMBUS_7_RX"/>
<device name="SND_DEVICE_OUT_VOICE_TTY_HCO_HANDSET" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_ANC_FB_HEADSET" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_VOICE_ANC_FB_HEADSET" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_ANC_HANDSET" interface="RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_SPEAKER_PROTECTED" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_PROTECTED" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_2_PROTECTED" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_SPEAKER_PROTECTED_VBAT" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_PROTECTED_VBAT" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_2_PROTECTED_VBAT" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_SPEAKER_WSA" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_WSA" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_2_WSA" interface="TERT_MI2S_RX"/>
<device name="SND_DEVICE_IN_HANDSET_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_MIC_EXTERNAL" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_MIC_AEC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_MIC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_MIC_AEC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_DMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_DMIC_AEC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_DMIC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_DMIC_AEC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_DMIC_STEREO" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_MIC_AEC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_MIC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_MIC_AEC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_DMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_DMIC_AEC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_DMIC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_DMIC_AEC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HEADSET_MIC" backend="headset-mic" interface="TX_CDC_DMA_TX_4"/>
<device name="SND_DEVICE_IN_HEADSET_MIC_FLUENCE" backend="headset-mic" interface="TX_CDC_DMA_TX_4"/>
<device name="SND_DEVICE_IN_VOICE_HEADSET_MIC" backend="headset-mic" interface="TX_CDC_DMA_TX_4"/>
<device name="SND_DEVICE_IN_VOICE_TTY_FULL_HEADSET_MIC" backend="headset-mic" interface="TX_CDC_DMA_TX_4"/>
<device name="SND_DEVICE_IN_VOICE_TTY_HCO_HEADSET_MIC" backend="headset-mic" interface="TX_CDC_DMA_TX_4"/>
<device name="SND_DEVICE_IN_UNPROCESSED_HEADSET_MIC" backend="headset-mic" interface="TX_CDC_DMA_TX_4"/>
<device name="SND_DEVICE_IN_VOICE_REC_HEADSET_MIC" backend="headset-mic" interface="TX_CDC_DMA_TX_4"/>
<device name="SND_DEVICE_IN_HEADSET_MIC_AEC" backend="headset-mic" interface="TX_CDC_DMA_TX_4"/>
<device name="SND_DEVICE_IN_VOICE_SPEAKER_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HDMI_MIC" interface="HDMI"/>
<device name="SND_DEVICE_IN_BT_SCO_MIC" interface="SLIMBUS_7_TX"/>
<device name="SND_DEVICE_IN_BT_SCO_MIC_NREC" interface="SLIMBUS_7_TX"/>
<device name="SND_DEVICE_IN_BT_SCO_MIC_WB" interface="SLIMBUS_7_TX"/>
<device name="SND_DEVICE_IN_BT_SCO_MIC_WB_NREC" interface="SLIMBUS_7_TX"/>
<device name="SND_DEVICE_IN_CAMCORDER_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_VOICE_DMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_VOICE_SPEAKER_DMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_VOICE_SPEAKER_QMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_VOICE_TTY_VCO_HANDSET_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_VOICE_REC_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_VOICE_REC_MIC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_VOICE_REC_DMIC_STEREO" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_VOICE_REC_DMIC_FLUENCE" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_AANC_HANDSET_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_QUAD_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_STEREO_DMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_STEREO_DMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_CAPTURE_VI_FEEDBACK" interface="WSA_CDC_DMA_TX_0"/>
<device name="SND_DEVICE_IN_CAPTURE_VI_FEEDBACK_MONO_1" interface="WSA_CDC_DMA_TX_0"/>
<device name="SND_DEVICE_IN_CAPTURE_VI_FEEDBACK_MONO_2" interface="WSA_CDC_DMA_TX_0"/>
<device name="SND_DEVICE_IN_VOICE_SPEAKER_DMIC_BROADSIDE" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_DMIC_BROADSIDE" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_DMIC_AEC_BROADSIDE" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_DMIC_NS_BROADSIDE" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_DMIC_AEC_NS_BROADSIDE" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_VOICE_FLUENCE_DMIC_AANC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_QMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_QMIC_AEC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_QMIC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_QMIC_AEC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_THREE_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC_FLUENCE_PRO" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC_AEC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC_AEC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_VOICE_REC_TMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_UNPROCESSED_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_UNPROCESSED_STEREO_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_UNPROCESSED_THREE_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_UNPROCESSED_QUAD_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_UNPROCESSED_HEADSET_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_AND_VOICE_HEADPHONES" backend="speaker-and-headphones" interface="TERT_MI2S_RX-and-RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER_AND_VOICE_ANC_HEADSET" backend="speaker-and-headphones" interface="TERT_MI2S_RX-and-RX_CDC_DMA_RX_0"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_BT_SCO" backend="speaker-and-bt-sco" interface="TERT_MI2S_RX-and-SLIMBUS_7_RX"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_BT_SCO_WB" backend="speaker-and-bt-sco-wb" interface="TERT_MI2S_RX-and-SLIMBUS_7_RX"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_BT_SCO_SWB" backend="speaker-and-bt-sco-swb" interface="TERT_MI2S_RX-and-SLIMBUS_7_RX"/>
</backend_names>
<!-- below values are for ref purpose to OEM, doesn't contain actual hardware info on MTP -->
<microphone_characteristics>
<microphone valid_mask="31" device_id="builtin_mic_1" type="AUDIO_DEVICE_IN_BUILTIN_MIC" address="bottom" location="AUDIO_MICROPHONE_LOCATION_MAINBODY"
group="0" index_in_the_group="0" directionality="AUDIO_MICROPHONE_DIRECTIONALITY_OMNI" num_frequency_responses="93"
frequencies="100.00 106.00 112.00 118.00 125.00 132.00 140.00 150.00 160.00 170.00 180.00 190.00 200.00 212.00 224.00 236.00 250.00 265.00 280.00 300.00 315.00 335.00 355.00 375.00 400.00 425.00 450.00 475.00 500.00 530.00 560.00 600.00 630.00 670.00 710.00 750.00 800.00 850.00 900.00 950.00 1000.00 1060.00 1120.00 1180.00 1250.00 1320.00 1400.00 1500.00 1600.00 1700.00 1800.00 1900.00 2000.00 2120.00 2240.00 2360.00 2500.00 2650.00 2800.00 3000.00 3150.00 3350.00 3550.00 3750.00 4000.00 4250.00 4500.00 4750.00 5000.00 5300.00 5600.00 6000.00 6300.00 6700.00 7100.00 7500.00 8000.00 8500.00 9000.00 9500.00 10000.00 10600.00 11200.00 11800.00 12500.00 13200.00 14000.00 15000.00 16000.00 17000.00 18000.00 19000.00 20000.00"
responses="-0.78 -0.71 -0.64 -0.60 -0.55 -0.50 -0.47 -0.42 -0.39 -0.36 -0.34 -0.33 -0.32 -0.29 -0.28 -0.28 -0.27 -0.25 -0.25 -0.24 -0.23 -0.23 -0.22 -0.22 -0.19 -0.17 -0.15 -0.15 -0.14 -0.14 -0.12 -0.11 -0.10 -0.10 -0.08 -0.07 -0.07 -0.04 -0.03 -0.01 0.00 0.04 0.06 0.07 0.08 0.13 0.09 0.14 0.19 0.23 0.28 0.29 0.31 0.37 0.88 0.86 0.77 0.78 0.84 0.86 1.05 1.12 1.18 1.25 1.43 1.66 1.83 2.02 2.23 2.59 2.84 3.35 4.01 6.82 6.62 6.42 7.30 8.23 7.54 12.68 13.76 18.69 19.68 20.90 23.70 25.10 21.65 16.18 18.84 25.44 23.48 23.22 24.89"
sensitivity="-37.0" max_spl="132.5" min_spl="28.5" orientation="0.0 0.0 1.0" geometric_location="0.0269 0.0058 0.0079" />
<microphone valid_mask="31" device_id="builtin_mic_2" type="AUDIO_DEVICE_IN_BACK_MIC" address="back" location="AUDIO_MICROPHONE_LOCATION_MAINBODY"
group="0" index_in_the_group="1" directionality="AUDIO_MICROPHONE_DIRECTIONALITY_OMNI" num_frequency_responses="92"
frequencies="106.00 112.00 118.00 125.00 132.00 140.00 150.00 160.00 170.00 180.00 190.00 200.00 212.00 224.00 236.00 250.00 265.00 280.00 300.00 315.00 335.00 355.00 375.00 400.00 425.00 450.00 475.00 500.00 530.00 560.00 600.00 630.00 670.00 710.00 750.00 800.00 850.00 900.00 950.00 1000.00 1060.00 1120.00 1180.00 1250.00 1320.00 1400.00 1500.00 1600.00 1700.00 1800.00 1900.00 2000.00 2120.00 2240.00 2360.00 2500.00 2650.00 2800.00 3000.00 3150.00 3350.00 3550.00 3750.00 4000.00 4250.00 4500.00 4750.00 5000.00 5300.00 5600.00 6000.00 6300.00 6700.00 7100.00 7500.00 8000.00 8500.00 9000.00 9500.00 10000.00 10600.00 11200.00 11800.00 12500.00 13200.00 14000.00 15000.00 16000.00 17000.00 18000.00 19000.00 20000.00"
responses="-0.75 -0.74 -0.69 -0.65 -0.62 -0.61 -0.56 -0.53 -0.50 -0.47 -0.43 -0.40 -0.37 -0.36 -0.33 -0.30 -0.28 -0.25 -0.24 -0.24 -0.24 -0.25 -0.24 -0.12 -0.10 -0.08 -0.09 -0.07 -0.07 -0.06 -0.06 -0.06 -0.05 -0.04 -0.05 -0.04 -0.01 0.02 0.02 0.00 0.02 0.03 0.07 0.10 0.10 0.13 0.01 0.01 0.10 0.11 0.19 0.24 0.38 0.46 0.26 0.27 0.43 0.76 0.75 1.09 1.09 0.94 1.06 1.21 1.47 1.45 1.36 2.07 2.85 2.90 3.85 4.65 5.84 5.46 6.15 7.50 8.30 10.62 12.70 16.65 20.95 25.41 26.32 20.20 16.60 11.24 7.85 7.62 20.19 7.32 2.87 5.18"
sensitivity="-37.0" max_spl="132.5" min_spl="28.5" orientation="0.0 1.0 0.0" geometric_location="0.0546 0.1456 0.00415" />
<microphone valid_mask="31" device_id="builtin_mic_3" type="AUDIO_DEVICE_IN_BUILTIN_MIC" address="top" location="AUDIO_MICROPHONE_LOCATION_MAINBODY"
group="0" index_in_the_group="2" directionality="AUDIO_MICROPHONE_DIRECTIONALITY_OMNI" num_frequency_responses="92"
frequencies="100.00 106.00 112.00 118.00 125.00 132.00 140.00 150.00 160.00 170.00 180.00 190.00 200.00 212.00 224.00 236.00 250.00 265.00 280.00 300.00 315.00 335.00 355.00 375.00 400.00 425.00 450.00 475.00 500.00 530.00 560.00 600.00 630.00 670.00 710.00 750.00 800.00 850.00 900.00 950.00 1000.00 1060.00 1120.00 1180.00 1250.00 1320.00 1400.00 1500.00 1600.00 1700.00 1800.00 1900.00 2000.00 2120.00 2240.00 2360.00 2500.00 2650.00 2800.00 3000.00 3150.00 3350.00 3550.00 3750.00 4000.00 4250.00 4500.00 4750.00 5000.00 5300.00 5600.00 6000.00 6300.00 6700.00 7100.00 7500.00 8000.00 8500.00 9000.00 9500.00 10000.00 10600.00 11200.00 11800.00 12500.00 13200.00 14000.00 15000.00 16000.00 17000.00 18000.00 19000.00"
responses="-9.24 -9.31 -9.39 -9.45 -9.46 -9.47 -9.50 -9.52 -9.51 -9.52 -9.51 -9.50 -9.49 -9.47 -9.48 -9.49 -9.48 -9.50 -9.51 -9.53 -9.55 -9.59 -9.63 -9.67 -9.58 -9.57 -9.65 -9.68 -9.71 -9.75 -9.79 -9.84 -9.87 -9.87 -9.90 -9.90 -9.91 -9.97 -10.01 -10.05 -9.85 -9.93 -9.94 -9.98 -10.04 -10.12 -10.28 -10.25 -10.01 -9.86 -9.81 -9.82 -9.61 -9.46 -8.27 -8.42 -8.98 -8.99 -8.82 -9.21 -8.92 -8.97 -9.30 -9.44 -9.52 -9.28 -9.09 -8.81 -7.02 -5.72 -5.30 -7.26 -8.39 -12.28 -8.23 -6.99 -5.52 -4.87 -3.82 -6.09 0.00 -2.15 -0.26 1.48 5.22 10.92 6.41 9.55 12.96 3.35 22.00 19.75"
sensitivity="-37.0" max_spl="132.5" min_spl="28.5" orientation="0.0 0.0 1.0" geometric_location="0.0274 0.14065 0.0079" />
</microphone_characteristics>
<snd_devices>
<input_snd_device>
<input_snd_device_mic_mapping>
<snd_dev in_snd_device="SND_DEVICE_IN_CAMCORDER_MIC">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_3"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_VOICE_REC_MIC_AEC_NS">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_VOICE_REC_MIC_AEC">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_VOICE_REC_MIC_NS">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_VOICE_REC_MIC">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_HANDSET_MIC">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_VOICE_DMIC">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_VOICE_DMIC_TMUS">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_VOICE_SPEAKER_DMIC">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_3"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_HANDSET_DMIC_AEC_NS">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_HANDSET_DMIC_AEC">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_HANDSET_DMIC_NS">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_HANDSET_DMIC">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_SPEAKER_DMIC_AEC_NS">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_3"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_SPEAKER_DMIC_AEC">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_3"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_SPEAKER_DMIC_NS">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_3"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_SPEAKER_MIC">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_3"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_UNPROCESSED_MIC">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_DIRECT"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_UNPROCESSED_STEREO_MIC">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_DIRECT AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_DIRECT"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_UNPROCESSED_THREE_MIC">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_DIRECT AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_DIRECT AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/>
<mic_info mic_device_id="builtin_mic_3"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_DIRECT"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_HANDSET_DMIC_STEREO">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
<snd_dev in_snd_device="SND_DEVICE_IN_SPEAKER_DMIC_STEREO">
<mic_info mic_device_id="builtin_mic_1"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_2"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
<mic_info mic_device_id="builtin_mic_3"
channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/>
</snd_dev>
</input_snd_device_mic_mapping>
</input_snd_device>
</snd_devices>
</audio_platform_info>

View File

@ -0,0 +1,466 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!-- Copyright (c) 2016-2021, The Linux Foundation. All rights reserved
Not a Contribution.
-->
<!-- Copyright (C) 2015 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!--
Changes from Qualcomm Innovation Center are provided under the following license:
Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted (subject to the limitations in the
disclaimer below) provided that the following conditions are met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above
copyright notice, this list of conditions and the following
disclaimer in the documentation and/or other materials provided
with the distribution.
* Neither the name of Qualcomm Innovation Center, Inc. nor the names of its
contributors may be used to endorse or promote products derived
from this software without specific prior written permission.
NO EXPRESS OR IMPLIED LICENSES TO ANY PARTY'S PATENT RIGHTS ARE
GRANTED BY THIS LICENSE. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT
HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED
WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-->
<audioPolicyConfiguration version="1.0" xmlns:xi="http://www.w3.org/2001/XInclude">
<!-- version section contains a “version” tag in the form “major.minor” e.g version=”1.0” -->
<!-- Global configuration Decalaration -->
<globalConfiguration speaker_drc_enabled="true" call_screen_mode_supported="true"/>
<!-- Modules section:
There is one section per audio HW module present on the platform.
Each module section will contains two mandatory tags for audio HAL “halVersion” and “name”.
The module names are the same as in current .conf file:
“primary”, “A2DP”, “remote_submix”, “USB”
Each module will contain the following sections:
“devicePorts”: a list of device descriptors for all input and output devices accessible via this
module.
This contains both permanently attached devices and removable devices.
“mixPorts”: listing all output and input streams exposed by the audio HAL
“routes”: list of possible connections between input and output devices or between stream and
devices.
"route": is defined by an attribute:
-"type": <mux|mix> means all sources are mutual exclusive (mux) or can be mixed (mix)
-"sink": the sink involved in this route
-"sources": all the sources than can be connected to the sink via vis route
“attachedDevices”: permanently attached devices.
The attachedDevices section is a list of devices names. The names correspond to device names
defined in <devicePorts> section.
“defaultOutputDevice”: device to be used by default when no policy rule applies
-->
<modules>
<!-- Primary Audio HAL -->
<module name="primary" halVersion="2.0">
<attachedDevices>
<item>Earpiece</item>
<item>Speaker</item>
<item>Telephony Tx</item>
<item>Built-In Mic</item>
<item>Built-In Back Mic</item>
<item>FM Tuner</item>
<item>Telephony Rx</item>
</attachedDevices>
<defaultOutputDevice>Speaker</defaultOutputDevice>
<mixPorts>
<mixPort name="primary output" role="source" flags="AUDIO_OUTPUT_FLAG_FAST|AUDIO_OUTPUT_FLAG_PRIMARY">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="deep_buffer" role="source"
flags="AUDIO_OUTPUT_FLAG_DEEP_BUFFER">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="mmap_no_irq_out" role="source" flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_MMAP_NOIRQ">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="hifi_playback" role="source" />
<mixPort name="compress_passthrough" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD|AUDIO_OUTPUT_FLAG_NON_BLOCKING">
</mixPort>
<mixPort name="direct_pcm" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000,128000,176400,192000"
channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_2POINT1,AUDIO_CHANNEL_OUT_QUAD,AUDIO_CHANNEL_OUT_PENTA,AUDIO_CHANNEL_OUT_5POINT1,AUDIO_CHANNEL_OUT_6POINT1,AUDIO_CHANNEL_OUT_7POINT1"/>
<profile name="" format="AUDIO_FORMAT_PCM_8_24_BIT"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000,128000,176400,192000,352800,384000"
channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_2POINT1,AUDIO_CHANNEL_OUT_QUAD,AUDIO_CHANNEL_OUT_PENTA,AUDIO_CHANNEL_OUT_5POINT1,AUDIO_CHANNEL_OUT_6POINT1,AUDIO_CHANNEL_OUT_7POINT1"/>
<profile name="" format="AUDIO_FORMAT_PCM_24_BIT_PACKED"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000,128000,176400,192000,352800,384000"
channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_2POINT1,AUDIO_CHANNEL_OUT_QUAD,AUDIO_CHANNEL_OUT_PENTA,AUDIO_CHANNEL_OUT_5POINT1,AUDIO_CHANNEL_OUT_6POINT1,AUDIO_CHANNEL_OUT_7POINT1"/>
<profile name="" format="AUDIO_FORMAT_PCM_32_BIT"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000,128000,176400,192000,352800,384000"
channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_2POINT1,AUDIO_CHANNEL_OUT_QUAD,AUDIO_CHANNEL_OUT_PENTA,AUDIO_CHANNEL_OUT_5POINT1,AUDIO_CHANNEL_OUT_6POINT1,AUDIO_CHANNEL_OUT_7POINT1"/>
</mixPort>
<mixPort name="compressed_offload" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD|AUDIO_OUTPUT_FLAG_NON_BLOCKING">
<profile name="" format="AUDIO_FORMAT_MP3"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000"
channelMasks="AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_MONO"/>
<profile name="" format="AUDIO_FORMAT_FLAC"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000,128000,176400,192000"
channelMasks="AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_MONO"/>
<profile name="" format="AUDIO_FORMAT_ALAC"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000,128000,176400,192000"
channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_2POINT1,AUDIO_CHANNEL_OUT_QUAD,AUDIO_CHANNEL_OUT_PENTA,AUDIO_CHANNEL_OUT_5POINT1,AUDIO_CHANNEL_OUT_6POINT1,AUDIO_CHANNEL_OUT_7POINT1"/>
<profile name="" format="AUDIO_FORMAT_APE"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000,128000,176400,192000"
channelMasks="AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_MONO"/>
<profile name="" format="AUDIO_FORMAT_AAC_LC"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000"
channelMasks="AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_MONO"/>
<profile name="" format="AUDIO_FORMAT_AAC_HE_V1"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000"
channelMasks="AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_MONO"/>
<profile name="" format="AUDIO_FORMAT_AAC_HE_V2"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000"
channelMasks="AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_MONO"/>
<profile name="" format="AUDIO_FORMAT_DTS"
samplingRates="32000,44100,48000"
channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_2POINT1,AUDIO_CHANNEL_OUT_QUAD,AUDIO_CHANNEL_OUT_PENTA,AUDIO_CHANNEL_OUT_5POINT1"/>
<profile name="" format="AUDIO_FORMAT_DTS_HD"
samplingRates="32000,44100,48000,64000,88200,96000,128000,176400,192000"
channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_2POINT1,AUDIO_CHANNEL_OUT_QUAD,AUDIO_CHANNEL_OUT_PENTA,AUDIO_CHANNEL_OUT_5POINT1,AUDIO_CHANNEL_OUT_6POINT1,AUDIO_CHANNEL_OUT_7POINT1"/>
<profile name="" format="AUDIO_FORMAT_WMA"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000"
channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_2POINT1,AUDIO_CHANNEL_OUT_QUAD,AUDIO_CHANNEL_OUT_PENTA,AUDIO_CHANNEL_OUT_5POINT1,AUDIO_CHANNEL_OUT_6POINT1,AUDIO_CHANNEL_OUT_7POINT1"/>
<profile name="" format="AUDIO_FORMAT_WMA_PRO"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000"
channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_2POINT1,AUDIO_CHANNEL_OUT_QUAD,AUDIO_CHANNEL_OUT_PENTA,AUDIO_CHANNEL_OUT_5POINT1,AUDIO_CHANNEL_OUT_6POINT1,AUDIO_CHANNEL_OUT_7POINT1"/>
<profile name="" format="AUDIO_FORMAT_AAC_ADTS_LC"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000"
channelMasks="AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_MONO"/>
<profile name="" format="AUDIO_FORMAT_AAC_ADTS_HE_V1"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000"
channelMasks="AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_MONO"/>
<profile name="" format="AUDIO_FORMAT_AAC_ADTS_HE_V2"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,64000,88200,96000"
channelMasks="AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_MONO"/>
</mixPort>
<mixPort name="dsd_compress_passthrough" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD|AUDIO_OUTPUT_FLAG_NON_BLOCKING">
<profile name="" format="AUDIO_FORMAT_DSD"
samplingRates="2822400,5644800"
channelMasks="AUDIO_CHANNEL_OUT_STEREO,AUDIO_CHANNEL_OUT_MONO"/>
</mixPort>
<mixPort name="voice_tx" role="source">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,16000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="voip_rx" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_VOIP_RX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="incall_music_uplink" role="source"
flags="AUDIO_OUTPUT_FLAG_INCALL_MUSIC">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,16000,48000"
channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="primary input" role="sink" maxOpenCount="2" maxActiveCount="2">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000"
channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO,AUDIO_CHANNEL_IN_FRONT_BACK"/>
</mixPort>
<mixPort name="voip_tx" role="sink"
flags="AUDIO_INPUT_FLAG_VOIP_TX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_IN_MONO"/>
</mixPort>
<mixPort name="usb_surround_sound" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,88200,96000,176400,192000"
channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO,AUDIO_CHANNEL_IN_FRONT_BACK,AUDIO_CHANNEL_INDEX_MASK_3,AUDIO_CHANNEL_INDEX_MASK_4,AUDIO_CHANNEL_IN_5POINT1,AUDIO_CHANNEL_INDEX_MASK_6,AUDIO_CHANNEL_IN_7POINT1,AUDIO_CHANNEL_INDEX_MASK_8"/>
<profile name="" format="AUDIO_FORMAT_PCM_32_BIT"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,88200,96000,176400,192000"
channelMasks="AUDIO_CHANNEL_IN_5POINT1,AUDIO_CHANNEL_INDEX_MASK_6,AUDIO_CHANNEL_IN_7POINT1,AUDIO_CHANNEL_INDEX_MASK_8"/>
<profile name="" format="AUDIO_FORMAT_PCM_FLOAT"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,88200,96000,176400,192000"
channelMasks="AUDIO_CHANNEL_IN_STEREO,AUDIO_CHANNEL_INDEX_MASK_2,AUDIO_CHANNEL_IN_5POINT1,AUDIO_CHANNEL_INDEX_MASK_6,AUDIO_CHANNEL_IN_7POINT1,AUDIO_CHANNEL_INDEX_MASK_8"/>
</mixPort>
<mixPort name="record_24" role="sink" maxOpenCount="2" maxActiveCount="2">
<profile name="" format="AUDIO_FORMAT_PCM_24_BIT_PACKED"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,96000,192000"
channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO,AUDIO_CHANNEL_IN_FRONT_BACK,AUDIO_CHANNEL_INDEX_MASK_3,AUDIO_CHANNEL_INDEX_MASK_4"/>
<profile name="" format="AUDIO_FORMAT_PCM_8_24_BIT"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,96000,192000"
channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO,AUDIO_CHANNEL_IN_FRONT_BACK,AUDIO_CHANNEL_INDEX_MASK_3,AUDIO_CHANNEL_INDEX_MASK_4"/>
<profile name="" format="AUDIO_FORMAT_PCM_FLOAT"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000,96000,192000"
channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO,AUDIO_CHANNEL_IN_FRONT_BACK,AUDIO_CHANNEL_INDEX_MASK_3,AUDIO_CHANNEL_INDEX_MASK_4"/>
</mixPort>
<mixPort name="voice_rx" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,16000,48000" channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO"/>
</mixPort>
<mixPort name="mmap_no_irq_in" role="sink" flags="AUDIO_INPUT_FLAG_MMAP_NOIRQ">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000"
channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO,AUDIO_CHANNEL_IN_FRONT_BACK,AUDIO_CHANNEL_INDEX_MASK_3"/>
</mixPort>
<mixPort name="hifi_input" role="sink" />
<mixPort name="fast input" role="sink"
flags="AUDIO_INPUT_FLAG_FAST">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000"
channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO,AUDIO_CHANNEL_IN_FRONT_BACK"/>
</mixPort>
</mixPorts>
<devicePorts>
<!-- Output devices declaration, i.e. Sink DEVICE PORT -->
<devicePort tagName="Earpiece" type="AUDIO_DEVICE_OUT_EARPIECE" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
</devicePort>
<devicePort tagName="Speaker" role="sink" type="AUDIO_DEVICE_OUT_SPEAKER" address="">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort>
<devicePort tagName="Wired Headset" type="AUDIO_DEVICE_OUT_WIRED_HEADSET" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort>
<devicePort tagName="Wired Headphones" type="AUDIO_DEVICE_OUT_WIRED_HEADPHONE" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort>
<devicePort tagName="Line" type="AUDIO_DEVICE_OUT_LINE" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort>
<devicePort tagName="BT SCO" type="AUDIO_DEVICE_OUT_BLUETOOTH_SCO" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,16000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
</devicePort>
<devicePort tagName="BT SCO Headset" type="AUDIO_DEVICE_OUT_BLUETOOTH_SCO_HEADSET" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,16000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
</devicePort>
<devicePort tagName="BT SCO Car Kit" type="AUDIO_DEVICE_OUT_BLUETOOTH_SCO_CARKIT" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,16000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
</devicePort>
<devicePort tagName="Telephony Tx" type="AUDIO_DEVICE_OUT_TELEPHONY_TX" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,16000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort>
<devicePort tagName="HDMI" type="AUDIO_DEVICE_OUT_AUX_DIGITAL" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,11025,16000,22050,32000,44100,48000,64000,88200,96000,128000,176400,192000"/>
</devicePort>
<devicePort tagName="Proxy" type="AUDIO_DEVICE_OUT_PROXY" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,11025,16000,22050,32000,44100,48000,64000,88200,96000,128000,176400,192000"/>
</devicePort>
<devicePort tagName="FM" type="AUDIO_DEVICE_OUT_FM" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort>
<devicePort tagName="BT A2DP Out" type="AUDIO_DEVICE_OUT_BLUETOOTH_A2DP" role="sink"
encodedFormats="AUDIO_FORMAT_SBC AUDIO_FORMAT_AAC AUDIO_FORMAT_APTX AUDIO_FORMAT_APTX_HD AUDIO_FORMAT_LDAC AUDIO_FORMAT_CELT AUDIO_FORMAT_APTX_ADAPTIVE AUDIO_FORMAT_APTX_TWSP VX_AUDIO_FORMAT_LC3">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort>
<devicePort tagName="BT A2DP Headphones" type="AUDIO_DEVICE_OUT_BLUETOOTH_A2DP_HEADPHONES" role="sink"
encodedFormats="AUDIO_FORMAT_SBC AUDIO_FORMAT_AAC AUDIO_FORMAT_APTX AUDIO_FORMAT_APTX_HD AUDIO_FORMAT_LDAC AUDIO_FORMAT_CELT AUDIO_FORMAT_APTX_ADAPTIVE AUDIO_FORMAT_APTX_TWSP VX_AUDIO_FORMAT_LC3">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort>
<devicePort tagName="BT A2DP Speaker" type="AUDIO_DEVICE_OUT_BLUETOOTH_A2DP_SPEAKER" role="sink"
encodedFormats="AUDIO_FORMAT_SBC AUDIO_FORMAT_AAC AUDIO_FORMAT_APTX AUDIO_FORMAT_APTX_HD AUDIO_FORMAT_LDAC AUDIO_FORMAT_CELT AUDIO_FORMAT_APTX_ADAPTIVE AUDIO_FORMAT_APTX_TWSP VX_AUDIO_FORMAT_LC3">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort>
<devicePort tagName="USB Device Out" type="AUDIO_DEVICE_OUT_USB_DEVICE" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="44100,48000,64000,88200,96000,128000,176400,192000"/>
</devicePort>
<devicePort tagName="USB Headset Out" type="AUDIO_DEVICE_OUT_USB_HEADSET" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="44100,48000,64000,88200,96000,128000,176400,192000"/>
</devicePort>
<!-- Input devices declaration, i.e. Source DEVICE PORT -->
<devicePort tagName="Built-In Mic" type="AUDIO_DEVICE_IN_BUILTIN_MIC" role="source">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000"
channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO,AUDIO_CHANNEL_IN_FRONT_BACK"/>
</devicePort>
<devicePort tagName="Built-In Back Mic" type="AUDIO_DEVICE_IN_BACK_MIC" role="source">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000"
channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO,AUDIO_CHANNEL_IN_FRONT_BACK"/>
</devicePort>
<devicePort tagName="FM Tuner" type="AUDIO_DEVICE_IN_FM_TUNER" role="source">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000"
channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO"/>
</devicePort>
<devicePort tagName="Wired Headset Mic" type="AUDIO_DEVICE_IN_WIRED_HEADSET" role="source">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,11025,12000,16000,22050,24000,32000,44100,48000"
channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO,AUDIO_CHANNEL_IN_FRONT_BACK"/>
</devicePort>
<devicePort tagName="BT SCO Headset Mic" type="AUDIO_DEVICE_IN_BLUETOOTH_SCO_HEADSET" role="source">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,16000" channelMasks="AUDIO_CHANNEL_IN_MONO"/>
</devicePort>
<devicePort tagName="Telephony Rx" type="AUDIO_DEVICE_IN_TELEPHONY_RX" role="source">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="8000,16000,48000" channelMasks="AUDIO_CHANNEL_IN_MONO"/>
</devicePort>
<devicePort tagName="USB Device In" type="AUDIO_DEVICE_IN_USB_DEVICE" role="source">
</devicePort>
<devicePort tagName="USB Headset In" type="AUDIO_DEVICE_IN_USB_HEADSET" role="source">
</devicePort>
</devicePorts>
<!-- route declaration, i.e. list all available sources for a given sink -->
<routes>
<route type="mix" sink="Earpiece"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,voip_rx,mmap_no_irq_out"/>
<route type="mix" sink="Speaker"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,voip_rx,mmap_no_irq_out"/>
<route type="mix" sink="Wired Headset"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,dsd_compress_passthrough,voip_rx,mmap_no_irq_out"/>
<route type="mix" sink="Wired Headphones"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,dsd_compress_passthrough,voip_rx,mmap_no_irq_out"/>
<route type="mix" sink="Line"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,dsd_compress_passthrough,voip_rx,mmap_no_irq_out"/>
<route type="mix" sink="HDMI"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,compress_passthrough,voip_rx"/>
<route type="mix" sink="Proxy"
sources="primary output,deep_buffer,direct_pcm,compressed_offload"/>
<route type="mix" sink="FM"
sources="primary output"/>
<route type="mix" sink="BT SCO"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,voip_rx"/>
<route type="mix" sink="BT SCO Headset"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,voip_rx"/>
<route type="mix" sink="BT SCO Car Kit"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,voip_rx"/>
<route type="mix" sink="USB Device Out"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,voip_rx,mmap_no_irq_out,hifi_playback"/>
<route type="mix" sink="USB Headset Out"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,voip_rx,mmap_no_irq_out,hifi_playback"/>
<route type="mix" sink="Telephony Tx"
sources="voice_tx,incall_music_uplink"/>
<route type="mix" sink="voice_rx"
sources="Telephony Rx"/>
<route type="mix" sink="primary input"
sources="Built-In Mic,Built-In Back Mic,Wired Headset Mic,BT SCO Headset Mic,FM Tuner,USB Device In,USB Headset In,Telephony Rx"/>
<route type="mix" sink="voip_tx"
sources="Built-In Mic,Built-In Back Mic,BT SCO Headset Mic,USB Device In,USB Headset In,Wired Headset Mic"/>
<route type="mix" sink="usb_surround_sound"
sources="USB Device In,USB Headset In"/>
<route type="mix" sink="record_24"
sources="Built-In Mic,Built-In Back Mic,Wired Headset Mic,BT SCO Headset Mic"/>
<route type="mix" sink="mmap_no_irq_in"
sources="Built-In Mic,Built-In Back Mic,Wired Headset Mic,USB Device In,USB Headset In"/>
<route type="mix" sink="BT A2DP Out"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,voip_rx"/>
<route type="mix" sink="BT A2DP Headphones"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,voip_rx"/>
<route type="mix" sink="BT A2DP Speaker"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,voip_rx"/>
<route type="mix" sink="hifi_input" sources="USB Device In,USB Headset In" />
<route type="mix" sink="fast input"
sources="Built-In Mic,Built-In Back Mic,BT SCO Headset Mic,USB Device In,USB Headset In,Wired Headset Mic"/>
</routes>
</module>
<!-- A2DP Audio HAL -->
<module name="a2dp" halVersion="2.0">
<mixPorts>
<mixPort name="a2dp input" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="44100,48000" channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO"/>
</mixPort>
</mixPorts>
<devicePorts>
<devicePort tagName="BT A2DP In" type="AUDIO_DEVICE_IN_BLUETOOTH_A2DP" role="source">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="44100,48000" channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO"/>
</devicePort>
</devicePorts>
<routes>
<route type="mix" sink="a2dp input"
sources="BT A2DP In"/>
</routes>
</module>
<!-- Usb Audio HAL -->
<module name="usb" halVersion="2.0">
<mixPorts>
<mixPort name="usb_accessory output" role="source">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="44100" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
</mixPorts>
<devicePorts>
<devicePort tagName="USB Host Out" type="AUDIO_DEVICE_OUT_USB_ACCESSORY" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="44100" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort>
</devicePorts>
<routes>
<route type="mix" sink="USB Host Out"
sources="usb_accessory output"/>
</routes>
</module>
<!-- Remote Submix Audio HAL -->
<xi:include href="/vendor/etc/r_submix_audio_policy_configuration.xml"/>
</modules>
<!-- End of Modules section -->
<!-- Volume section -->
<xi:include href="/vendor/etc/audio_policy_volumes.xml"/>
<xi:include href="/vendor/etc/default_volume_tables.xml"/>
<!-- End of Volume section -->
</audioPolicyConfiguration>

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,336 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!--- Copyright (c) 2014-2020, The Linux Foundation. All rights reserved. -->
<!--- -->
<!--- Redistribution and use in source and binary forms, with or without -->
<!--- modification, are permitted provided that the following conditions are -->
<!--- met: -->
<!--- * Redistributions of source code must retain the above copyright -->
<!--- notice, this list of conditions and the following disclaimer. -->
<!--- * Redistributions in binary form must reproduce the above -->
<!--- copyright notice, this list of conditions and the following -->
<!--- disclaimer in the documentation and/or other materials provided -->
<!--- with the distribution. -->
<!--- * Neither the name of The Linux Foundation nor the names of its -->
<!--- contributors may be used to endorse or promote products derived -->
<!--- from this software without specific prior written permission. -->
<!--- -->
<!--- THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED -->
<!--- WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -->
<!--- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT -->
<!--- ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS -->
<!--- BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -->
<!--- CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF -->
<!--- SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR -->
<!--- BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -->
<!--- WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE -->
<!--- OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN -->
<!--- IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -->
<mixer>
<!-- These are the initial mixer settings -->
<ctl name="LSM1 Mixer VA_CDC_DMA_TX_0" value="0" />
<ctl name="LSM2 Mixer VA_CDC_DMA_TX_0" value="0" />
<ctl name="LSM3 Mixer VA_CDC_DMA_TX_0" value="0" />
<ctl name="LSM4 Mixer VA_CDC_DMA_TX_0" value="0" />
<ctl name="LSM5 Mixer VA_CDC_DMA_TX_0" value="0" />
<ctl name="LSM6 Mixer VA_CDC_DMA_TX_0" value="0" />
<ctl name="LSM7 Mixer VA_CDC_DMA_TX_0" value="0" />
<ctl name="LSM8 Mixer VA_CDC_DMA_TX_0" value="0" />
<ctl name="LSM1 Port" value="None" />
<ctl name="LSM2 Port" value="None" />
<ctl name="LSM3 Port" value="None" />
<ctl name="LSM4 Port" value="None" />
<ctl name="LSM5 Port" value="None" />
<ctl name="LSM6 Port" value="None" />
<ctl name="LSM7 Port" value="None" />
<ctl name="LSM8 Port" value="None" />
<ctl name="VA_CDC_DMA_TX_0 Channels" value="One" />
<ctl name="VA_AIF1_CAP Mixer DEC0" value="0" />
<ctl name="VA_AIF1_CAP Mixer DEC1" value="0" />
<ctl name="VA_AIF1_CAP Mixer DEC2" value="0" />
<ctl name="VA_AIF1_CAP Mixer DEC3" value="0" />
<ctl name="VA_AIF1_CAP Mixer DEC4" value="0" />
<ctl name="VA_AIF1_CAP Mixer DEC5" value="0" />
<ctl name="VA_AIF1_CAP Mixer DEC6" value="0" />
<ctl name="VA_AIF1_CAP Mixer DEC7" value="0" />
<ctl name="VA DEC0 MUX" value="MSM_DMIC" />
<ctl name="VA DEC1 MUX" value="MSM_DMIC" />
<ctl name="VA DEC2 MUX" value="MSM_DMIC" />
<ctl name="VA DEC3 MUX" value="MSM_DMIC" />
<ctl name="VA DEC4 MUX" value="MSM_DMIC" />
<ctl name="VA DEC5 MUX" value="MSM_DMIC" />
<ctl name="VA DEC6 MUX" value="MSM_DMIC" />
<ctl name="VA DEC7 MUX" value="MSM_DMIC" />
<ctl name="VA DMIC MUX0" value="ZERO" />
<ctl name="VA DMIC MUX1" value="ZERO" />
<ctl name="VA DMIC MUX2" value="ZERO" />
<ctl name="VA DMIC MUX3" value="ZERO" />
<ctl name="VA DMIC MUX4" value="ZERO" />
<ctl name="VA DMIC MUX5" value="ZERO" />
<ctl name="VA DMIC MUX6" value="ZERO" />
<ctl name="VA DMIC MUX7" value="ZERO" />
<ctl name="VA SMIC MUX0" value="ZERO" />
<ctl name="VA SMIC MUX1" value="ZERO" />
<ctl name="VA SMIC MUX2" value="ZERO" />
<ctl name="VA SMIC MUX3" value="ZERO" />
<ctl name="VA SMIC MUX4" value="ZERO" />
<ctl name="VA SMIC MUX5" value="ZERO" />
<ctl name="VA SMIC MUX6" value="ZERO" />
<ctl name="VA SMIC MUX7" value="ZERO" />
<ctl name="AUDIO_REF_EC_UL1 MUX" value="None"/>
<ctl name="EC Reference Channels" value="Zero"/>
<ctl name="EC Reference Bit Format" value="0"/>
<ctl name="EC Reference SampleRate" value="0"/>
<ctl name="ADC2_MIXER Switch" value="0" />
<ctl name="LPI Enable" value="0" />
<ctl name="ADC2 Volume" value="12" />
<ctl name="VA_DEC0 MODE" value="ADC_DEFAULT" />
<ctl name="ADC2_BCS Disable" value="0" />
<path name="listen-voice-wakeup-1">
<ctl name="LSM1 Mixer VA_CDC_DMA_TX_0" value="1" />
</path>
<path name="listen-voice-wakeup-2">
<ctl name="LSM2 Mixer VA_CDC_DMA_TX_0" value="1" />
</path>
<path name="listen-voice-wakeup-3">
<ctl name="LSM3 Mixer VA_CDC_DMA_TX_0" value="1" />
</path>
<path name="listen-voice-wakeup-4">
<ctl name="LSM4 Mixer VA_CDC_DMA_TX_0" value="1" />
</path>
<path name="listen-voice-wakeup-5">
<ctl name="LSM5 Mixer VA_CDC_DMA_TX_0" value="1" />
</path>
<path name="listen-voice-wakeup-6">
<ctl name="LSM6 Mixer VA_CDC_DMA_TX_0" value="1" />
</path>
<path name="listen-voice-wakeup-7">
<ctl name="LSM7 Mixer VA_CDC_DMA_TX_0" value="1" />
</path>
<path name="listen-voice-wakeup-8">
<ctl name="LSM8 Mixer VA_CDC_DMA_TX_0" value="1" />
</path>
<path name="listen-voice-wakeup-1 preproc">
<path name="listen-voice-wakeup-1" />
</path>
<path name="listen-voice-wakeup-2 preproc">
<path name="listen-voice-wakeup-2" />
</path>
<path name="listen-voice-wakeup-3 preproc">
<path name="listen-voice-wakeup-3" />
</path>
<path name="listen-voice-wakeup-4 preproc">
<path name="listen-voice-wakeup-4" />
</path>
<path name="listen-voice-wakeup-5 preproc">
<path name="listen-voice-wakeup-5" />
</path>
<path name="listen-voice-wakeup-6 preproc">
<path name="listen-voice-wakeup-6" />
</path>
<path name="listen-voice-wakeup-7 preproc">
<path name="listen-voice-wakeup-7" />
</path>
<path name="listen-voice-wakeup-8 preproc">
<path name="listen-voice-wakeup-8" />
</path>
<path name="listen-voice-wakeup-1 port">
<ctl name="LSM1 Port" value="VA_CDC_DMA_TX_0" />
<ctl name="LPI Enable" value="1" />
<ctl name="ADC2_BCS Disable" value="1" />
</path>
<path name="listen-voice-wakeup-2 port">
<ctl name="LSM2 Port" value="VA_CDC_DMA_TX_0" />
<ctl name="LPI Enable" value="1" />
<ctl name="ADC2_BCS Disable" value="1" />
</path>
<path name="listen-voice-wakeup-3 port">
<ctl name="LSM3 Port" value="VA_CDC_DMA_TX_0" />
<ctl name="LPI Enable" value="1" />
<ctl name="ADC2_BCS Disable" value="1" />
</path>
<path name="listen-voice-wakeup-4 port">
<ctl name="LSM4 Port" value="VA_CDC_DMA_TX_0" />
<ctl name="LPI Enable" value="1" />
<ctl name="ADC2_BCS Disable" value="1" />
</path>
<path name="listen-voice-wakeup-5 port">
<ctl name="LSM5 Port" value="VA_CDC_DMA_TX_0" />
<ctl name="LPI Enable" value="1" />
<ctl name="ADC2_BCS Disable" value="1" />
</path>
<path name="listen-voice-wakeup-6 port">
<ctl name="LSM6 Port" value="VA_CDC_DMA_TX_0" />
<ctl name="LPI Enable" value="1" />
<ctl name="ADC2_BCS Disable" value="1" />
</path>
<path name="listen-voice-wakeup-7 port">
<ctl name="LSM7 Port" value="VA_CDC_DMA_TX_0" />
<ctl name="LPI Enable" value="1" />
<ctl name="ADC2_BCS Disable" value="1" />
</path>
<path name="listen-voice-wakeup-8 port">
<ctl name="LSM8 Port" value="VA_CDC_DMA_TX_0" />
<ctl name="LPI Enable" value="1" />
<ctl name="ADC2_BCS Disable" value="1" />
</path>
<path name="listen-voice-wakeup-1 preproc port">
<ctl name="LSM1 Port" value="ADM_LSM_TX" />
<ctl name="LPI Enable" value="0" />
<ctl name="ADC2_BCS Disable" value="0" />
</path>
<path name="listen-voice-wakeup-2 preproc port">
<ctl name="LSM2 Port" value="ADM_LSM_TX" />
<ctl name="LPI Enable" value="0" />
<ctl name="ADC2_BCS Disable" value="0" />
</path>
<path name="listen-voice-wakeup-3 preproc port">
<ctl name="LSM3 Port" value="ADM_LSM_TX" />
<ctl name="LPI Enable" value="0" />
<ctl name="ADC2_BCS Disable" value="0" />
</path>
<path name="listen-voice-wakeup-4 preproc port">
<ctl name="LSM4 Port" value="ADM_LSM_TX" />
<ctl name="LPI Enable" value="0" />
<ctl name="ADC2_BCS Disable" value="0" />
</path>
<path name="listen-voice-wakeup-5 preproc port">
<ctl name="LSM5 Port" value="ADM_LSM_TX" />
<ctl name="LPI Enable" value="0" />
<ctl name="ADC2_BCS Disable" value="0" />
</path>
<path name="listen-voice-wakeup-6 preproc port">
<ctl name="LSM6 Port" value="ADM_LSM_TX" />
<ctl name="LPI Enable" value="0" />
<ctl name="ADC2_BCS Disable" value="0" />
</path>
<path name="listen-voice-wakeup-7 preproc port">
<ctl name="LSM7 Port" value="ADM_LSM_TX" />
<ctl name="LPI Enable" value="0" />
<ctl name="ADC2_BCS Disable" value="0" />
</path>
<path name="listen-voice-wakeup-8 preproc port">
<ctl name="LSM8 Port" value="ADM_LSM_TX" />
<ctl name="LPI Enable" value="0" />
<ctl name="ADC2_BCS Disable" value="0" />
</path>
<path name="listen-ape-handset-mic">
<ctl name="VA_AIF1_CAP Mixer DEC0" value="1" />
<ctl name="VA DEC0 MUX" value="SWR_MIC" />
<ctl name="VA SMIC MUX0" value="ADC2" />
<ctl name="ADC2_MIXER Switch" value="1" />
<ctl name="ADC2 MUX" value="INP3" />
</path>
<path name="listen-ape-handset-mic-preproc">
<path name="listen-ape-handset-mic" />
</path>
<path name="listen-ape-handset-dmic">
<ctl name="VA_CDC_DMA_TX_0 Channels" value="Two" />
<ctl name="VA_AIF1_CAP Mixer DEC0" value="1" />
<ctl name="VA_AIF1_CAP Mixer DEC1" value="1" />
<ctl name="VA DEC0 MUX" value="SWR_MIC" />
<ctl name="VA SMIC MUX0" value="ADC0" />
<ctl name="ADC1_MIXER Switch" value="1" />
<ctl name="VA DEC1 MUX" value="SWR_MIC" />
<ctl name="VA SMIC MUX1" value="ADC2" />
<ctl name="ADC2_MIXER Switch" value="1" />
<ctl name="ADC2 MUX" value="INP3" />
<ctl name="VA_DEC0 Volume" value="95" />
<ctl name="VA_DEC1 Volume" value="90" />
</path>
<path name="listen-ape-handset-tmic">
<ctl name="VA_CDC_DMA_TX_0 Channels" value="Three" />
<ctl name="VA_AIF1_CAP Mixer DEC0" value="1" />
<ctl name="VA_AIF1_CAP Mixer DEC1" value="1" />
<ctl name="VA_AIF1_CAP Mixer DEC2" value="1" />
<ctl name="VA DEC0 MUX" value="MSM_DMIC" />
<ctl name="VA DEC1 MUX" value="MSM_DMIC" />
<ctl name="VA DEC2 MUX" value="MSM_DMIC" />
<ctl name="VA DMIC MUX0" value="DMIC1" />
<ctl name="VA DMIC MUX1" value="DMIC4" />
<ctl name="VA DMIC MUX2" value="DMIC0" />
</path>
<path name="listen-ape-handset-qmic">
<ctl name="VA_CDC_DMA_TX_0 Channels" value="Four" />
<ctl name="VA_AIF1_CAP Mixer DEC0" value="1" />
<ctl name="VA_AIF1_CAP Mixer DEC1" value="1" />
<ctl name="VA_AIF1_CAP Mixer DEC2" value="1" />
<ctl name="VA_AIF1_CAP Mixer DEC3" value="1" />
<ctl name="VA DEC0 MUX" value="MSM_DMIC" />
<ctl name="VA DEC1 MUX" value="MSM_DMIC" />
<ctl name="VA DEC2 MUX" value="MSM_DMIC" />
<ctl name="VA DEC3 MUX" value="MSM_DMIC" />
<ctl name="VA DMIC MUX0" value="DMIC0" />
<ctl name="VA DMIC MUX1" value="DMIC2" />
<ctl name="VA DMIC MUX2" value="DMIC3" />
<ctl name="VA DMIC MUX3" value="DMIC1" />
</path>
<path name="listen-ape-headset-mic">
<ctl name="VA_AIF1_CAP Mixer DEC0" value="1" />
<ctl name="VA DEC0 MUX" value="SWR_MIC" />
<ctl name="VA SMIC MUX0" value="ADC1" />
<ctl name="ADC2_MIXER Switch" value="1" />
<ctl name="ADC2 MUX" value="INP2" />
<ctl name="VA_DEC0 MODE" value="ADC_LOW_PWR" />
</path>
<path name="echo-reference">
<ctl name="AUDIO_REF_EC_UL1 MUX" value="TERT_MI2S_RX"/>
<ctl name="EC Reference Channels" value="One"/>
<ctl name="EC Reference Bit Format" value="S16_LE"/>
<ctl name="EC Reference SampleRate" value="48000"/>
</path>
<path name="echo-reference headset">
<ctl name="AUDIO_REF_EC_UL1 MUX" value="RX_CDC_DMA_RX_0"/>
<ctl name="EC Reference Channels" value="One"/>
<ctl name="EC Reference Bit Format" value="S16_LE"/>
<ctl name="EC Reference SampleRate" value="48000"/>
</path>
<path name="echo-reference a2dp">
<ctl name="AUDIO_REF_EC_UL1 MUX" value="SLIM_7_RX"/>
<ctl name="EC Reference Channels" value="Two"/>
<ctl name="EC Reference Bit Format" value="S16_LE"/>
<ctl name="EC Reference SampleRate" value="48000"/>
</path>
</mixer>

View File

@ -0,0 +1,374 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!--- Copyright (c) 2013-2020, The Linux Foundation. All rights reserved. -->
<!--- -->
<!--- Redistribution and use in source and binary forms, with or without -->
<!--- modification, are permitted provided that the following conditions are -->
<!--- met: -->
<!--- * Redistributions of source code must retain the above copyright -->
<!--- notice, this list of conditions and the following disclaimer. -->
<!--- * Redistributions in binary form must reproduce the above -->
<!--- copyright notice, this list of conditions and the following -->
<!--- disclaimer in the documentation and/or other materials provided -->
<!--- with the distribution. -->
<!--- * Neither the name of The Linux Foundation nor the names of its -->
<!--- contributors may be used to endorse or promote products derived -->
<!--- from this software without specific prior written permission. -->
<!--- -->
<!--- THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED -->
<!--- WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -->
<!--- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT -->
<!--- ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS -->
<!--- BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -->
<!--- CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF -->
<!--- SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR -->
<!--- BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -->
<!--- WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE -->
<!--- OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN -->
<!--- IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -->
<sound_trigger_platform_info>
<param version="0x0105" /> <!-- this must be the first param -->
<!--- Version History: -->
<!--- 0x0101: Legacy version. -->
<!--- 0x0102: Includes acdb_ids param with the gcs_usecase tag. This matches -->
<!--- the gcs_usecase with the acdb device that uses it. -->
<!--- 0x0103: app_type and in_channels added to <lsm usecase> and out_channels -->
<!--- added to <adm_config> -->
<!--- 0x0104: instance id support for both WDSP<CPE> and ADSP lsm usecases -->
<!--- 0x0105: Select <lsm_usecase> based on capture device -->
<common_config>
<param implementer_version="0x0101" />
<param max_ape_sessions="8" />
<param enable_failure_detection="false" />
<param support_device_switch="false" />
<param transit_to_non_lpi_on_battery_charging="false" />
<!-- Below backend params must match with port used in mixer path file -->
<!-- param used to configure backend sample rate, format and channels -->
<param backend_port_name="VA_CDC_DMA_TX_0" />
<!-- Param used to match and obtain device backend index -->
<param backend_dai_name="VA_CDC_DMA_TX_0" />
<!-- Param used to indicate if SVA has dedicated SLIM ports -->
<param dedicated_sva_path="false" />
<param dedicated_headset_path="false" />
<param platform_lpi_enable="true" />
<param enable_debug_dumps="false" />
<param support_non_lpi_without_ec="false" />
<param concurrent_capture="false" />
</common_config>
<acdb_ids>
<param DEVICE_HANDSET_MIC_APE="100" />
<param DEVICE_HANDSET_MIC_PP_APE="135" />
<param DEVICE_HANDSET_DMIC_APE="149" />
<param DEVICE_HANDSET_DMIC_LPI_APE="179" />
<param DEVICE_HANDSET_TMIC_APE="157" />
<param DEVICE_HANDSET_TMIC_LPI_APE="180" />
<param DEVICE_HANDSET_QMIC_APE="137" />
<param DEVICE_HANDSET_QMIC_LPI_APE="181" />
<param DEVICE_HEADSET_MIC_APE="141" />
<param DEVICE_HEADSET_MIC_APE_LPI="182" />
</acdb_ids>
<!-- Multiple sound_model_config tags can be listed, each with unique -->
<!-- vendor_uuid. The below tag represents QTI SVA engine sound model -->
<!-- configuration. ISV must use their own unique vendor_uuid. -->
<!-- QTI SVA -->
<sound_model_config>
<param vendor_uuid="68ab2d40-e860-11e3-95ef-0002a5d5c51b" />
<param execution_type="ADSP" />
<param merge_first_stage_sound_models="false" />
<param max_ape_phrases="20" />
<param max_ape_users="10" />
<!-- Profile specific data which the algorithm can support -->
<param sample_rate="16000" />
<param bit_width="16" />
<param out_channels="1"/> <!-- Module output channels -->
<param dam_token_id="1"/>
<arm_ss_usecase>
<!-- Options are "KEYWORD_DETECTION", "USER_VERIFICATION", "CUSTOM_DETECTION" -->
<param sm_detection_type= "KEYWORD_DETECTION" />
<param sm_id="0x2" />
<param module_lib="libcapiv2svacnn.so"/>
<param sample_rate="16000"/>
<param bit_wdith="16"/>
<param channel_count="1"/>
</arm_ss_usecase>
<arm_ss_usecase>
<param sm_detection_type= "USER_VERIFICATION" />
<param sm_id="0x4" />
<param module_lib="libcapiv2vop.so"/>
<param sample_rate="16000"/>
<param bit_wdith="16"/>
<param channel_count="1"/>
</arm_ss_usecase>
<arm_ss_usecase>
<param sm_detection_type= "KEYWORD_DETECTION" />
<param sm_id="0x8" />
<param module_lib="libcapiv2svarnn.so"/>
<param sample_rate="16000"/>
<param bit_wdith="16"/>
<param channel_count="1"/>
</arm_ss_usecase>
<!-- Module and param ids with which the algorithm is integrated
in non-graphite firmware (note these must come after gcs params)
Extends flexibility to have different ids based on execution type.
valid execution_type values: "WDSP" "ADSP" -->
<lsm_usecase>
<param capture_device="HANDSET" />
<!-- adm_cfg_profile should match with the one defined under adm_config -->
<!-- Set it to NONE if LSM directly connects to AFE -->
<param adm_cfg_profile="FFECNS" />
<!-- fluence_type: "FLUENCE_MIC", "FLUENCE_DMIC", "FLUENCE_TMIC" -->
<!-- "FLUENCE_QMIC". Param value is valid when adm_cfg_profile -->
<!-- is FFECNS -->
<param fluence_type="FLUENCE_MIC" />
<param execution_mode="ADSP" />
<!-- lpi_mode: "NON_LPI_BARGE_IN", "NON_LPI", "LPI" -->
<!-- NON_LPI_BARGE_IN: Default non-LPI mode type. lsm_usecase -->
<!-- must be present with this mode type to handle barge-in. -->
<!-- NON_LPI: If another lsm_usecase is present with this mode -->
<!-- type, it will be used for non-LPI non-barge-in usecases. -->
<!-- If not present, NON_LPI_BARGE_IN mode type will be used. -->
<!-- LPI: This mode type will be used for LPI usecases. -->
<param lpi_mode="NON_LPI_BARGE_IN" />
<param app_type="2" /> <!-- app type used in ACDB -->
<param in_channels="1"/> <!-- Module input channels -->
<param load_sound_model_ids="0x00012C1C, 0x0, 0x00012C14" />
<param unload_sound_model_ids="0x00012C1C, 0x0, 0x00012C15" />
<param confidence_levels_ids="0x00012C1C, 0x0, 0x00012C07" />
<param operation_mode_ids="0x00012C1C, 0x0, 0x00012C02" />
<param polling_enable_ids="0x00012C1C, 0x0, 0x00012C1B" />
<param custom_config_ids="0x00012C1C, 0x0, 0x00012C20" />
<param det_event_type_ids="0x00012C1C, 0x0, 0x00012C2C" />
<param lab_dam_cfg_ids="0x00012C08, 0x0, 0x000102C4" />
</lsm_usecase>
<lsm_usecase>
<param capture_device="HANDSET" />
<!-- adm_cfg_profile should match with the one defined under adm_config -->
<!-- Set it to NONE if LSM directly connects to AFE -->
<param adm_cfg_profile="FFECNS" />
<!-- fluence_type: "FLUENCE_MIC", "FLUENCE_DMIC", "FLUENCE_TMIC" -->
<!-- "FLUENCE_QMIC". Param value is valid when adm_cfg_profile -->
<!-- is FFECNS -->
<param fluence_type="FLUENCE_MIC" />
<param execution_mode="ADSP" />
<!-- lpi_mode: "NON_LPI_BARGE_IN", "NON_LPI", "LPI" -->
<!-- NON_LPI_BARGE_IN: Default non-LPI mode type. lsm_usecase -->
<!-- must be present with this mode type to handle barge-in. -->
<!-- NON_LPI: If another lsm_usecase is present with this mode -->
<!-- type, it will be used for non-LPI non-barge-in usecases. -->
<!-- If not present, NON_LPI_BARGE_IN mode type will be used. -->
<!-- LPI: This mode type will be used for LPI usecases. -->
<param lpi_mode="LPI" />
<param app_type="2" /> <!-- app type used in ACDB -->
<param in_channels="1"/> <!-- Module input channels -->
<param load_sound_model_ids="0x00012C1C, 0x0, 0x00012C14" />
<param unload_sound_model_ids="0x00012C1C, 0x0, 0x00012C15" />
<param confidence_levels_ids="0x00012C1C, 0x0, 0x00012C07" />
<param operation_mode_ids="0x00012C1C, 0x0, 0x00012C02" />
<param polling_enable_ids="0x00012C1C, 0x0, 0x00012C1B" />
<param custom_config_ids="0x00012C1C, 0x0, 0x00012C20" />
<param det_event_type_ids="0x00012C1C, 0x0, 0x00012C2C" />
<param lab_dam_cfg_ids="0x00012C08, 0x0, 0x000102C4" />
</lsm_usecase>
<lsm_usecase>
<param capture_device="HEADSET" />
<param adm_cfg_profile="FFECNS" />
<param fluence_type="FLUENCE_MIC" />
<param execution_mode="ADSP" />
<param app_type="2" /> <!-- app type used in ACDB -->
<param in_channels="1"/> <!-- Module input channels -->
<param load_sound_model_ids="0x00012C1C, 0x0, 0x00012C14" />
<param unload_sound_model_ids="0x00012C1C, 0x0, 0x00012C15" />
<param confidence_levels_ids="0x00012C1C, 0x0, 0x00012C07" />
<param operation_mode_ids="0x00012C1C, 0x0, 0x00012C02" />
<param polling_enable_ids="0x00012C1C, 0x0, 0x00012C1B" />
<param custom_config_ids="0x00012C1C, 0x0, 0x00012C20" />
<param det_event_type_ids="0x00012C1C, 0x0, 0x00012C2C" />
<param lab_dam_cfg_ids="0x00012C08, 0x0, 0x000102C4" />
</lsm_usecase>
<!-- format: "ADPCM_packet" or "PCM_packet" !-->
<!-- transfer_mode: "FTRT" or "RT" -->
<!-- kw_duration is in milli seconds. It is valid only for FTRT
transfer mode -->
<param capture_keyword="PCM_packet, RT, 2000" />
<param client_capture_read_delay="2000" />
</sound_model_config>
<!-- QTI Music Detection !-->
<sound_model_config>
<param vendor_uuid="876c1b46-9d4d-40cc-a4fd-4d5ec7a80e47" />
<param execution_type="ADSP" />
<param max_ape_phrases="1" />
<param max_ape_users="1" />
<!-- Profile specific data which the algorithm can support -->
<param sample_rate="16000" />
<param bit_width="16" />
<param out_channels="1"/> <!-- Module output channels -->
<!-- Module and param ids with which the algorithm is integrated
in non-graphite firmware (note these must come after gcs params)
Extends flexibility to have different ids based on execution type.
valid execution_type values: only "ADSP" -->
<lsm_usecase>
<param capture_device="HANDSET" />
<!-- adm_cfg_profile should match with the one defined under adm_config -->
<!-- Set it to NONE if LSM directly connects to AFE -->
<param adm_cfg_profile="DEFAULT" />
<!-- fluence_type: "FLUENCE_MIC", "FLUENCE_DMIC", "FLUENCE_TMIC" -->
<!-- "FLUENCE_QMIC". Param value is valid when adm_cfg_profile -->
<!-- is FFECNS -->
<param fluence_type="NONE" />
<param execution_mode="ADSP" />
<param app_type="4" /> <!-- app type for MD used in ACDB -->
<param in_channels="1"/> <!-- Module input channels -->
<param load_sound_model_ids="0x00012C22, 0x0, 0x00012C14" />
<param unload_sound_model_ids="0x00012C22, 0x0, 0x00012C15" />
<param confidence_levels_ids="0x00012C22, 0x0, 0x00012C07" />
<param det_event_type_ids="0x00012C22, 0x0, 0x00012C2C" />
<param custom_config_ids="0x00012C22, 0x0, 0x00012C30" />
</lsm_usecase>
<lsm_usecase>
<param capture_device="HEADSET" />
<param adm_cfg_profile="DEFAULT" />
<param fluence_type="NONE" />
<param execution_mode="ADSP" />
<param app_type="4" /> <!-- app type for MD used in ACDB -->
<param in_channels="1"/> <!-- Module input channels -->
<param load_sound_model_ids="0x00012C22, 0x0, 0x00012C14" />
<param unload_sound_model_ids="0x00012C22, 0x0, 0x00012C15" />
<param confidence_levels_ids="0x00012C22, 0x0, 0x00012C07" />
<param det_event_type_ids="0x00012C22, 0x0, 0x00012C2C" />
<param custom_config_ids="0x00012C22, 0x0, 0x00012C30" />
</lsm_usecase>
<!-- format: "ADPCM_packet" or "PCM_packet" !-->
<!-- transfer_mode: "FTRT" or "RT" -->
<!-- kw_duration is in milli seconds. It is valid only for FTRT
transfer mode -->
<param capture_keyword="PCM_packet, FTRT, 1500" />
<param client_capture_read_delay="2000" />
</sound_model_config>
<!-- Google Hotword -->
<sound_model_config>
<param vendor_uuid="7038ddc8-30f2-11e6-b0ac-40a8f03d3f15" />
<param execution_type="ADSP" />
<param max_ape_phrases="1" />
<param max_ape_users="1" />
<!-- Profile specific data which the algorithm can support -->
<param sample_rate="16000" />
<param bit_width="16" />
<param out_channels="1"/> <!-- Module output channels -->
<lsm_usecase>
<param capture_device="HANDSET" />
<!-- adm_cfg_profile should match with the one defined under adm_config -->
<!-- Set it to NONE if LSM directly connects to AFE -->
<param adm_cfg_profile="DEFAULT" />
<!-- fluence_type: "FLUENCE_MIC", "FLUENCE_DMIC", "FLUENCE_TMIC" -->
<!-- "FLUENCE_QMIC". Param value is valid when adm_cfg_profile -->
<!-- is FFECNS -->
<param fluence_type="NONE" />
<param execution_mode="ADSP" />
<param app_type="3" /> <!-- app type used in ACDB -->
<param in_channels="1"/> <!-- Module input channels -->
<param load_sound_model_ids="0x18000001, 0x0, 0x00012C14" />
<param unload_sound_model_ids="0x18000001, 0x0, 0x00012C15" />
<param confidence_levels_ids="0x18000001, 0x0, 0x00012C07" />
<param operation_mode_ids="0x18000001, 0x0, 0x00012C02" />
<param polling_enable_ids="0x18000001, 0x0, 0x00012C1B" />
<param custom_config_ids="0x18000001, 0x0, 0x00012C20" />
</lsm_usecase>
<lsm_usecase>
<param capture_device="HEADSET" />
<param adm_cfg_profile="DEFAULT" />
<param fluence_type="NONE" />
<param execution_mode="ADSP" />
<param app_type="3" /> <!-- app type used in ACDB -->
<param in_channels="1"/> <!-- Module input channels -->
<param load_sound_model_ids="0x18000001, 0x0, 0x00012C14" />
<param unload_sound_model_ids="0x18000001, 0x0, 0x00012C15" />
<param confidence_levels_ids="0x18000001, 0x0, 0x00012C07" />
<param operation_mode_ids="0x18000001, 0x0, 0x00012C02" />
<param polling_enable_ids="0x18000001, 0x0, 0x00012C1B" />
<param custom_config_ids="0x18000001, 0x0, 0x00012C20" />
</lsm_usecase>
<!-- format: "ADPCM_packet" or "PCM_packet" !-->
<!-- transfer_mode: "FTRT" or "RT" -->
<!-- kw_duration is in milli seconds. It is valid only for FTRT
transfer mode -->
<param capture_keyword="PCM_raw, FTRT, 2000" />
<param client_capture_read_delay="2000" />
</sound_model_config>
<!-- Google Music Detection -->
<sound_model_config>
<param vendor_uuid="9f6ad62a-1f0b-11e7-87c5-40a8f03d3f15" />
<param execution_type="ADSP" />
<param max_ape_phrases="1" />
<param max_ape_users="1" />
<!-- Profile specific data which the algorithm can support -->
<param sample_rate="16000" />
<param bit_width="16" />
<param out_channels="1"/> <!-- Module output channels -->
<lsm_usecase>
<param capture_device="HANDSET" />
<!-- adm_cfg_profile should match with the one defined under adm_config -->
<!-- Set it to NONE if LSM directly connects to AFE -->
<param adm_cfg_profile="DEFAULT" />
<!-- fluence_type: "FLUENCE_MIC", "FLUENCE_DMIC", "FLUENCE_TMIC" -->
<!-- "FLUENCE_QMIC". Param value is valid when adm_cfg_profile -->
<!-- is FFECNS -->
<param fluence_type="NONE" />
<param execution_mode="ADSP" />
<param app_type="3" /> <!-- app type used in ACDB -->
<param in_channels="1"/> <!-- Module input channels -->
<param load_sound_model_ids="0x18000001, 0x0, 0x00012C14" />
<param unload_sound_model_ids="0x18000001, 0x0, 0x00012C15" />
<param confidence_levels_ids="0x18000001, 0x0, 0x00012C07" />
<param operation_mode_ids="0x18000001, 0x0, 0x00012C02" />
<param polling_enable_ids="0x18000001, 0x0, 0x00012C1B" />
<param custom_config_ids="0x18000001, 0x0, 0x00012C20" />
</lsm_usecase>
<lsm_usecase>
<param capture_device="HEADSET" />
<param adm_cfg_profile="DEFAULT" />
<param fluence_type="NONE" />
<param execution_mode="ADSP" />
<param app_type="3" /> <!-- app type used in ACDB -->
<param in_channels="1"/> <!-- Module input channels -->
<param load_sound_model_ids="0x18000001, 0x0, 0x00012C14" />
<param unload_sound_model_ids="0x18000001, 0x0, 0x00012C15" />
<param confidence_levels_ids="0x18000001, 0x0, 0x00012C07" />
<param operation_mode_ids="0x18000001, 0x0, 0x00012C02" />
<param polling_enable_ids="0x18000001, 0x0, 0x00012C1B" />
<param custom_config_ids="0x18000001, 0x0, 0x00012C20" />
</lsm_usecase>
<!-- format: "ADPCM_packet" or "PCM_packet" !-->
<!-- transfer_mode: "FTRT" or "RT" -->
<!-- kw_duration is in milli seconds. It is valid only for FTRT
transfer mode -->
<param capture_keyword="PCM_raw, FTRT, 5000" />
<param client_capture_read_delay="2000" />
</sound_model_config>
<!-- Multiple adm_config tags can be listed, each with unique profile name. -->
<!-- app_type to match corresponding value from ACDB -->
<adm_config>
<param adm_cfg_profile="FFECNS" />
<param app_type="69947" />
<param sample_rate="16000" />
<param bit_width="16" />
<param out_channels="3"/>
</adm_config>
<adm_config>
<param adm_cfg_profile="DEFAULT" />
<param app_type="69938" />
<param sample_rate="16000" />
<param bit_width="16" />
<param out_channels="1"/>
</adm_config>
</sound_trigger_platform_info>

View File

@ -0,0 +1,31 @@
/*
* Copyright (c) 2013, The Linux Foundation. All rights reserved.
* Not a Contribution, Apache license notifications and license are retained
* for attribution purposes only.
*
* Copyright (C) 2012 The Android Open Source Project
* Copyright (C) 2018, 2022 The LineageOS Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef _BDROID_BUILDCFG_H
#define _BDROID_BUILDCFG_H
// Disables read remote device feature
#define MAX_ACL_CONNECTIONS 16
#define MAX_L2CAP_CHANNELS 16
#define BLE_VND_INCLUDED TRUE
/* Increasing SEPs to 12 from 6 to support SHO/MCast i.e. two streams per codec */
#define AVDT_NUM_SEPS 12
#endif

82
compatibility_matrix.xml Normal file
View File

@ -0,0 +1,82 @@
<compatibility-matrix version="2.0" type="device">
<hal format="hidl" optional="false">
<name>android.frameworks.schedulerservice</name>
<version>1.0</version>
<interface>
<name>ISchedulingPolicyService</name>
<instance>default</instance>
</interface>
</hal>
<hal format="hidl" optional="false">
<name>android.frameworks.sensorservice</name>
<version>1.0</version>
<interface>
<name>ISensorManager</name>
<instance>default</instance>
</interface>
</hal>
<hal format="hidl" optional="false">
<name>android.hidl.allocator</name>
<version>1.0</version>
<interface>
<name>IAllocator</name>
<instance>ashmem</instance>
</interface>
</hal>
<hal format="hidl" optional="false">
<name>android.hidl.manager</name>
<version>1.0</version>
<interface>
<name>IServiceManager</name>
<instance>default</instance>
</interface>
</hal>
<hal format="hidl" optional="false">
<name>android.hidl.memory</name>
<version>1.0</version>
<interface>
<name>IMapper</name>
<instance>ashmem</instance>
</interface>
</hal>
<hal format="hidl" optional="false">
<name>android.hidl.token</name>
<version>1.0</version>
<interface>
<name>ITokenManager</name>
<instance>default</instance>
</interface>
</hal>
<hal format="hidl" optional="false">
<name>android.system.wifi.keystore</name>
<version>1.0</version>
<interface>
<name>IKeystore</name>
<instance>default</instance>
</interface>
</hal>
<hal format="hidl" optional="true">
<name>vendor.qti.hardware.qccsyshal</name>
<version>1.0</version>
<interface>
<name>IQccsyshal</name>
<instance>qccsyshal</instance>
</interface>
</hal>
<hal format="hidl" optional="true">
<name>vendor.qti.hardware.sigma_miracast</name>
<version>1.0</version>
<interface>
<name>Isigma_miracast</name>
<instance>sigmahal</instance>
</interface>
</hal>
<hal format="hidl" optional="true">
<name>vendor.qti.hardware.wifi.keystore</name>
<version>1.0</version>
<interface>
<name>IKeystoreExt</name>
<instance>default</instance>
</interface>
</hal>
</compatibility-matrix>

92
config.fs Normal file
View File

@ -0,0 +1,92 @@
[AID_VENDOR_QTI_DIAG]
value:2901
[AID_VENDOR_QDSS]
value:2902
[AID_VENDOR_RFS]
value:2903
[AID_VENDOR_RFS_SHARED]
value:2904
[AID_VENDOR_ADPL_ODL]
value:2905
[AID_VENDOR_QRTR]
value:2906
[AID_VENDOR_THERMAL]
value:2907
[vendor/bin/hw/android.hardware.bluetooth@1.0-service-qti]
mode: 0755
user: AID_BLUETOOTH
group: AID_BLUETOOTH
caps: BLOCK_SUSPEND NET_ADMIN
[vendor/bin/pm-service]
mode: 0755
user: AID_SYSTEM
group: AID_SYSTEM
caps: NET_BIND_SERVICE SYS_BOOT
[vendor/bin/pd-mapper]
mode: 0755
user: AID_SYSTEM
group: AID_SYSTEM
caps: NET_BIND_SERVICE
[vendor/bin/imsdatadaemon]
mode: 0755
user: AID_RADIO
group: AID_RADIO
caps: NET_BIND_SERVICE
[vendor/bin/ims_rtp_daemon]
mode: 0755
user: AID_RADIO
group: AID_RADIO
caps: NET_BIND_SERVICE
[vendor/bin/imsrcsd]
mode: 0755
user: AID_RADIO
group: AID_RADIO
caps: NET_BIND_SERVICE BLOCK_SUSPEND WAKE_ALARM
[vendor/bin/cnd]
mode: 0755
user: AID_SYSTEM
group: AID_SYSTEM
caps: NET_BIND_SERVICE BLOCK_SUSPEND NET_ADMIN
[vendor/bin/slim_daemon]
mode: 0755
user: AID_GPS
group: AID_GPS
caps: NET_BIND_SERVICE
[vendor/bin/loc_launcher]
mode: 0755
user: AID_GPS
group: AID_GPS
caps: SETUID SETGID
[vendor/bin/xtwifi-client]
mode: 0755
user: AID_GPS
group: AID_GPS
caps: NET_BIND_SERVICE BLOCK_SUSPEND WAKE_ALARM
[vendor/bin/sensors.qti]
mode: 0755
user: AID_SYSTEM
group: AID_SYSTEM
caps: NET_BIND_SERVICE
[vendor/firmware_mnt/image/*]
mode: 0771
user: AID_SYSTEM
group: AID_SYSTEM
caps: 0

View File

@ -0,0 +1,21 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2019 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<config>
<component-override package="com.android.bluetooth" >
<component class=".avrcpcontroller.AvrcpControllerService" enabled="true" />
<component class=".sap.SapService" enabled="true" />
</component-override>
</config>

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (c) 2018, 2020 The Linux Foundation. All rights reserved. -->
<!-- -->
<!-- Redistribution and use in source and binary forms, with or without -->
<!-- modification, are permitted provided that the following conditions are -->
<!-- met: -->
<!-- * Redistributions of source code must retain the above copyright -->
<!-- notice, this list of conditions and the following disclaimer. -->
<!-- * Redistributions in binary form must reproduce the above -->
<!-- copyright notice, this list of conditions and the following -->
<!-- disclaimer in the documentation and/or other materials provided -->
<!-- with the distribution. -->
<!-- * Neither the name of The Linux Foundation nor the names of its -->
<!-- contributors may be used to endorse or promote products derived -->
<!-- from this software without specific prior written permission. -->
<!-- -->
<!-- THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED -->
<!-- WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -->
<!-- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT -->
<!-- ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS -->
<!-- BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -->
<!-- CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF -->
<!-- SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR -->
<!-- BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -->
<!-- WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE -->
<!-- OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN -->
<!-- IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -->
<devices>
<device name="qti-haptics"/>
<device name="qcom-hv-haptics"/>
<device name="drv2624:haptics"/>
<device name="aw8624_haptic"/>
</devices>

354
configs/powerhint.json Normal file
View File

@ -0,0 +1,354 @@
{
"Nodes": [
{
"Name": "CPULittleClusterMaxFreq",
"Path": "/sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq",
"Values": [
"9999999",
"1324800"
],
"DefaultIndex": 0,
"ResetOnInit": true
},
{
"Name": "CPULittleClusterMinFreq",
"Path": "/sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq",
"Values": [
"9999999",
"1708800",
"1324800",
"576000"
],
"ResetOnInit": true
},
{
"Name": "CPUBigClusterMaxFreq",
"Path": "/sys/devices/system/cpu/cpu6/cpufreq/scaling_max_freq",
"Values": [
"9999999",
"1555200"
],
"DefaultIndex": 0,
"ResetOnInit": true
},
{
"Name": "CPUBigClusterMinFreq",
"Path": "/sys/devices/system/cpu/cpu6/cpufreq/scaling_min_freq",
"Values": [
"9999999",
"1900800",
"825600",
"652800"
],
"ResetOnInit": true
},
{
"Name": "GPUMaxFreq",
"Path": "/sys/class/kgsl/kgsl-3d0/max_pwrlevel",
"Values": [
"0",
"3"
],
"DefaultIndex": 0,
"ResetOnInit": true
},
{
"Name": "GPUMinFreq",
"Path": "/sys/class/kgsl/kgsl-3d0/min_pwrlevel",
"Values": [
"0",
"5"
],
"ResetOnInit": true
},
{
"Name": "GPUForceRailOn",
"Path": "/sys/class/kgsl/kgsl-3d0/force_rail_on",
"Values": [
"1",
"0"
],
"ResetOnInit": true
},
{
"Name": "GPUForceClkOn",
"Path": "/sys/class/kgsl/kgsl-3d0/force_clk_on",
"Values": [
"1",
"0"
],
"ResetOnInit": true
},
{
"Name": "GPUIdleTimer",
"Path": "/sys/class/kgsl/kgsl-3d0/idle_timer",
"Values": [
"10000",
"80"
],
"ResetOnInit": true
},
{
"Name": "CPUBWHystTriggerCount",
"Path": "/sys/class/devfreq/soc:qcom,cpu-cpu-llcc-bw/bw_hwmon/hyst_trigger_count",
"Values": [
"0",
"3"
],
"ResetOnInit": true
},
{
"Name": "CPUBWHistMemory",
"Path": "/sys/class/devfreq/soc:qcom,cpu-cpu-llcc-bw/bw_hwmon/hist_memory",
"Values": [
"0",
"20"
],
"ResetOnInit": true
},
{
"Name": "CPUBWHystLength",
"Path": "/sys/class/devfreq/soc:qcom,cpu-cpu-llcc-bw/bw_hwmon/hyst_length",
"Values": [
"0",
"10"
],
"ResetOnInit": true
},
{
"Name": "CPUBWMinFreq",
"Path": "/sys/class/devfreq/soc:qcom,cpu-cpu-llcc-bw/min_freq",
"Values": [
"14236",
"9155",
"4577"
],
"ResetOnInit": true
},
{
"Name": "LLCCBWMinFreq",
"Path": "/sys/class/devfreq/soc:qcom,cpu-llcc-ddr-bw/min_freq",
"Values": [
"6881",
"2929",
"1144"
],
"ResetOnInit": true
},
{
"Name": "L3LittleClusterMinFreq",
"Path": "/sys/class/devfreq/soc:qcom,cpu0-cpu-l3-lat/min_freq",
"Values": [
"1459200000",
"300000000"
],
"ResetOnInit": true
},
{
"Name": "L3BigClusterMinFreq",
"Path": "/sys/class/devfreq/soc:qcom,cpu6-cpu-l3-lat/min_freq",
"Values": [
"1459200000",
"300000000"
],
"ResetOnInit": true
},
{
"Name": "PowerHALMainState",
"Path": "vendor.powerhal.state",
"Values": [
"SUSTAINED_PERFORMANCE",
""
],
"Type": "Property"
},
{
"Name": "PowerHALAudioState",
"Path": "vendor.powerhal.audio",
"Values": [
"AUDIO_STREAMING_LOW_LATENCY",
""
],
"Type": "Property"
},
{
"Name": "PowerHALRenderingState",
"Path": "vendor.powerhal.rendering",
"Values": [
"EXPENSIVE_RENDERING",
""
],
"Type": "Property"
}
],
"Actions": [
{
"PowerHint": "SUSTAINED_PERFORMANCE",
"Node": "PowerHALMainState",
"Duration": 0,
"Value": "SUSTAINED_PERFORMANCE"
},
{
"PowerHint": "SUSTAINED_PERFORMANCE",
"Node": "CPUBigClusterMaxFreq",
"Duration": 0,
"Value": "1555200"
},
{
"PowerHint": "SUSTAINED_PERFORMANCE",
"Node": "CPULittleClusterMaxFreq",
"Duration": 0,
"Value": "1324800"
},
{
"PowerHint": "SUSTAINED_PERFORMANCE",
"Node": "GPUMaxFreq",
"Duration": 0,
"Value": "3"
},
{
"PowerHint": "INTERACTION",
"Node": "CPUBigClusterMinFreq",
"Duration": 0,
"Value": "825600"
},
{
"PowerHint": "INTERACTION",
"Node": "CPULittleClusterMinFreq",
"Duration": 0,
"Value": "1324800"
},
{
"PowerHint": "INTERACTION",
"Node": "CPUBWHystTriggerCount",
"Duration": 0,
"Value": "0"
},
{
"PowerHint": "INTERACTION",
"Node": "CPUBWHystLength",
"Duration": 0,
"Value": "0"
},
{
"PowerHint": "INTERACTION",
"Node": "CPUBWHistMemory",
"Duration": 0,
"Value": "0"
},
{
"PowerHint": "INTERACTION",
"Node": "CPUBWMinFreq",
"Duration": 0,
"Value": "9155"
},
{
"PowerHint": "INTERACTION",
"Node": "LLCCBWMinFreq",
"Duration": 0,
"Value": "2929"
},
{
"PowerHint": "LAUNCH",
"Node": "CPUBigClusterMaxFreq",
"Duration": 5000,
"Value": "9999999"
},
{
"PowerHint": "LAUNCH",
"Node": "CPUBigClusterMinFreq",
"Duration": 5000,
"Value": "1900800"
},
{
"PowerHint": "LAUNCH",
"Node": "CPULittleClusterMinFreq",
"Duration": 5000,
"Value": "1708800"
},
{
"PowerHint": "LAUNCH",
"Node": "CPUBWHystTriggerCount",
"Duration": 5000,
"Value": "0"
},
{
"PowerHint": "LAUNCH",
"Node": "CPUBWHystLength",
"Duration": 5000,
"Value": "0"
},
{
"PowerHint": "LAUNCH",
"Node": "CPUBWHistMemory",
"Duration": 5000,
"Value": "0"
},
{
"PowerHint": "LAUNCH",
"Node": "CPUBWMinFreq",
"Duration": 5000,
"Value": "14236"
},
{
"PowerHint": "LAUNCH",
"Node": "GPUForceClkOn",
"Duration": 5000,
"Value": "1"
},
{
"PowerHint": "LAUNCH",
"Node": "GPUForceRailOn",
"Duration": 5000,
"Value": "1"
},
{
"PowerHint": "LAUNCH",
"Node": "GPUIdleTimer",
"Duration": 5000,
"Value": "10000"
},
{
"PowerHint": "LAUNCH",
"Node": "LLCCBWMinFreq",
"Duration": 5000,
"Value": "6881"
},
{
"PowerHint": "LAUNCH",
"Node": "L3LittleClusterMinFreq",
"Duration": 5000,
"Value": "1459200000"
},
{
"PowerHint": "LAUNCH",
"Node": "L3BigClusterMinFreq",
"Duration": 5000,
"Value": "1459200000"
},
{
"PowerHint": "AUDIO_STREAMING_LOW_LATENCY",
"Node": "PowerHALAudioState",
"Duration": 0,
"Value": "AUDIO_STREAMING_LOW_LATENCY"
},
{
"PowerHint": "EXPENSIVE_RENDERING",
"Node": "PowerHALRenderingState",
"Duration": 0,
"Value": "EXPENSIVE_RENDERING"
},
{
"PowerHint": "EXPENSIVE_RENDERING",
"Node": "GPUMinFreq",
"Duration": 0,
"Value": "0"
},
{
"PowerHint": "EXPENSIVE_RENDERING",
"Node": "GPUMaxFreq",
"Duration": 0,
"Value": "0"
}
]
}

View File

@ -0,0 +1,242 @@
{
"Sensors":[
{
"Name":"cpu-0-0-usr",
"Type":"CPU",
"HotThreshold":[
"NAN",
"NAN",
"NAN",
95.0,
"NAN",
"NAN",
125.0
],
"VrThreshold":"NAN",
"Multiplier":0.001
},
{
"Name":"cpu-0-1-usr",
"Type":"CPU",
"HotThreshold":[
"NAN",
"NAN",
"NAN",
95.0,
"NAN",
"NAN",
125.0
],
"VrThreshold":"NAN",
"Multiplier":0.001
},
{
"Name":"cpu-0-2-usr",
"Type":"CPU",
"HotThreshold":[
"NAN",
"NAN",
"NAN",
95.0,
"NAN",
"NAN",
125.0
],
"VrThreshold":"NAN",
"Multiplier":0.001
},
{
"Name":"cpu-0-3-usr",
"Type":"CPU",
"HotThreshold":[
"NAN",
"NAN",
"NAN",
95.0,
"NAN",
"NAN",
125.0
],
"VrThreshold":"NAN",
"Multiplier":0.001
},
{
"Name":"cpu-0-4-usr",
"Type":"CPU",
"HotThreshold":[
"NAN",
"NAN",
"NAN",
95.0,
"NAN",
"NAN",
125.0
],
"VrThreshold":"NAN",
"Multiplier":0.001
},
{
"Name":"cpu-0-5-usr",
"Type":"CPU",
"HotThreshold":[
"NAN",
"NAN",
"NAN",
95.0,
"NAN",
"NAN",
125.0
],
"VrThreshold":"NAN",
"Multiplier":0.001
},
{
"Name":"cpu-1-0-usr",
"Type":"CPU",
"HotThreshold":[
"NAN",
"NAN",
"NAN",
95.0,
"NAN",
"NAN",
125.0
],
"VrThreshold":"NAN",
"Multiplier":0.001
},
{
"Name":"cpu-1-1-usr",
"Type":"CPU",
"HotThreshold":[
"NAN",
"NAN",
"NAN",
95.0,
"NAN",
"NAN",
125.0
],
"VrThreshold":"NAN",
"Multiplier":0.001
},
{
"Name":"cpu-1-2-usr",
"Type":"CPU",
"HotThreshold":[
"NAN",
"NAN",
"NAN",
95.0,
"NAN",
"NAN",
125.0
],
"VrThreshold":"NAN",
"Multiplier":0.001
},
{
"Name":"cpu-1-3-usr",
"Type":"CPU",
"HotThreshold":[
"NAN",
"NAN",
"NAN",
95.0,
"NAN",
"NAN",
125.0
],
"VrThreshold":"NAN",
"Multiplier":0.001
},
{
"Name":"gpuss-0-usr",
"Type":"GPU",
"HotThreshold":[
"NAN",
"NAN",
"NAN",
95.0,
"NAN",
"NAN",
125.0
],
"VrThreshold":"NAN",
"Multiplier":0.001
},
{
"Name":"gpuss-1-usr",
"Type":"GPU",
"HotThreshold":[
"NAN",
"NAN",
"NAN",
95.0,
"NAN",
"NAN",
125.0
],
"VrThreshold":"NAN",
"Multiplier":0.001
},
{
"Name":"battery",
"Type":"BATTERY",
"HotThreshold":[
"NAN",
"NAN",
"NAN",
"NAN",
"NAN",
"NAN",
60.0
],
"VrThreshold":"NAN",
"Multiplier":0.001
},
{
"Name":"quiet-therm-usr",
"Type":"SKIN",
"HotThreshold":[
"NAN",
43.0,
45.0,
48.0,
50.0,
54.0,
58.0
],
"HotHysteresis":[
0.0,
1.9,
1.9,
1.9,
1.9,
1.9,
1.9
],
"VrThreshold":"NAN",
"Multiplier":0.001,
"Monitor":true
}
],
"CoolingDevices":[
{
"Name":"thermal-cpufreq-0",
"Type":"CPU"
},
{
"Name":"thermal-cpufreq-7",
"Type":"CPU"
},
{
"Name":"thermal-devfreq-0",
"Type":"GPU"
},
{
"Name":"battery",
"Type":"BATTERY"
}
]
}

434
device.mk
View File

@ -4,8 +4,233 @@
# SPDX-License-Identifier: Apache-2.0
#
# Inherit from sm6250-common
$(call inherit-product, device/xiaomi/sm6250-common/atoll.mk)
# Enable project quotas and casefolding for emulated storage without sdcardfs
$(call inherit-product, $(SRC_TARGET_DIR)/product/emulated_storage.mk)
# Enable updating of APEXes
$(call inherit-product, $(SRC_TARGET_DIR)/product/updatable_apex.mk)
# Include GSI keys
$(call inherit-product, $(SRC_TARGET_DIR)/product/gsi_keys.mk)
# Setup dalvik vm configs
$(call inherit-product, frameworks/native/build/phone-xhdpi-4096-dalvik-heap.mk)
# AAPT
PRODUCT_AAPT_CONFIG := normal
PRODUCT_AAPT_PREF_CONFIG := xxhdpi
# Audio
PRODUCT_PACKAGES += \
android.hardware.audio@6.0-impl \
android.hardware.audio.effect@6.0-impl \
android.hardware.audio.service \
android.hardware.bluetooth.audio@2.1-impl \
android.hardware.soundtrigger@2.2-impl
PRODUCT_PACKAGES += \
audio.bluetooth.default \
audio.primary.atoll \
audio.r_submix.default \
audio.usb.default \
PRODUCT_PACKAGES += \
liba2dpoffload \
libbatterylistener \
libcomprcapture \
libexthwplugin \
libhdmiedid \
libhfp \
libqcompostprocbundle \
libqcomvisualizer \
libqcomvoiceprocessing \
libsndmonitor \
libspkrprot \
libssrec \
libvolumelistener \
sound_trigger.primary.atoll:32
PRODUCT_COPY_FILES += \
$(call find-copy-subdir-files,*,$(LOCAL_PATH)/audio/,$(TARGET_COPY_OUT_VENDOR)/etc)
PRODUCT_COPY_FILES += \
frameworks/av/services/audiopolicy/config/audio_policy_volumes.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_volumes.xml \
frameworks/av/services/audiopolicy/config/default_volume_tables.xml:$(TARGET_COPY_OUT_VENDOR)/etc/default_volume_tables.xml \
frameworks/av/services/audiopolicy/config/r_submix_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/r_submix_audio_policy_configuration.xml
# Bluetooth
PRODUCT_PACKAGES += \
android.hardware.bluetooth@1.1.vendor \
vendor.qti.hardware.bluetooth_audio@2.1.vendor \
vendor.qti.hardware.btconfigstore@1.0.vendor \
vendor.qti.hardware.btconfigstore@2.0.vendor
# Camera
PRODUCT_PACKAGES += \
android.hardware.camera.provider@2.4-impl \
android.hardware.camera.provider@2.4-service_64 \
vendor.qti.hardware.camera.device@1.0.vendor
PRODUCT_PACKAGES += \
libMegviiFacepp-0.5.2 \
libmegface
PRODUCT_PACKAGES += \
libcamera2ndk_vendor \
libdng_sdk.vendor \
libgui_vendor \
libstdc++.vendor
# Component overrides
PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/configs/component-overrides.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sysconfig/component-overrides.xml
# DebugFS
PRODUCT_SET_DEBUGFS_RESTRICTIONS := true
# Display
PRODUCT_PACKAGES += \
android.hardware.graphics.composer@2.4-impl \
android.hardware.graphics.composer@2.4-service
PRODUCT_PACKAGES += \
android.hardware.graphics.mapper@3.0-impl-qti-display \
android.hardware.graphics.mapper@4.0-impl-qti-display
PRODUCT_PACKAGES += \
android.hardware.memtrack@1.0-impl \
android.hardware.memtrack@1.0-service \
memtrack.atoll
PRODUCT_PACKAGES += \
disable_configstore \
gralloc.atoll \
hwcomposer.atoll \
libdisplayconfig.qti \
libdisplayconfig.system.qti \
libqdMetaData \
libqdMetaData.system \
libsdmcore \
libsdmutils \
libtinyxml \
libvulkan \
vendor.display.config@1.5 \
vendor.display.config@1.11.vendor \
vendor.display.config@2.0 \
vendor.display.config@2.0.vendor \
vendor.qti.hardware.display.allocator-service \
vendor.qti.hardware.display.mapper@1.1.vendor \
vendor.qti.hardware.display.mapper@2.0.vendor \
vendor.qti.hardware.display.mapper@3.0.vendor \
vendor.qti.hardware.display.mapper@4.0.vendor
# DRM
PRODUCT_PACKAGES += \
android.hardware.drm@1.4-service.clearkey
PRODUCT_PACKAGES += \
android.hardware.drm@1.4.vendor
# Fastbootd
PRODUCT_PACKAGES += \
fastbootd
# Fingerprint
PRODUCT_PACKAGES += \
android.hardware.biometrics.fingerprint@2.3-service.xiaomi
# FM
PRODUCT_PACKAGES += \
FM2 \
libqcomfm_jni \
qcom.fmradio
# Gatekeeper
PRODUCT_PACKAGES += \
android.hardware.gatekeeper@1.0.vendor
# GPS
PRODUCT_PACKAGES += \
android.hardware.gnss@1.1.vendor \
android.hardware.gnss@2.1.vendor
# Health
PRODUCT_PACKAGES += \
android.hardware.health@2.1-impl \
android.hardware.health@2.1-service
# HIDL
PRODUCT_PACKAGES += \
libhwbinder.vendor
# HotwordEnrollement app permissions
PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/permissions/privapp-permissions-hotword.xml:$(TARGET_COPY_OUT_PRODUCT)/etc/permissions/privapp-permissions-hotword.xml
# Input
PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/idc/uinput-fpc.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/uinput-fpc.idc \
$(LOCAL_PATH)/idc/uinput-goodix.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/uinput-goodix.idc
PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/keylayout/gpio-keys.kl:$(TARGET_COPY_OUT_VENDOR)/usr/keylayout/gpio-keys.kl \
$(LOCAL_PATH)/keylayout/uinput-fpc.kl:$(TARGET_COPY_OUT_VENDOR)/usr/keylayout/uinput-fpc.kl \
$(LOCAL_PATH)/keylayout/uinput-goodix.kl:$(TARGET_COPY_OUT_VENDOR)/usr/keylayout/uinput-goodix.kl
# IPACM
PRODUCT_PACKAGES += \
ipacm \
IPACM_cfg.xml
# IR
PRODUCT_PACKAGES += \
android.hardware.ir@1.0-impl \
android.hardware.ir@1.0-service
# Keymaster
PRODUCT_PACKAGES += \
android.hardware.keymaster@4.1.vendor
# Lights
PRODUCT_PACKAGES += \
android.hardware.light-service.xiaomi
# LiveDisplay
PRODUCT_PACKAGES += \
vendor.lineage.livedisplay@2.0-service-sdm
# Media
PRODUCT_PACKAGES += \
libavservices_minijail \
libavservices_minijail.vendor \
libcodec2_hidl@1.0.vendor \
libcodec2_vndk.vendor
PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/media/media_codecs.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs.xml \
$(LOCAL_PATH)/media/media_codecs_performance.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_performance.xml \
$(LOCAL_PATH)/media/media_codecs_vendor.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_vendor.xml \
$(LOCAL_PATH)/media/media_codecs_vendor_audio.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_vendor_audio.xml \
$(LOCAL_PATH)/media/media_profiles.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_profiles.xml \
$(LOCAL_PATH)/media/media_profiles_V1_0.xml:$(TARGET_COPY_OUT_ODM)/etc/media_profiles_V1_0.xml \
$(LOCAL_PATH)/media/media_profiles_vendor.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_profiles_vendor.xml
PRODUCT_COPY_FILES += \
frameworks/av/media/libstagefright/data/media_codecs_google_audio.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_audio.xml \
frameworks/av/media/libstagefright/data/media_codecs_google_c2.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_c2.xml \
frameworks/av/media/libstagefright/data/media_codecs_google_c2_audio.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_c2_audio.xml \
frameworks/av/media/libstagefright/data/media_codecs_google_c2_video.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_c2_video.xml \
frameworks/av/media/libstagefright/data/media_codecs_google_telephony.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_telephony.xml \
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_video_le.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_video_le.xml
# Net
PRODUCT_PACKAGES += \
android.system.net.netd@1.1.vendor \
# Neural networks
PRODUCT_PACKAGES += \
android.hardware.neuralnetworks@1.3.vendor
# NFC
PRODUCT_PACKAGES += \
@ -26,20 +251,221 @@ PRODUCT_COPY_FILES += \
frameworks/native/data/etc/com.android.nfc_extras.xml:$(TARGET_COPY_OUT_ODM)/etc/permissions/sku_nfc/com.android.nfc_extras.xml \
frameworks/native/data/etc/com.nxp.mifare.xml:$(TARGET_COPY_OUT_ODM)/etc/permissions/sku_nfc/com.nxp.mifare.xml
# OMX
PRODUCT_PACKAGES += \
libOmxAacEnc \
libOmxAmrEnc \
libOmxCore \
libOmxEvrcEnc \
libOmxG711Enc \
libOmxQcelp13Enc \
libOmxVdec \
libOmxVenc \
libstagefrighthw
# Overlays
PRODUCT_ENFORCE_RRO_TARGETS := *
PRODUCT_PACKAGES += \
CarrierConfigResCommon \
SM6250Frameworks \
SM6250SystemUI \
TelephonyResCommon \
WifiOverlay
PRODUCT_PACKAGES += \
SM6250LineageDialer \
SM6250LineageSDK
# Partitions
PRODUCT_USE_DYNAMIC_PARTITIONS := true
# Perf
PRODUCT_PACKAGES += \
libqti-perfd-client
# Permissions
PRODUCT_COPY_FILES += \
frameworks/native/data/etc/android.hardware.audio.low_latency.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.audio.low_latency.xml \
frameworks/native/data/etc/android.hardware.audio.pro.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.audio.pro.xml \
frameworks/native/data/etc/android.hardware.bluetooth.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.bluetooth.xml \
frameworks/native/data/etc/android.hardware.bluetooth_le.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.bluetooth_le.xml \
frameworks/native/data/etc/android.hardware.camera.flash-autofocus.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.flash-autofocus.xml \
frameworks/native/data/etc/android.hardware.camera.front.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.front.xml \
frameworks/native/data/etc/android.hardware.camera.full.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.full.xml \
frameworks/native/data/etc/android.hardware.camera.raw.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.raw.xml \
frameworks/native/data/etc/android.hardware.consumerir.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.consumerir.xml \
frameworks/native/data/etc/android.hardware.fingerprint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.fingerprint.xml \
frameworks/native/data/etc/android.hardware.location.gps.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.location.gps.xml \
frameworks/native/data/etc/android.hardware.opengles.aep.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.opengles.aep.xml \
frameworks/native/data/etc/android.hardware.se.omapi.ese.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.ese.xml \
frameworks/native/data/etc/android.hardware.se.omapi.uicc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.uicc.xml \
frameworks/native/data/etc/android.hardware.sensor.accelerometer.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.accelerometer.xml \
frameworks/native/data/etc/android.hardware.sensor.compass.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.compass.xml \
frameworks/native/data/etc/android.hardware.sensor.gyroscope.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.gyroscope.xml \
frameworks/native/data/etc/android.hardware.sensor.light.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.light.xml \
frameworks/native/data/etc/android.hardware.sensor.proximity.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.proximity.xml \
frameworks/native/data/etc/android.hardware.sensor.stepcounter.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.stepcounter.xml \
frameworks/native/data/etc/android.hardware.sensor.stepdetector.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.stepdetector.xml \
frameworks/native/data/etc/android.hardware.telephony.cdma.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.telephony.cdma.xml \
frameworks/native/data/etc/android.hardware.telephony.gsm.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.telephony.gsm.xml \
frameworks/native/data/etc/android.hardware.telephony.ims.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.telephony.ims.xml \
frameworks/native/data/etc/android.hardware.touchscreen.multitouch.jazzhand.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.touchscreen.multitouch.jazzhand.xml \
frameworks/native/data/etc/android.hardware.usb.accessory.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.usb.accessory.xml \
frameworks/native/data/etc/android.hardware.usb.host.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.usb.host.xml \
frameworks/native/data/etc/android.hardware.vulkan.compute-0.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.compute-0.xml \
frameworks/native/data/etc/android.hardware.vulkan.level-1.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.level-1.xml \
frameworks/native/data/etc/android.hardware.vulkan.version-1_1.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.version-1_1.xml \
frameworks/native/data/etc/android.hardware.wifi.aware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.wifi.aware.xml \
frameworks/native/data/etc/android.hardware.wifi.direct.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.wifi.direct.xml \
frameworks/native/data/etc/android.hardware.wifi.passpoint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.wifi.passpoint.xml \
frameworks/native/data/etc/android.hardware.wifi.rtt.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.wifi.rtt.xml \
frameworks/native/data/etc/android.hardware.wifi.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.wifi.xml \
frameworks/native/data/etc/android.software.device_id_attestation.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.device_id_attestation.xml \
frameworks/native/data/etc/android.software.ipsec_tunnels.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.ipsec_tunnels.xml \
frameworks/native/data/etc/android.software.midi.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.midi.xml \
frameworks/native/data/etc/android.software.opengles.deqp.level-2020-03-01.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.opengles.deqp.level.xml \
frameworks/native/data/etc/android.software.sip.voip.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.sip.voip.xml \
frameworks/native/data/etc/android.software.verified_boot.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.verified_boot.xml \
frameworks/native/data/etc/android.software.vulkan.deqp.level-2020-03-01.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.vulkan.deqp.level.xml
# Power
PRODUCT_PACKAGES += \
android.hardware.power-service.xiaomi-libperfmgr
PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/configs/powerhint.json:$(TARGET_COPY_OUT_VENDOR)/etc/powerhint.json
# QMI
PRODUCT_PACKAGES += \
libjson \
libqti_vndfwk_detect.vendor \
libvndfwk_detect_jni.qti.vendor
# RIL
PRODUCT_PACKAGES += \
libprotobuf-cpp-full \
librmnetctl \
libxml2
PRODUCT_PACKAGES += \
android.hardware.radio@1.6.vendor \
android.hardware.radio.config@1.3.vendor \
android.hardware.radio.deprecated@1.0.vendor \
android.hardware.secure_element@1.2.vendor
# Rootdir
PRODUCT_PACKAGES += \
init.device.rc
init.qcom.early_boot.sh \
init.qcom.sh \
init.qti.chg_policy.sh
PRODUCT_PACKAGES += \
init.device.rc \
init.qcom.power.rc \
init.qcom.rc \
init.target.rc \
fstab.qcom \
ueventd.qcom.rc
PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/rootdir/etc/fstab.qcom:$(TARGET_COPY_OUT_RAMDISK)/fstab.qcom \
$(LOCAL_PATH)/rootdir/etc/init.recovery.qcom.rc:recovery/root/init.recovery.qcom.rc
# Sensors
PRODUCT_PACKAGES += \
android.hardware.sensors@2.1-service.multihal
PRODUCT_PACKAGES += \
libsensorndkbridge
# Shipping API level
PRODUCT_SHIPPING_API_LEVEL := 29
# Soong namespaces
PRODUCT_SOONG_NAMESPACES += \
$(LOCAL_PATH)
$(LOCAL_PATH) \
hardware/google/interfaces \
hardware/google/pixel \
hardware/xiaomi
# Telephony
PRODUCT_PACKAGES += \
ims-ext-common \
ims_ext_common.xml \
qti-telephony-hidl-wrapper \
qti_telephony_hidl_wrapper.xml \
qti-telephony-utils \
qti_telephony_utils.xml \
telephony-ext
PRODUCT_BOOT_JARS += \
telephony-ext
# Thermal
PRODUCT_PACKAGES += \
android.hardware.thermal@2.0-service.pixel \
thermal_symlinks
PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/configs/thermal_info_config.json:$(TARGET_COPY_OUT_VENDOR)/etc/thermal_info_config.json
PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/configs/thermal-engine-curtana.conf:$(TARGET_COPY_OUT_VENDOR)/etc/thermal-engine-curtana.conf \
$(LOCAL_PATH)/configs/thermal-engine-excalibur.conf:$(TARGET_COPY_OUT_VENDOR)/etc/thermal-engine-excalibur.conf \
$(LOCAL_PATH)/configs/thermal-engine-gram.conf:$(TARGET_COPY_OUT_VENDOR)/etc/thermal-engine-gram.conf \
$(LOCAL_PATH)/configs/thermal-engine-joyeuse.conf:$(TARGET_COPY_OUT_VENDOR)/etc/thermal-engine-joyeuse.conf
# Trust
PRODUCT_PACKAGES += \
vendor.lineage.trust@1.0-service
# USB
PRODUCT_PACKAGES += \
android.hardware.usb@1.0-service
PRODUCT_PACKAGES += \
init.qcom.usb.rc \
init.qcom.usb.sh
PRODUCT_SOONG_NAMESPACES += \
vendor/qcom/opensource/usb/etc
# Vendor service manager
PRODUCT_PACKAGES += \
vndservicemanager
# Vibrator
PRODUCT_PACKAGES += \
vendor.qti.hardware.vibrator.service
PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/configs/excluded-input-devices.xml:$(TARGET_COPY_OUT_VENDOR)/etc/excluded-input-devices.xml
# WiFi
PRODUCT_PACKAGES += \
android.hardware.wifi@1.0-service \
hostapd \
libwpa_client \
libwifi-hal-ctrl \
libwifi-hal-qcom \
vendor.qti.hardware.wifi.hostapd@1.2.vendor \
vendor.qti.hardware.wifi.supplicant@2.2.vendor \
wpa_supplicant \
wpa_supplicant.conf
PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/wifi/p2p_supplicant_overlay.conf:$(TARGET_COPY_OUT_VENDOR)/etc/wifi/p2p_supplicant_overlay.conf \
$(LOCAL_PATH)/wifi/wpa_supplicant_overlay.conf:$(TARGET_COPY_OUT_VENDOR)/etc/wifi/wpa_supplicant_overlay.conf \
$(LOCAL_PATH)/wifi/WCNSS_qcom_cfg.ini:$(TARGET_COPY_OUT_VENDOR)/etc/wifi/WCNSS_qcom_cfg.ini
# WiFi Display
PRODUCT_PACKAGES += \
libnl \
libwfdaac_vendor
PRODUCT_BOOT_JARS += \
WfdCommon
# Inherit proprietary targets
$(call inherit-product, vendor/xiaomi/miatoll/miatoll-vendor.mk)

View File

@ -0,0 +1,30 @@
<compatibility-matrix version="2.0" type="framework">
<hal format="hidl" optional="true">
<name>com.fingerprints.extension</name>
<version>1.0</version>
<interface>
<name>IFingerprintEngineering</name>
<instance>default</instance>
</interface>
<interface>
<name>IFingerprintNavigation</name>
<instance>default</instance>
</interface>
<interface>
<name>IFingerprintSensorTest</name>
<instance>default</instance>
</interface>
</hal>
<hal format="hidl" optional="true">
<name>vendor.goodix.hardware.biometrics.fingerprint</name>
<version>2.0-1</version>
<interface>
<name>IGoodixFingerprintDaemon</name>
<instance>default</instance>
</interface>
<interface>
<name>IGoodixFingerprintDaemonExt</name>
<instance>default</instance>
</interface>
</hal>
</compatibility-matrix>

View File

@ -1,20 +1,76 @@
#!/bin/bash
#
# Copyright (C) 2021 The LineageOS Project
# Copyright (C) 2016 The CyanogenMod Project
# Copyright (C) 2017-2020 The LineageOS Project
#
# SPDX-License-Identifier: Apache-2.0
#
# If we're being sourced by the common script that we called,
# stop right here. No need to go down the rabbit hole.
if [ "${BASH_SOURCE[0]}" != "${0}" ]; then
return
fi
set -e
export DEVICE=miatoll
export DEVICE_COMMON=sm6250-common
export VENDOR=xiaomi
DEVICE=miatoll
VENDOR=xiaomi
"./../../${VENDOR}/${DEVICE_COMMON}/extract-files.sh" "$@"
# Load extract_utils and do some sanity checks
MY_DIR="${BASH_SOURCE%/*}"
if [[ ! -d "${MY_DIR}" ]]; then MY_DIR="${PWD}"; fi
ANDROID_ROOT="${MY_DIR}/../../.."
HELPER="${ANDROID_ROOT}/tools/extract-utils/extract_utils.sh"
if [ ! -f "${HELPER}" ]; then
echo "Unable to find helper script at ${HELPER}"
exit 1
fi
source "${HELPER}"
# Default to sanitizing the vendor folder before extraction
CLEAN_VENDOR=true
KANG=
SECTION=
while [ "${#}" -gt 0 ]; do
case "${1}" in
-n | --no-cleanup )
CLEAN_VENDOR=false
;;
-k | --kang )
KANG="--kang"
;;
-s | --section )
SECTION="${2}"; shift
CLEAN_VENDOR=false
;;
* )
SRC="${1}"
;;
esac
shift
done
if [ -z "${SRC}" ]; then
SRC="adb"
fi
function blob_fixup() {
case "${1}" in
vendor/etc/init/android.hardware.keymaster@4.0-service-qti.rc)
sed -i "s/4\.0/4\.1/g" "${2}"
;;
system_ext/etc/init/wfdservice.rc)
sed -i "/^service/! s/wfdservice$/wfdservice64/g" "${2}"
;;
# Remove dependency on android.hidl.base@1.0 for WFD native library.
system_ext/lib64/libwfdnative.so)
"${PATCHELF}" --remove-needed "android.hidl.base@1.0.so" "${2}"
;;
esac
}
# Initialize the helper
setup_vendor "${DEVICE}" "${VENDOR}" "${ANDROID_ROOT}" false "${CLEAN_VENDOR}"
extract "${MY_DIR}/proprietary-files.txt" "${SRC}" "${KANG}" --section "${SECTION}"
"${MY_DIR}/setup-makefiles.sh"

15
idc/uinput-fpc.idc Normal file
View File

@ -0,0 +1,15 @@
#
# FPC1020 Touch sensor driver
#
# Copyright (c) 2013,2014 Fingerprint Cards AB <tech@fingerprints.com>
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License Version 2
# as published by the Free Software Foundation.
#
device.internal = 1
keyboard.layout = uinput-fpc
keyboard.builtIn = 1
keyboard.orientationAware = 1

15
idc/uinput-goodix.idc Normal file
View File

@ -0,0 +1,15 @@
#
# FPC1020 Touch sensor driver
#
# Copyright (c) 2013,2014 Fingerprint Cards AB <tech@fingerprints.com>
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License Version 2
# as published by the Free Software Foundation.
#
device.internal = 1
keyboard.layout = uinput-gf
keyboard.builtIn = 1
keyboard.orientationAware = 1

32
keylayout/gpio-keys.kl Normal file
View File

@ -0,0 +1,32 @@
# Copyright (c) 2013, The Linux Foundation. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above
# copyright notice, this list of conditions and the following
# disclaimer in the documentation and/or other materials provided
# with the distribution.
# * Neither the name of The Linux Foundation nor the names of its
# contributors may be used to endorse or promote products derived
# from this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
# BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
# BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
# OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
# IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
key 115 VOLUME_UP
key 114 VOLUME_DOWN
key 102 HOME
key 528 FOCUS
key 766 CAMERA

14
keylayout/uinput-fpc.kl Normal file
View File

@ -0,0 +1,14 @@
#
# FPC1020 Touch sensor driver
#
# Copyright (c) 2013,2014 Fingerprint Cards AB <tech@fingerprints.com>
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License Version 2
# as published by the Free Software Foundation.
#
#key 96 DPAD_CENTER
#key 102 HOME
#key 105 DPAD_LEFT
#key 106 DPAD_RIGHT

View File

@ -0,0 +1,14 @@
#
# Goodix fingerprint sensor driver
#
# Copyright (c) 2013,2014 Fingerprint Cards AB <tech@fingerprints.com>
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License Version 2
# as published by the Free Software Foundation.
#
#key 96 DPAD_CENTER
#key 102 HOME
#key 105 DPAD_LEFT
#key 106 DPAD_RIGHT

View File

@ -4,10 +4,23 @@
// SPDX-License-Identifier: Apache-2.0
//
cc_library_static {
name: "libinit_xiaomi_miatoll",
srcs: [
"libinit_dalvik_heap.cpp",
"libinit_variant.cpp",
"libinit_utils.cpp",
],
whole_static_libs: ["libbase"],
export_include_dirs: ["include"],
recovery_available: true,
}
cc_library_static {
name: "init_xiaomi_miatoll",
srcs: ["init_xiaomi_miatoll.cpp"],
whole_static_libs: ["//device/xiaomi/sm6250-common:libinit_xiaomi_atoll"],
whole_static_libs: ["libinit_xiaomi_miatoll"],
include_dirs: ["system/core/init"],
recovery_available: true,
}

View File

@ -0,0 +1,23 @@
/*
* Copyright (C) 2021 The LineageOS Project
*
* SPDX-License-Identifier: Apache-2.0
*/
#ifndef LIBINIT_DALVIK_HEAP_H
#define LIBINIT_DALVIK_HEAP_H
#include <string>
typedef struct dalvik_heap_info {
std::string heapstartsize;
std::string heapgrowthlimit;
std::string heapsize;
std::string heapminfree;
std::string heapmaxfree;
std::string heaptargetutilization;
} dalvik_heap_info_t;
void set_dalvik_heap(void);
#endif // LIBINIT_DALVIK_HEAP_H

View File

@ -0,0 +1,18 @@
/*
* Copyright (C) 2021-2022 The LineageOS Project
*
* SPDX-License-Identifier: Apache-2.0
*/
#ifndef LIBINIT_UTILS_H
#define LIBINIT_UTILS_H
#include <string>
void property_override(std::string prop, std::string value, bool add = true);
void set_ro_build_prop(const std::string &prop, const std::string &value, bool product = false);
std::string fingerprint_to_description(std::string fingerprint);
#endif // LIBINIT_UTILS_H

View File

@ -0,0 +1,28 @@
/*
* Copyright (C) 2021-2022 The LineageOS Project
*
* SPDX-License-Identifier: Apache-2.0
*/
#ifndef LIBINIT_VARIANT_H
#define LIBINIT_VARIANT_H
#include <string>
#include <vector>
typedef struct variant_info {
std::string hwc_value;
std::string brand;
std::string device;
std::string model;
std::string build_fingerprint;
bool nfc;
} variant_info_t;
void search_variant(const std::vector<variant_info_t> variants);
void set_variant_props(const variant_info_t variant);
#endif // LIBINIT_VARIANT_H

View File

@ -0,0 +1,67 @@
/*
* Copyright (C) 2021 The LineageOS Project
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <sys/sysinfo.h>
#include <libinit_utils.h>
#include <libinit_dalvik_heap.h>
#define HEAPSTARTSIZE_PROP "dalvik.vm.heapstartsize"
#define HEAPGROWTHLIMIT_PROP "dalvik.vm.heapgrowthlimit"
#define HEAPSIZE_PROP "dalvik.vm.heapsize"
#define HEAPMINFREE_PROP "dalvik.vm.heapminfree"
#define HEAPMAXFREE_PROP "dalvik.vm.heapmaxfree"
#define HEAPTARGETUTILIZATION_PROP "dalvik.vm.heaptargetutilization"
#define GB(b) (b * 1024ull * 1024 * 1024)
static const dalvik_heap_info_t dalvik_heap_info_6144 = {
.heapstartsize = "16m",
.heapgrowthlimit = "256m",
.heapsize = "512m",
.heapminfree = "8m",
.heapmaxfree = "32m",
.heaptargetutilization = "0.5",
};
static const dalvik_heap_info_t dalvik_heap_info_4096 = {
.heapstartsize = "8m",
.heapgrowthlimit = "256m",
.heapsize = "512m",
.heapminfree = "8m",
.heapmaxfree = "16m",
.heaptargetutilization = "0.6",
};
static const dalvik_heap_info_t dalvik_heap_info_2048 = {
.heapstartsize = "8m",
.heapgrowthlimit = "192m",
.heapsize = "512m",
.heapminfree = "512k",
.heapmaxfree = "8m",
.heaptargetutilization = "0.75",
};
void set_dalvik_heap() {
struct sysinfo sys;
const dalvik_heap_info_t *dhi;
sysinfo(&sys);
if (sys.totalram > GB(5))
dhi = &dalvik_heap_info_6144;
else if (sys.totalram > GB(3))
dhi = &dalvik_heap_info_4096;
else
dhi = &dalvik_heap_info_2048;
property_override(HEAPSTARTSIZE_PROP, dhi->heapstartsize);
property_override(HEAPGROWTHLIMIT_PROP, dhi->heapgrowthlimit);
property_override(HEAPSIZE_PROP, dhi->heapsize);
property_override(HEAPTARGETUTILIZATION_PROP, dhi->heaptargetutilization);
property_override(HEAPMINFREE_PROP, dhi->heapminfree);
property_override(HEAPMAXFREE_PROP, dhi->heapmaxfree);
}

75
libinit/libinit_utils.cpp Normal file
View File

@ -0,0 +1,75 @@
/*
* Copyright (C) 2021-2022 The LineageOS Project
*
* SPDX-License-Identifier: Apache-2.0
*/
#define _REALLY_INCLUDE_SYS__SYSTEM_PROPERTIES_H_
#include <sys/_system_properties.h>
#include <vector>
#include <libinit_utils.h>
void property_override(std::string prop, std::string value, bool add) {
auto pi = (prop_info *) __system_property_find(prop.c_str());
if (pi != nullptr) {
__system_property_update(pi, value.c_str(), value.length());
} else if (add) {
__system_property_add(prop.c_str(), prop.length(), value.c_str(), value.length());
}
}
std::vector<std::string> ro_props_default_source_order = {
"odm.",
"odm_dlkm.",
"product.",
"system.",
"system_ext.",
"vendor.",
"vendor_dlkm.",
"",
};
void set_ro_build_prop(const std::string &prop, const std::string &value, bool product) {
std::string prop_name;
for (const auto &source : ro_props_default_source_order) {
if (product)
prop_name = "ro.product." + source + prop;
else
prop_name = "ro." + source + "build." + prop;
property_override(prop_name, value, true);
}
}
#define FIND_AND_REMOVE(s, delimiter, variable_name) \
std::string variable_name = s.substr(0, s.find(delimiter)); \
s.erase(0, s.find(delimiter) + delimiter.length());
#define APPEND_STRING(s, to_append) \
s.append(" "); \
s.append(to_append);
std::string fingerprint_to_description(std::string fingerprint) {
std::string delimiter = "/";
std::string delimiter2 = ":";
std::string build_fingerprint_copy = fingerprint;
FIND_AND_REMOVE(build_fingerprint_copy, delimiter, brand)
FIND_AND_REMOVE(build_fingerprint_copy, delimiter, product)
FIND_AND_REMOVE(build_fingerprint_copy, delimiter2, device)
FIND_AND_REMOVE(build_fingerprint_copy, delimiter, platform_version)
FIND_AND_REMOVE(build_fingerprint_copy, delimiter, build_id)
FIND_AND_REMOVE(build_fingerprint_copy, delimiter2, build_number)
FIND_AND_REMOVE(build_fingerprint_copy, delimiter, build_variant)
std::string build_version_tags = build_fingerprint_copy;
std::string description = product + "-" + build_variant;
APPEND_STRING(description, platform_version)
APPEND_STRING(description, build_id)
APPEND_STRING(description, build_number)
APPEND_STRING(description, build_version_tags)
return description;
}

View File

@ -0,0 +1,42 @@
/*
* Copyright (C) 2021-2022 The LineageOS Project
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <android-base/properties.h>
#include <libinit_utils.h>
#include <libinit_variant.h>
using android::base::GetProperty;
#define HWC_PROP "ro.boot.hwc"
#define HWNAME_PROP "ro.boot.hwname"
#define SKU_PROP "ro.boot.product.hardware.sku"
void search_variant(const std::vector<variant_info_t> variants) {
std::string hwc_value = GetProperty(HWC_PROP, "");
std::string hwname_value = GetProperty(HWNAME_PROP, "");
for (const auto& variant : variants) {
if ((variant.hwc_value == "" || variant.hwc_value == hwc_value) && (variant.device == hwname_value)) {
set_variant_props(variant);
break;
}
}
}
void set_variant_props(const variant_info_t variant) {
set_ro_build_prop("brand", variant.brand, true);
set_ro_build_prop("device", variant.device, true);
set_ro_build_prop("model", variant.model, true);
set_ro_build_prop("fingerprint", variant.build_fingerprint);
property_override("ro.bootimage.build.fingerprint", variant.build_fingerprint);
property_override("ro.build.description", fingerprint_to_description(variant.build_fingerprint));
if (variant.nfc)
property_override(SKU_PROP, "nfc");
}

View File

@ -0,0 +1,17 @@
cc_library_shared {
name: "libqti-perfd-client",
proprietary: true,
defaults: ["hidl_defaults"],
srcs: [
"client.c",
],
cflags: [
"-Werror",
"-Wextra",
"-Wall",
],
shared_libs: [
"liblog",
"libutils",
],
}

View File

@ -0,0 +1,24 @@
#define LOG_TAG "libqti-perfd-client"
#include <stdint.h>
#include <log/log.h>
void perf_get_feedback() {}
void perf_hint() {}
int perf_lock_acq(int handle, int duration, int arg3[], int arg4) {
ALOGI("perf_lock_acq: handle: %d, duration: %d, arg3[0]: %d, arg4: %d",
handle, duration, arg3[0], arg4);
if (handle > 0)
return handle;
return 233;
}
void perf_lock_cmd() {}
int perf_lock_rel(int handle) {
ALOGI("perf_lock_rel: handle: %d", handle);
if (handle > 0)
return handle;
return 233;
}
void perf_lock_use_profile() {}

View File

@ -1,6 +1,10 @@
[
{
"repository": "android_device_xiaomi_sm6250-common",
"target_path": "device/xiaomi/sm6250-common"
"repository": "android_hardware_xiaomi",
"target_path": "hardware/xiaomi"
},
{
"repository": "android_kernel_xiaomi_sm6250",
"target_path": "kernel/xiaomi/sm6250"
}
]

View File

@ -0,0 +1,18 @@
<compatibility-matrix version="2.0" type="framework">
<hal format="hidl" optional="true">
<name>vendor.lineage.livedisplay</name>
<version>2.0</version>
<interface>
<name>IPictureAdjustment</name>
<instance>default</instance>
</interface>
</hal>
<hal format="hidl" optional="true">
<name>vendor.lineage.trust</name>
<version>1.0</version>
<interface>
<name>IUsbRestrict</name>
<instance>default</instance>
</interface>
</hal>
</compatibility-matrix>

339
manifest.xml Normal file
View File

@ -0,0 +1,339 @@
<manifest version="2.0" type="device" target-level="5">
<hal format="hidl">
<name>android.hardware.audio</name>
<transport>hwbinder</transport>
<fqname>@6.0::IDevicesFactory/default</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.audio.effect</name>
<transport>hwbinder</transport>
<fqname>@6.0::IEffectsFactory/default</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.bluetooth</name>
<transport>hwbinder</transport>
<fqname>@1.0::IBluetoothHci/default</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.bluetooth.audio</name>
<transport>hwbinder</transport>
<fqname>@2.1::IBluetoothAudioProvidersFactory/default</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.camera.provider</name>
<transport>hwbinder</transport>
<fqname>@2.4::ICameraProvider/legacy/0</fqname>
</hal>
<hal format="hidl" override="true">
<name>android.hardware.contexthub</name>
<transport>hwbinder</transport>
<fqname>@1.0::IContexthub/default</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.drm</name>
<transport>hwbinder</transport>
<fqname>@1.3::ICryptoFactory/wfdhdcp</fqname>
<fqname>@1.3::IDrmFactory/wfdhdcp</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.gatekeeper</name>
<transport>hwbinder</transport>
<fqname>@1.0::IGatekeeper/default</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.ir</name>
<transport>hwbinder</transport>
<fqname>@1.0::IConsumerIr/default</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.keymaster</name>
<transport>hwbinder</transport>
<fqname>@4.1::IKeymasterDevice/default</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.media.omx</name>
<transport>hwbinder</transport>
<fqname>@1.0::IOmx/default</fqname>
<fqname>@1.0::IOmxStore/default</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.memtrack</name>
<transport>hwbinder</transport>
<fqname>@1.0::IMemtrack/default</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.radio</name>
<transport>hwbinder</transport>
<fqname>@1.2::ISap/slot1</fqname>
<fqname>@1.2::ISap/slot2</fqname>
<fqname>@1.5::IRadio/slot1</fqname>
<fqname>@1.5::IRadio/slot2</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.radio.config</name>
<transport>hwbinder</transport>
<fqname>@1.1::IRadioConfig/default</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.renderscript</name>
<transport arch="32+64">passthrough</transport>
<fqname>@1.0::IDevice/default</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.soundtrigger</name>
<transport>hwbinder</transport>
<fqname>@2.2::ISoundTriggerHw/default</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.tetheroffload.config</name>
<transport>hwbinder</transport>
<fqname>@1.0::IOffloadConfig/default</fqname>
</hal>
<hal format="hidl">
<name>android.hardware.tetheroffload.control</name>
<transport>hwbinder</transport>
<fqname>@1.0::IOffloadControl/default</fqname>
</hal>
<hal format="hidl">
<name>com.fingerprints.extension</name>
<transport>hwbinder</transport>
<fqname>@1.0::IFingerprintEngineering/default</fqname>
<fqname>@1.0::IFingerprintNavigation/default</fqname>
<fqname>@1.0::IFingerprintSensorTest/default</fqname>
</hal>
<hal format="hidl">
<name>com.qualcomm.qti.dpm.api</name>
<transport>hwbinder</transport>
<fqname>@1.0::IdpmQmi/dpmQmiService</fqname>
</hal>
<hal format="hidl">
<name>com.qualcomm.qti.imscmservice</name>
<transport>hwbinder</transport>
<fqname>@2.2::IImsCmService/qti.ims.connectionmanagerservice</fqname>
</hal>
<hal format="hidl">
<name>com.qualcomm.qti.uceservice</name>
<transport>hwbinder</transport>
<fqname>@2.3::IUceService/com.qualcomm.qti.uceservice</fqname>
</hal>
<hal format="hidl">
<name>vendor.display.color</name>
<transport>hwbinder</transport>
<fqname>@1.3::IDisplayColor/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.display.postproc</name>
<transport>hwbinder</transport>
<fqname>@1.0::IDisplayPostproc/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.lineage.livedisplay</name>
<transport>hwbinder</transport>
<fqname>@2.0::IPictureAdjustment/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.data.factory</name>
<transport>hwbinder</transport>
<fqname>@2.2::IFactory/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.esepowermanager</name>
<transport>hwbinder</transport>
<fqname>@1.1::IEsePowerManager/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.alarm</name>
<transport>hwbinder</transport>
<fqname>@1.0::IAlarm/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.bluetooth_audio</name>
<transport>hwbinder</transport>
<fqname>@2.1::IBluetoothAudioProvidersFactory/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.bluetooth_sar</name>
<transport>hwbinder</transport>
<fqname>@1.1::IBluetoothSar/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.btconfigstore</name>
<transport>hwbinder</transport>
<fqname>@2.0::IBTConfigStore/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.cacert</name>
<transport>hwbinder</transport>
<fqname>@1.0::IService/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.capabilityconfigstore</name>
<transport>hwbinder</transport>
<fqname>@1.0::ICapabilityConfigStore/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.cryptfshw</name>
<transport>hwbinder</transport>
<fqname>@1.0::ICryptfsHw/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.data.connection</name>
<transport>hwbinder</transport>
<fqname>@1.1::IDataConnection/slot1</fqname>
<fqname>@1.1::IDataConnection/slot2</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.data.latency</name>
<transport>hwbinder</transport>
<fqname>@1.0::ILinkLatency/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.dsp</name>
<transport>hwbinder</transport>
<fqname>@1.0::IDspService/dspservice</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.embmssl</name>
<transport>hwbinder</transport>
<fqname>@1.1::IEmbms/embmsslServer0</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.factory</name>
<transport>hwbinder</transport>
<fqname>@1.1::IFactory/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.fm</name>
<transport>hwbinder</transport>
<fqname>@1.0::IFmHci/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.fstman</name>
<transport>hwbinder</transport>
<fqname>@1.0::IFstManager/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.qccvndhal</name>
<transport>hwbinder</transport>
<fqname>@1.0::IQccvndhal/qccvndhal</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.qseecom</name>
<transport>hwbinder</transport>
<fqname>@1.0::IQSEECom/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.qteeconnector</name>
<transport>hwbinder</transport>
<fqname>@1.0::IAppConnector/default</fqname>
<fqname>@1.0::IGPAppConnector/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.radio.am</name>
<transport>hwbinder</transport>
<fqname>@1.0::IQcRilAudio/slot1</fqname>
<fqname>@1.0::IQcRilAudio/slot2</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.radio.ims</name>
<transport>hwbinder</transport>
<fqname>@1.7::IImsRadio/imsradio0</fqname>
<fqname>@1.7::IImsRadio/imsradio1</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.radio.internal.deviceinfo</name>
<transport>hwbinder</transport>
<fqname>@1.0::IDeviceInfo/deviceinfo</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.radio.lpa</name>
<transport>hwbinder</transport>
<fqname>@1.0::IUimLpa/UimLpa0</fqname>
<fqname>@1.0::IUimLpa/UimLpa1</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.radio.qcrilhook</name>
<transport>hwbinder</transport>
<fqname>@1.0::IQtiOemHook/oemhook0</fqname>
<fqname>@1.0::IQtiOemHook/oemhook1</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.radio.qtiradio</name>
<transport>hwbinder</transport>
<fqname>@1.0::IQtiRadio/slot1</fqname>
<fqname>@1.0::IQtiRadio/slot2</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.radio.qtiradio</name>
<transport>hwbinder</transport>
<fqname>@2.4::IQtiRadio/slot1</fqname>
<fqname>@2.4::IQtiRadio/slot2</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.radio.uim</name>
<transport>hwbinder</transport>
<fqname>@1.2::IUim/Uim0</fqname>
<fqname>@1.2::IUim/Uim1</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.radio.uim_remote_client</name>
<transport>hwbinder</transport>
<fqname>@1.0::IUimRemoteServiceClient/uimRemoteClient0</fqname>
<fqname>@1.0::IUimRemoteServiceClient/uimRemoteClient1</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.radio.uim_remote_server</name>
<transport>hwbinder</transport>
<fqname>@1.0::IUimRemoteServiceServer/uimRemoteServer0</fqname>
<fqname>@1.0::IUimRemoteServiceServer/uimRemoteServer1</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.sensorscalibrate</name>
<transport>hwbinder</transport>
<fqname>@1.0::ISensorsCalibrate/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.soter</name>
<transport>hwbinder</transport>
<fqname>@1.0::ISoter/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.trustedui</name>
<transport>hwbinder</transport>
<fqname>@1.0::ITrustedInput/default</fqname>
<fqname>@1.0::ITrustedUI/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.tui_comm</name>
<transport>hwbinder</transport>
<fqname>@1.0::ITuiComm/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.wifi.wifilearner</name>
<transport>hwbinder</transport>
<fqname>@1.0::IWifiStats/wifiStats</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.hardware.wifidisplaysession</name>
<transport>hwbinder</transport>
<fqname>@1.0::IWifiDisplaySession/wifidisplaysession</fqname>
<fqname>@1.0::IWifiDisplaySessionAudioTrack/wifidisplaysessionaudiotrack</fqname>
<fqname>@1.0::IWifiDisplaySessionImageTrack/wifidisplaysessionimagetrack</fqname>
<fqname>@1.0::IWifiDisplaySessionVideoTrack/wifidisplaysessionvideotrack</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.ims.callinfo</name>
<transport>hwbinder</transport>
<fqname>@1.0::IService/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.ims.factory</name>
<transport>hwbinder</transport>
<fqname>@1.0::IImsFactory/default</fqname>
</hal>
<hal format="hidl">
<name>vendor.qti.imsrtpservice</name>
<transport>hwbinder</transport>
<fqname>@3.0::IRTPService/imsrtpservice</fqname>
</hal>
</manifest>

390
media/media_codecs.xml Normal file
View File

@ -0,0 +1,390 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2012-2020 The Linux Foundation. All rights reserved.
Not a contribution.
Copyright (C) 2012-2013 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!--
<!DOCTYPE MediaCodecs [
<!ELEMENT Include EMPTY>
<!ATTLIST Include href CDATA #REQUIRED>
<!ELEMENT MediaCodecs (Decoders|Encoders|Include)*>
<!ELEMENT Decoders (MediaCodec|Include)*>
<!ELEMENT Encoders (MediaCodec|Include)*>
<!ELEMENT MediaCodec (Type|Quirk|Include)*>
<!ATTLIST MediaCodec name CDATA #REQUIRED>
<!ATTLIST MediaCodec type CDATA>
<!ELEMENT Type EMPTY>
<!ATTLIST Type name CDATA #REQUIRED>
<!ELEMENT Quirk EMPTY>
<!ATTLIST Quirk name CDATA #REQUIRED>
]>
There's a simple and a complex syntax to declare the availability of a
media codec:
A codec that properly follows the OpenMax spec and therefore doesn't have any
quirks and that only supports a single content type can be declared like so:
<MediaCodec name="OMX.foo.bar" type="something/interesting" />
If a codec has quirks OR supports multiple content types, the following syntax
can be used:
<MediaCodec name="OMX.foo.bar" >
<Type name="something/interesting" />
<Type name="something/else" />
...
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="output-buffers-are-unreadable" />
</MediaCodec>
Only the three quirks included above are recognized at this point:
"requires-allocate-on-input-ports"
must be advertised if the component does not properly support specification
of input buffers using the OMX_UseBuffer(...) API but instead requires
OMX_AllocateBuffer to be used.
"requires-allocate-on-output-ports"
must be advertised if the component does not properly support specification
of output buffers using the OMX_UseBuffer(...) API but instead requires
OMX_AllocateBuffer to be used.
"output-buffers-are-unreadable"
must be advertised if the emitted output buffers of a decoder component
are not readable, i.e. use a custom format even though abusing one of
the official OMX colorspace constants.
Clients of such decoders will not be able to access the decoded data,
naturally making the component much less useful. The only use for
a component with this quirk is to render the output to the screen.
Audio decoders MUST NOT advertise this quirk.
Video decoders that advertise this quirk must be accompanied by a
corresponding color space converter for thumbnail extraction,
matching surfaceflinger support that can render the custom format to
a texture and possibly other code, so just DON'T USE THIS QUIRK.
-->
<!--
SM6150 Non-Secure decoder capabilities
_________________________________________________________
| Codec | W H fps Mbps MB/s |
|_____________|_________________________________________|
| h264 | 4096 2160 24 100 829440 |
| hevc | 4096 2160 24 100 829440 |
| mpeg4-sw | 1920 1088 30 40 244800 |
| vp8 | 3840 2160 30 100 972000 |
| vp9 | 4096 2160 24 100 829440 |
| vc1 | 1920 1088 30 20 244800 |
| h263-sw | 864 480 30 16 48600 |
| mpeg2 | 1920 1088 30 40 244800 |
|_____________|_________________________________________|
SM6150 Secure decoder capabilities
______________________________________________________
| Codec | W H fps Mbps MB/s |
|__________|_________________________________________|
| h264 | 3840 2160 30 35 972000 |
| vp9 | 3840 2160 30 35 972000 |
| hevc | 3840 2160 30 35 972000 |
| mpeg2 | 1920 1088 30 35 244800 |
|__________|_________________________________________|
SM6150 Non-Secure encoder capabilities (Secure not supported)
______________________________________________________
| Codec | W H fps Mbps MB/s |
|__________|_________________________________________|
| h264 | 4096 2160 24 100 829440 |
| hevc | 4096 2160 24 100 829440 |
| mpeg4-sw | 1280 720 30 4 108000 |
| vp8 | 3840 2160 30 100 972000 |
| h263-sw | 864 480 30 2 48600 |
|__________|_________________________________________|
-->
<MediaCodecs>
<Include href="media_codecs_google_audio.xml" />
<Include href="media_codecs_google_telephony.xml" />
<Settings>
<Setting name="max-video-encoder-input-buffers" value="11" />
</Settings>
<Encoders>
<!-- Video Hardware -->
<MediaCodec name="OMX.qcom.video.encoder.avc" type="video/avc" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="requires-loaded-to-idle-after-allocation" />
<Limit name="size" min="96x96" max="4096x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="979200" />
<Limit name="bitrate" range="1-100000000" />
<Limit name="frame-rate" range="1-240" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-4096x2160" value="24" />
<Limit name="performance-point-3840x2160" value="30" />
<Limit name="performance-point-1920x1080" value="120" />
<Limit name="performance-point-1280x720" value="240" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.encoder.vp8" type="video/x-vnd.on2.vp8" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="requires-loaded-to-idle-after-allocation" />
<Limit name="size" min="96x96" max="3840x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="979200" />
<Limit name="bitrate" range="1-120000000" />
<Limit name="frame-rate" range="1-240" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-3840x2160" value="30" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.encoder.hevc" type="video/hevc" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="requires-loaded-to-idle-after-allocation" />
<Limit name="size" min="96x96" max="4096x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="979200" />
<Limit name="bitrate" range="1-100000000" />
<Limit name="frame-rate" range="1-240" />
<Limit name="concurrent-instances" max="16" />
<Limit name="quality" range="0-100" default="80" />
<Limit name="performance-point-4096x2160" value="24" />
<Limit name="performance-point-3840x2160" value="30" />
<Limit name="performance-point-1920x1080" value="120" />
<Limit name="performance-point-1280x720" value="240" />
<Feature name="bitrate-modes" value="VBR,CBR" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.encoder.hevc.cq" type="video/hevc" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="requires-loaded-to-idle-after-allocation" />
<Limit name="size" min="512x512" max="512x512" />
<Limit name="frame-rate" range="1-20" />
<Limit name="concurrent-instances" max="16" />
<Limit name="quality" range="0-100" default="80" />
<Limit name="performance-point-4096x2304" value="24" />
<Limit name="performance-point-3840x2160" value="30" />
<Limit name="performance-point-1920x1080" value="120" />
<Limit name="performance-point-1280x720" value="240" />
<Feature name="bitrate-modes" value="CQ" />
</MediaCodec>
<!-- Video Software -->
<MediaCodec name="OMX.qcom.video.encoder.h263sw" type="video/3gpp" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="requires-loaded-to-idle-after-allocation" />
<Limit name="size" min="96x96" max="864x480" />
<Limit name="alignment" value="4x4" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="48600" />
<Limit name="bitrate" range="1-2000000" />
<Limit name="frame-rate" range="1-30" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-864x480" value="30" />
<Limit name="performance-point-720x480" value="30" />
<Limit name="performance-point-720x576" value="25" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.encoder.mpeg4sw" type="video/mp4v-es" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="requires-loaded-to-idle-after-allocation" />
<Limit name="size" min="96x96" max="864x480" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="48600" />
<Limit name="bitrate" range="1-8000000" />
<Limit name="frame-rate" range="1-30" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-864x480" value="30" />
<Limit name="performance-point-720x480" value="30" />
<Limit name="performance-point-720x576" value="25" />
</MediaCodec>
</Encoders>
<Decoders>
<!-- Video Hardware -->
<MediaCodec name="OMX.qcom.video.decoder.avc" type="video/avc" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="4096x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="979200" />
<Limit name="bitrate" range="1-100000000" />
<Limit name="frame-rate" range="1-240" />
<Feature name="adaptive-playback" />
<Feature name="can-swap-width-height" required="true" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-4096x2160" value="24" />
<Limit name="performance-point-3840x2160" value="30" />
<Limit name="performance-point-1920x1080" value="120" />
<Limit name="performance-point-1280x720" value="240" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.avc.secure" type="video/avc" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="3840x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="972000" />
<Limit name="bitrate" range="1-35000000" />
<Limit name="frame-rate" range="1-30" />
<Feature name="adaptive-playback" />
<Feature name="secure-playback" required="true" />
<Limit name="concurrent-instances" max="3" />
<Limit name="performance-point-3840x2160" value="30" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.mpeg2" type="video/mpeg2" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="1920x1088" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="244800" />
<Limit name="bitrate" range="1-40000000" />
<Limit name="frame-rate" range="1-30" />
<Feature name="adaptive-playback" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-1920x1080" value="30" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.mpeg2.secure" type="video/mpeg2" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="1920x1088" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="244800" />
<Limit name="bitrate" range="1-35000000" />
<Limit name="frame-rate" range="1-30" />
<Feature name="adaptive-playback" />
<Feature name="secure-playback" required="true" />
<Limit name="concurrent-instances" max="3" />
<Limit name="performance-point-1920x1080" value="30" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.vp8" type="video/x-vnd.on2.vp8" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="3840x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="979200" />
<Limit name="bitrate" range="1-100000000" />
<Limit name="frame-rate" range="1-240" />
<Feature name="adaptive-playback" />
<Feature name="can-swap-width-height" required="true" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-3840x2160" value="30" />
<Limit name="performance-point-1920x1080" value="60" />
<Limit name="performance-point-1280x720" value="120" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.vp9" type="video/x-vnd.on2.vp9" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="4096x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="979200" />
<Limit name="bitrate" range="1-120000000" />
<Limit name="frame-rate" range="1-240" />
<Feature name="adaptive-playback" />
<Feature name="can-swap-width-height" required="true" />
<Limit name="concurrent-instances" max="6" />
<Limit name="performance-point-4096x2160" value="24" />
<Limit name="performance-point-3840x2160" value="30" />
<Limit name="performance-point-1920x1080" value="120" />
<Limit name="performance-point-1280x720" value="240" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.vp9.secure" type="video/x-vnd.on2.vp9" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="3840x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="972000" />
<Limit name="bitrate" range="1-35000000" />
<Limit name="frame-rate" range="1-30" />
<Feature name="adaptive-playback" />
<Feature name="secure-playback" required="true" />
<Limit name="concurrent-instances" max="3" />
<Limit name="performance-point-3840x2160" value="30" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.hevc" type="video/hevc" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="4096x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="979200" />
<Limit name="bitrate" range="1-100000000" />
<Limit name="frame-rate" range="1-240" />
<Feature name="adaptive-playback" />
<Feature name="can-swap-width-height" required="true" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-4096x2160" value="24" />
<Limit name="performance-point-3840x2160" value="30" />
<Limit name="performance-point-1920x1080" value="120" />
<Limit name="performance-point-1280x720" value="240" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.hevc.secure" type="video/hevc" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="3840x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="972000" />
<Limit name="bitrate" range="1-35000000" />
<Limit name="frame-rate" range="1-30" />
<Feature name="adaptive-playback" />
<Feature name="secure-playback" required="true" />
<Limit name="concurrent-instances" max="3" />
<Limit name="performance-point-3840x2160" value="30" />
</MediaCodec>
<!-- Video Software -->
<MediaCodec name="OMX.qti.video.decoder.h263sw" type="video/3gpp" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="864x480" />
<Limit name="alignment" value="4x4" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="48600" />
<Limit name="bitrate" range="1-16000000" />
<Limit name="frame-rate" range="1-30" />
<Feature name="adaptive-playback" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-864x480" value="30" />
<Limit name="performance-point-720x480" value="30" />
<Limit name="performance-point-720x576" value="25" />
</MediaCodec>
<MediaCodec name="OMX.qti.video.decoder.mpeg4sw" type="video/mp4v-es">
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="1920x1088" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="244800" />
<Limit name="bitrate" range="1-40000000" />
<Limit name="frame-rate" range="1-30" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-1920x1080" value="30" />
</MediaCodec>
<MediaCodec name="OMX.google.opus.decoder" type="audio/opus" update="true" rank="100"/>
</Decoders>
<Include href="media_codecs_google_video.xml" />
</MediaCodecs>

View File

@ -0,0 +1,194 @@
<?xml version="1.0" encoding="utf-8" ?>
<!--
Copyright (c) 2015-2017, 2019 The Linux Foundation. All rights reserved.
Not a Contribution.
Copyright 2015 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
u may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<MediaCodecs>
<Encoders>
<MediaCodec name="OMX.qcom.video.encoder.avc" type="video/avc" update="true">
<Limit name="measured-frame-rate-320x240" range="650-655" />
<Limit name="measured-frame-rate-720x480" range="280-289" />
<Limit name="measured-frame-rate-1280x720" range="110-115" />
<Limit name="measured-frame-rate-1920x1080" range="91-95" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.encoder.hevc" type="video/hevc" update="true">
<Limit name="measured-frame-rate-320x240" range="580-590" />
<Limit name="measured-frame-rate-720x480" range="270-300" />
<Limit name="measured-frame-rate-1280x720" range="110-119" />
<Limit name="measured-frame-rate-1920x1080" range="16-45" />
<Limit name="measured-frame-rate-3840x2160" range="20-28" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.encoder.h263sw" type="video/3gpp" update="true">
<Limit name="measured-frame-rate-176x144" range="270-280" />
<Limit name="measured-frame-rate-352x288" range="59-84" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.encoder.mpeg4sw" type="video/mp4v-es" update="true">
<Limit name="measured-frame-rate-176x144" range="80-102" />
<Limit name="measured-frame-rate-352x288" range="55-79" />
<Limit name="measured-frame-rate-640x480" range="39-58" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.encoder.vp8" type="video/x-vnd.on2.vp8" update="true">
<Limit name="measured-frame-rate-320x180" range="266-266" />
<Limit name="measured-frame-rate-640x360" range="440-450" />
<Limit name="measured-frame-rate-1280x720" range="130-135" />
<Limit name="measured-frame-rate-1920x1080" range="16-40" />
</MediaCodec>
<MediaCodec name="OMX.google.h264.encoder" type="video/avc" update="true">
<Limit name="measured-frame-rate-320x240" range="215-215" />
<Limit name="measured-frame-rate-720x480" range="100-100" />
<Limit name="measured-frame-rate-1280x720" range="56-56" />
<Limit name="measured-frame-rate-1920x1080" range="30-30" />
</MediaCodec>
<MediaCodec name="OMX.google.h263.encoder" type="video/3gpp" update="true">
<Limit name="measured-frame-rate-176x144" range="200-200" />
</MediaCodec>
<MediaCodec name="OMX.google.mpeg4.encoder" type="video/mp4v-es" update="true">
<Limit name="measured-frame-rate-176x144" range="180-180" />
</MediaCodec>
<MediaCodec name="OMX.google.vp8.encoder" type="video/x-vnd.on2.vp8" update="true">
<Limit name="measured-frame-rate-320x180" range="39-39" />
<Limit name="measured-frame-rate-640x360" range="32-32" />
<Limit name="measured-frame-rate-1280x720" range="17-24" />
<Limit name="measured-frame-rate-1920x1080" range="8-12" />
</MediaCodec>
<MediaCodec name="c2.android.avc.encoder" type="video/avc" update="true">
<Limit name="measured-frame-rate-320x240" range="196-266" />
<Limit name="measured-frame-rate-720x480" range="64-92" />
<Limit name="measured-frame-rate-1280x720" range="38-60" />
<Limit name="measured-frame-rate-1920x1080" range="23-33" />
</MediaCodec>
<MediaCodec name="c2.android.hevc.encoder" type="video/hevc" update="true">
<Limit name="measured-frame-rate-320x240" range="22-36" />
</MediaCodec>
<MediaCodec name="c2.android.h263.encoder" type="video/3gpp" update="true">
<Limit name="measured-frame-rate-176x144" range="215-333" />
</MediaCodec>
<MediaCodec name="c2.android.mpeg4.encoder" type="video/mp4v-es" update="true">
<Limit name="measured-frame-rate-176x144" range="222-311" />
</MediaCodec>
<MediaCodec name="c2.android.vp8.encoder" type="video/x-vnd.on2.vp8" update="true">
<Limit name="measured-frame-rate-320x180" range="120-187" />
<Limit name="measured-frame-rate-640x360" range="87-123" />
<Limit name="measured-frame-rate-1280x720" range="21-31" />
<Limit name="measured-frame-rate-1920x1080" range="19-28" />
</MediaCodec>
</Encoders>
<Decoders>
<MediaCodec name="OMX.qcom.video.decoder.avc" type="video/avc" update="true">
<Limit name="measured-frame-rate-320x240" range="305-494" />
<Limit name="measured-frame-rate-720x480" range="310-488" />
<Limit name="measured-frame-rate-1280x720" range="177-275" />
<Limit name="measured-frame-rate-1920x1088" range="93-146" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.hevc" type="video/hevc" update="true">
<Limit name="measured-frame-rate-352x288" range="366-401" />
<Limit name="measured-frame-rate-720x480" range="268-360" />
<Limit name="measured-frame-rate-1280x720" range="191-268" />
<Limit name="measured-frame-rate-1920x1080" range="94-147" />
<Limit name="measured-frame-rate-3840x2160" range="29-41" />
</MediaCodec>
<MediaCodec name="OMX.qti.video.decoder.h263sw" type="video/3gpp" update="true">
<Limit name="measured-frame-rate-176x144" range="356-356" />
<Limit name="measured-frame-rate-352x288" range="292-292" />
</MediaCodec>
<MediaCodec name="OMX.qti.video.decoder.mpeg4sw" type="video/mp4v-es" update="true">
<Limit name="measured-frame-rate-176x144" range="203-431" />
<Limit name="measured-frame-rate-480x360" range="190-450" />
<Limit name="measured-frame-rate-1280x720" range="160-217" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.vp8" type="video/x-vnd.on2.vp8" update="true">
<Limit name="measured-frame-rate-320x240" range="337-337" />
<Limit name="measured-frame-rate-640x360" range="337-337" />
<Limit name="measured-frame-rate-1280x720" range="337-337" />
<Limit name="measured-frame-rate-1920x1080" range="248-248" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.vp9" type="video/x-vnd.on2.vp9" update="true">
<Limit name="measured-frame-rate-320x240" range="377-377" />
<Limit name="measured-frame-rate-640x360" range="323-323" />
<Limit name="measured-frame-rate-1280x720" range="262-262" />
<Limit name="measured-frame-rate-1920x1080" range="102-204" />
<Limit name="measured-frame-rate-3840x2160" range="23-51" />
</MediaCodec>
<MediaCodec name="OMX.google.h264.decoder" type="video/avc" update="true">
<Limit name="measured-frame-rate-320x240" range="122-122" />
<Limit name="measured-frame-rate-720x480" range="68-68" />
<Limit name="measured-frame-rate-1280x720" range="32-32" />
<Limit name="measured-frame-rate-1920x1080" range="6-10" />
</MediaCodec>
<MediaCodec name="OMX.google.h263.decoder" type="video/3gpp" update="true">
<Limit name="measured-frame-rate-176x144" range="104-279" />
<Limit name="measured-frame-rate-352x288" range="200-200" />
</MediaCodec>
<MediaCodec name="OMX.google.hevc.decoder" type="video/hevc" update="true">
<Limit name="measured-frame-rate-352x288" range="170-170" />
<Limit name="measured-frame-rate-640x360" range="89-89" />
<Limit name="measured-frame-rate-720x480" range="73-73" />
<Limit name="measured-frame-rate-1280x720" range="32-32" />
<Limit name="measured-frame-rate-1920x1080" range="21-21" />
</MediaCodec>
<MediaCodec name="OMX.google.mpeg4.decoder" update="true">
<Type name="video/mp4v-es">
<Limit name="measured-frame-rate-176x144" range="430-450" />
</Type>
</MediaCodec>
<MediaCodec name="OMX.google.vp8.decoder" type="video/x-vnd.on2.vp8" update="true">
<Limit name="measured-frame-rate-320x240" range="330-381" />
<Limit name="measured-frame-rate-640x360" range="139-185" />
<Limit name="measured-frame-rate-1280x720" range="22-38" />
<Limit name="measured-frame-rate-1920x1080" range="9-18" />
</MediaCodec>
<MediaCodec name="OMX.google.vp9.decoder" type="video/x-vnd.on2.vp9" update="true">
<Limit name="measured-frame-rate-320x240" range="200-230" />
<Limit name="measured-frame-rate-640x360" range="81-90" />
<Limit name="measured-frame-rate-1280x720" range="32-40" />
<Limit name="measured-frame-rate-1920x1080" range="19-23" />
</MediaCodec>
<MediaCodec name="c2.android.avc.decoder" type="video/avc" update="true">
<Limit name="measured-frame-rate-320x240" range="143-204" />
<Limit name="measured-frame-rate-720x480" range="48-76" />
<Limit name="measured-frame-rate-1280x720" range="20-29" />
<Limit name="measured-frame-rate-1920x1080" range="10-15" />
</MediaCodec>
<MediaCodec name="c2.android.hevc.decoder" type="video/hevc" update="true">
<Limit name="measured-frame-rate-352x288" range="120-290" />
<Limit name="measured-frame-rate-640x360" range="66-161" />
<Limit name="measured-frame-rate-720x480" range="99-142" />
<Limit name="measured-frame-rate-1280x720" range="51-73" />
<Limit name="measured-frame-rate-1920x1080" range="26-38" />
</MediaCodec>
<MediaCodec name="c2.android.h263.decoder" type="video/3gpp" update="true">
<Limit name="measured-frame-rate-176x144" range="333-920" />
<Limit name="measured-frame-rate-352x288" range="438-584" />
</MediaCodec>
<MediaCodec name="c2.android.mpeg4.decoder" type="video/mp4v-es" update="true">
<Limit name="measured-frame-rate-176x144" range="554-876" />
</MediaCodec>
<MediaCodec name="c2.android.vp8.decoder" type="video/x-vnd.on2.vp8" update="true">
<Limit name="measured-frame-rate-320x180" range="514-727" />
<Limit name="measured-frame-rate-640x360" range="143-222" />
<Limit name="measured-frame-rate-1920x1080" range="22-31" />
</MediaCodec>
<MediaCodec name="c2.android.vp9.decoder" type="video/x-vnd.on2.vp9" update="true">
<Limit name="measured-frame-rate-320x180" range="432-576" />
<Limit name="measured-frame-rate-640x360" range="126-179" />
<Limit name="measured-frame-rate-1280x720" range="39-75" />
<Limit name="measured-frame-rate-1920x1080" range="25-36" />
</MediaCodec>
</Decoders>
</MediaCodecs>

View File

@ -0,0 +1,398 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2012-2020 The Linux Foundation. All rights reserved.
Not a contribution.
Copyright (C) 2012-2013 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!--
<!DOCTYPE MediaCodecs [
<!ELEMENT Include EMPTY>
<!ATTLIST Include href CDATA #REQUIRED>
<!ELEMENT MediaCodecs (Decoders|Encoders|Include)*>
<!ELEMENT Decoders (MediaCodec|Include)*>
<!ELEMENT Encoders (MediaCodec|Include)*>
<!ELEMENT MediaCodec (Type|Quirk|Include)*>
<!ATTLIST MediaCodec name CDATA #REQUIRED>
<!ATTLIST MediaCodec type CDATA>
<!ELEMENT Type EMPTY>
<!ATTLIST Type name CDATA #REQUIRED>
<!ELEMENT Quirk EMPTY>
<!ATTLIST Quirk name CDATA #REQUIRED>
]>
There's a simple and a complex syntax to declare the availability of a
media codec:
A codec that properly follows the OpenMax spec and therefore doesn't have any
quirks and that only supports a single content type can be declared like so:
<MediaCodec name="OMX.foo.bar" type="something/interesting" />
If a codec has quirks OR supports multiple content types, the following syntax
can be used:
<MediaCodec name="OMX.foo.bar" >
<Type name="something/interesting" />
<Type name="something/else" />
...
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="output-buffers-are-unreadable" />
</MediaCodec>
Only the three quirks included above are recognized at this point:
"requires-allocate-on-input-ports"
must be advertised if the component does not properly support specification
of input buffers using the OMX_UseBuffer(...) API but instead requires
OMX_AllocateBuffer to be used.
"requires-allocate-on-output-ports"
must be advertised if the component does not properly support specification
of output buffers using the OMX_UseBuffer(...) API but instead requires
OMX_AllocateBuffer to be used.
"output-buffers-are-unreadable"
must be advertised if the emitted output buffers of a decoder component
are not readable, i.e. use a custom format even though abusing one of
the official OMX colorspace constants.
Clients of such decoders will not be able to access the decoded data,
naturally making the component much less useful. The only use for
a component with this quirk is to render the output to the screen.
Audio decoders MUST NOT advertise this quirk.
Video decoders that advertise this quirk must be accompanied by a
corresponding color space converter for thumbnail extraction,
matching surfaceflinger support that can render the custom format to
a texture and possibly other code, so just DON'T USE THIS QUIRK.
-->
<!--
SM6150 Non-Secure decoder capabilities
_________________________________________________________
| Codec | W H fps Mbps MB/s |
|_____________|_________________________________________|
| h264 | 4096 2160 24 100 829440 |
| hevc | 4096 2160 24 100 829440 |
| mpeg4-sw | 1920 1088 30 40 244800 |
| vp8 | 3840 2160 30 100 972000 |
| vp9 | 4096 2160 24 100 829440 |
| vc1 | 1920 1088 30 20 244800 |
| h263-sw | 864 480 30 16 48600 |
| mpeg2 | 1920 1088 30 40 244800 |
|_____________|_________________________________________|
SM6150 Secure decoder capabilities
______________________________________________________
| Codec | W H fps Mbps MB/s |
|__________|_________________________________________|
| h264 | 3840 2160 30 35 972000 |
| vp9 | 3840 2160 30 35 972000 |
| hevc | 3840 2160 30 35 972000 |
| mpeg2 | 1920 1088 30 35 244800 |
|__________|_________________________________________|
SM6150 Non-Secure encoder capabilities (Secure not supported)
______________________________________________________
| Codec | W H fps Mbps MB/s |
|__________|_________________________________________|
| h264 | 4096 2160 24 100 829440 |
| hevc | 4096 2160 24 100 829440 |
| mpeg4-sw | 1280 720 30 4 108000 |
| vp8 | 3840 2160 30 100 972000 |
| h263-sw | 864 480 30 2 48600 |
|__________|_________________________________________|
-->
<MediaCodecs>
<Include href="media_codecs_google_audio.xml" />
<Include href="media_codecs_vendor_audio.xml" />
<Include href="media_codecs_google_telephony.xml" />
<Settings>
<Setting name="max-video-encoder-input-buffers" value="11" />
</Settings>
<Encoders>
<!-- Video Hardware -->
<MediaCodec name="OMX.qcom.video.encoder.avc" type="video/avc" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="requires-loaded-to-idle-after-allocation" />
<Limit name="size" min="96x96" max="4096x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="979200" />
<Limit name="bitrate" range="1-100000000" />
<Limit name="frame-rate" range="1-240" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-4096x2160" value="24" />
<Limit name="performance-point-3840x2160" value="30" />
<Limit name="performance-point-1920x1080" value="120" />
<Limit name="performance-point-1280x720" value="240" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.encoder.vp8" type="video/x-vnd.on2.vp8" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="requires-loaded-to-idle-after-allocation" />
<Limit name="size" min="96x96" max="3840x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="979200" />
<Limit name="bitrate" range="1-120000000" />
<Limit name="frame-rate" range="1-240" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-3840x2160" value="30" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.encoder.hevc" type="video/hevc" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="requires-loaded-to-idle-after-allocation" />
<Limit name="size" min="96x96" max="4096x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="979200" />
<Limit name="bitrate" range="1-100000000" />
<Limit name="frame-rate" range="1-240" />
<Limit name="concurrent-instances" max="16" />
<Limit name="quality" range="0-100" default="80" />
<Limit name="performance-point-4096x2160" value="24" />
<Limit name="performance-point-3840x2160" value="30" />
<Limit name="performance-point-1920x1080" value="120" />
<Limit name="performance-point-1280x720" value="240" />
<Feature name="bitrate-modes" value="VBR,CBR" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.encoder.hevc.cq" type="video/hevc" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="requires-loaded-to-idle-after-allocation" />
<Limit name="size" min="512x512" max="512x512" />
<Limit name="frame-rate" range="1-20" />
<Limit name="concurrent-instances" max="16" />
<Limit name="quality" range="0-100" default="80" />
<Limit name="performance-point-4096x2304" value="24" />
<Limit name="performance-point-3840x2160" value="30" />
<Limit name="performance-point-1920x1080" value="120" />
<Limit name="performance-point-1280x720" value="240" />
<Feature name="bitrate-modes" value="CQ" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.encoder.heic" type="image/vnd.android.heic" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="requires-loaded-to-idle-after-allocation" />
<Limit name="size" min="512x512" max="8192x8192" />
<Limit name="frame-rate" range="1-20" />
<Limit name="concurrent-instances" max="6" />
<Limit name="quality" range="0-100" default="80" />
<Feature name="bitrate-modes" value="CQ" />
<Limit name="performance-point-8192x4320" value="3" />
<Limit name="performance-point-1920x1080" value="6" />
</MediaCodec>
<!-- Video Software -->
<MediaCodec name="OMX.qcom.video.encoder.h263sw" type="video/3gpp" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="requires-loaded-to-idle-after-allocation" />
<Limit name="size" min="96x96" max="864x480" />
<Limit name="alignment" value="4x4" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="48600" />
<Limit name="bitrate" range="1-2000000" />
<Limit name="frame-rate" range="1-30" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-864x480" value="30" />
<Limit name="performance-point-720x480" value="30" />
<Limit name="performance-point-720x576" value="25" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.encoder.mpeg4sw" type="video/mp4v-es" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Quirk name="requires-loaded-to-idle-after-allocation" />
<Limit name="size" min="96x96" max="864x480" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="48600" />
<Limit name="bitrate" range="1-8000000" />
<Limit name="frame-rate" range="1-30" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-864x480" value="30" />
<Limit name="performance-point-720x480" value="30" />
<Limit name="performance-point-720x576" value="25" />
</MediaCodec>
</Encoders>
<Decoders>
<!-- Video Hardware -->
<MediaCodec name="OMX.qcom.video.decoder.avc" type="video/avc" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="4096x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="979200" />
<Limit name="bitrate" range="1-100000000" />
<Limit name="frame-rate" range="1-240" />
<Feature name="adaptive-playback" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-4096x2160" value="24" />
<Limit name="performance-point-3840x2160" value="30" />
<Limit name="performance-point-1920x1080" value="120" />
<Limit name="performance-point-1280x720" value="240" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.avc.secure" type="video/avc" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="3840x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="972000" />
<Limit name="bitrate" range="1-35000000" />
<Limit name="frame-rate" range="1-30" />
<Feature name="adaptive-playback" />
<Feature name="secure-playback" required="true" />
<Limit name="concurrent-instances" max="3" />
<Limit name="performance-point-3840x2160" value="30" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.mpeg2" type="video/mpeg2" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="1920x1088" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="244800" />
<Limit name="bitrate" range="1-40000000" />
<Limit name="frame-rate" range="1-30" />
<Feature name="adaptive-playback" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-1920x1080" value="30" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.mpeg2.secure" type="video/mpeg2" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="1920x1088" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="244800" />
<Limit name="bitrate" range="1-35000000" />
<Limit name="frame-rate" range="1-30" />
<Feature name="adaptive-playback" />
<Feature name="secure-playback" required="true" />
<Limit name="concurrent-instances" max="3" />
<Limit name="performance-point-1920x1080" value="30" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.vp8" type="video/x-vnd.on2.vp8" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="3840x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="979200" />
<Limit name="bitrate" range="1-100000000" />
<Limit name="frame-rate" range="1-240" />
<Feature name="adaptive-playback" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-3840x2160" value="30" />
<Limit name="performance-point-1920x1080" value="60" />
<Limit name="performance-point-1280x720" value="120" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.vp9" type="video/x-vnd.on2.vp9" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="4096x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="979200" />
<Limit name="bitrate" range="1-120000000" />
<Limit name="frame-rate" range="1-240" />
<Feature name="adaptive-playback" />
<Limit name="concurrent-instances" max="6" />
<Limit name="performance-point-4096x2160" value="24" />
<Limit name="performance-point-3840x2160" value="30" />
<Limit name="performance-point-1920x1080" value="120" />
<Limit name="performance-point-1280x720" value="240" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.vp9.secure" type="video/x-vnd.on2.vp9" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="3840x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="972000" />
<Limit name="bitrate" range="1-35000000" />
<Limit name="frame-rate" range="1-30" />
<Feature name="adaptive-playback" />
<Feature name="secure-playback" required="true" />
<Limit name="concurrent-instances" max="3" />
<Limit name="performance-point-3840x2160" value="30" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.hevc" type="video/hevc" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="4096x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="979200" />
<Limit name="bitrate" range="1-100000000" />
<Limit name="frame-rate" range="1-240" />
<Feature name="adaptive-playback" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-4096x2160" value="24" />
<Limit name="performance-point-3840x2160" value="30" />
<Limit name="performance-point-1920x1080" value="120" />
<Limit name="performance-point-1280x720" value="240" />
</MediaCodec>
<MediaCodec name="OMX.qcom.video.decoder.hevc.secure" type="video/hevc" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="3840x2160" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="972000" />
<Limit name="bitrate" range="1-35000000" />
<Limit name="frame-rate" range="1-30" />
<Feature name="adaptive-playback" />
<Feature name="secure-playback" required="true" />
<Limit name="concurrent-instances" max="3" />
<Limit name="performance-point-3840x2160" value="30" />
</MediaCodec>
<!-- Video Software -->
<MediaCodec name="OMX.qti.video.decoder.h263sw" type="video/3gpp" >
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="864x480" />
<Limit name="alignment" value="4x4" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="48600" />
<Limit name="bitrate" range="1-16000000" />
<Limit name="frame-rate" range="1-30" />
<Feature name="adaptive-playback" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-864x480" value="30" />
<Limit name="performance-point-720x480" value="30" />
<Limit name="performance-point-720x576" value="25" />
</MediaCodec>
<MediaCodec name="OMX.qti.video.decoder.mpeg4sw" type="video/mp4v-es">
<Quirk name="requires-allocate-on-input-ports" />
<Quirk name="requires-allocate-on-output-ports" />
<Limit name="size" min="96x96" max="1920x1088" />
<Limit name="alignment" value="2x2" />
<Limit name="block-size" value="16x16" />
<Limit name="blocks-per-second" min="36" max="244800" />
<Limit name="bitrate" range="1-40000000" />
<Limit name="frame-rate" range="1-30" />
<Limit name="concurrent-instances" max="16" />
<Limit name="performance-point-1920x1080" value="30" />
</MediaCodec>
</Decoders>
<Include href="media_codecs_google_video.xml" />
</MediaCodecs>

View File

@ -0,0 +1,27 @@
<?xml version="1.0" encoding="utf-8" ?>
<!-- Copyright (C) 2015-2020 The Linux Foundation. All rights reserved.
Not a contribution.
Copyright (C) 2012 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<Included>
<Decoders>
<MediaCodec name="OMX.google.opus.decoder" type="audio/opus" update="true" rank="100"/>
<MediaCodec name="OMX.google.raw.decoder" type="audio/raw" update="true" rank="1"/>
<!-- SimpleOMXComponet based software decoder-->
<MediaCodec name="OMX.qti.audio.decoder.mpegh" type="audio/mhas" rank="0">
<Limit name="concurrent-instances" max="1" />
</MediaCodec>
</Decoders>
</Included>

867
media/media_profiles.xml Normal file
View File

@ -0,0 +1,867 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright 2013 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!DOCTYPE MediaSettings [
<!ELEMENT MediaSettings (CamcorderProfiles,
EncoderOutputFileFormat+,
VideoEncoderCap+,
AudioEncoderCap+,
VideoDecoderCap,
AudioDecoderCap)>
<!ELEMENT CamcorderProfiles (EncoderProfile+, ImageEncoding+, ImageDecoding, Camera)>
<!ELEMENT EncoderProfile (Video, Audio)>
<!ATTLIST EncoderProfile quality (high|low) #REQUIRED>
<!ATTLIST EncoderProfile fileFormat (mp4|3gp) #REQUIRED>
<!ATTLIST EncoderProfile duration (30|60) #REQUIRED>
<!ATTLIST EncoderProfile cameraId (0|1|2|3|4|5) #REQUIRED>
<!ELEMENT Video EMPTY>
<!ATTLIST Video codec (h264|h263|m4v) #REQUIRED>
<!ATTLIST Video bitRate CDATA #REQUIRED>
<!ATTLIST Video width CDATA #REQUIRED>
<!ATTLIST Video height CDATA #REQUIRED>
<!ATTLIST Video frameRate CDATA #REQUIRED>
<!ELEMENT Audio EMPTY>
<!ATTLIST Audio codec (amrnb|amrwb|aac) #REQUIRED>
<!ATTLIST Audio bitRate CDATA #REQUIRED>
<!ATTLIST Audio sampleRate CDATA #REQUIRED>
<!ATTLIST Audio channels (1|2) #REQUIRED>
<!ELEMENT ImageEncoding EMPTY>
<!ATTLIST ImageEncoding quality (90|80|70|60|50|40) #REQUIRED>
<!ELEMENT ImageDecoding EMPTY>
<!ATTLIST ImageDecoding memCap CDATA #REQUIRED>
<!ELEMENT Camera EMPTY>
<!ELEMENT EncoderOutputFileFormat EMPTY>
<!ATTLIST EncoderOutputFileFormat name (mp4|3gp) #REQUIRED>
<!ELEMENT VideoEncoderCap EMPTY>
<!ATTLIST VideoEncoderCap name (h264|h263|m4v|wmv) #REQUIRED>
<!ATTLIST VideoEncoderCap enabled (true|false) #REQUIRED>
<!ATTLIST VideoEncoderCap minBitRate CDATA #REQUIRED>
<!ATTLIST VideoEncoderCap maxBitRate CDATA #REQUIRED>
<!ATTLIST VideoEncoderCap minFrameWidth CDATA #REQUIRED>
<!ATTLIST VideoEncoderCap maxFrameWidth CDATA #REQUIRED>
<!ATTLIST VideoEncoderCap minFrameHeight CDATA #REQUIRED>
<!ATTLIST VideoEncoderCap maxFrameHeight CDATA #REQUIRED>
<!ATTLIST VideoEncoderCap minFrameRate CDATA #REQUIRED>
<!ATTLIST VideoEncoderCap maxFrameRate CDATA #REQUIRED>
<!ELEMENT AudioEncoderCap EMPTY>
<!ATTLIST AudioEncoderCap name (amrnb|amrwb|aac|wma) #REQUIRED>
<!ATTLIST AudioEncoderCap enabled (true|false) #REQUIRED>
<!ATTLIST AudioEncoderCap minBitRate CDATA #REQUIRED>
<!ATTLIST AudioEncoderCap maxBitRate CDATA #REQUIRED>
<!ATTLIST AudioEncoderCap minSampleRate CDATA #REQUIRED>
<!ATTLIST AudioEncoderCap maxSampleRate CDATA #REQUIRED>
<!ATTLIST AudioEncoderCap minChannels (1|2) #REQUIRED>
<!ATTLIST AudioEncoderCap maxChannels (1|2) #REQUIRED>
<!ELEMENT VideoDecoderCap EMPTY>
<!ATTLIST VideoDecoderCap name (wmv) #REQUIRED>
<!ATTLIST VideoDecoderCap enabled (true|false) #REQUIRED>
<!ELEMENT AudioDecoderCap EMPTY>
<!ATTLIST AudioDecoderCap name (wma) #REQUIRED>
<!ATTLIST AudioDecoderCap enabled (true|false) #REQUIRED>
]>
<!--
This file is used to declare the multimedia profiles and capabilities
on an android-powered device.
-->
<MediaSettings>
<!-- Each camcorder profile defines a set of predefined configuration parameters -->
<CamcorderProfiles cameraId="0">
<EncoderProfile quality="qvga" fileFormat="3gp" duration="60">
<Video codec="h264"
bitRate="128000"
width="320"
height="240"
frameRate="30" />
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="cif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="1080p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="17000000"
width="1920"
height="1080"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapseqcif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="192000"
width="176"
height="144"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapsecif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse1080p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="17000000"
width="1920"
height="1080"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<ImageEncoding quality="95" />
<ImageEncoding quality="80" />
<ImageEncoding quality="70" />
<ImageDecoding memCap="20000000" />
</CamcorderProfiles>
<CamcorderProfiles cameraId="1">
<EncoderProfile quality="qvga" fileFormat="3gp" duration="60">
<Video codec="h264"
bitRate="128000"
width="320"
height="240"
frameRate="30" />
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="cif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapseqcif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="192000"
width="176"
height="144"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapsecif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<ImageEncoding quality="95" />
<ImageEncoding quality="80" />
<ImageEncoding quality="70" />
<ImageDecoding memCap="20000000" />
</CamcorderProfiles>
<CamcorderProfiles cameraId="2">
<EncoderProfile quality="qvga" fileFormat="3gp" duration="60">
<Video codec="h264"
bitRate="128000"
width="320"
height="240"
frameRate="30" />
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="cif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="1080p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="17000000"
width="1920"
height="1080"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapseqcif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="192000"
width="176"
height="144"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapsecif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse1080p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="17000000"
width="1920"
height="1080"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<ImageEncoding quality="95" />
<ImageEncoding quality="80" />
<ImageEncoding quality="70" />
<ImageDecoding memCap="20000000" />
</CamcorderProfiles>
<CamcorderProfiles cameraId="3">
<EncoderProfile quality="qvga" fileFormat="3gp" duration="60">
<Video codec="h264"
bitRate="128000"
width="320"
height="240"
frameRate="30" />
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="cif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapseqcif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="192000"
width="176"
height="144"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapsecif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<ImageEncoding quality="95" />
<ImageEncoding quality="80" />
<ImageEncoding quality="70" />
<ImageDecoding memCap="20000000" />
</CamcorderProfiles>
<CamcorderProfiles cameraId="4">
<EncoderProfile quality="qvga" fileFormat="3gp" duration="60">
<Video codec="h264"
bitRate="128000"
width="320"
height="240"
frameRate="30" />
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="cif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="1080p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="17000000"
width="1920"
height="1080"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapseqcif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="192000"
width="176"
height="144"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapsecif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse1080p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="17000000"
width="1920"
height="1080"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<ImageEncoding quality="95" />
<ImageEncoding quality="80" />
<ImageEncoding quality="70" />
<ImageDecoding memCap="20000000" />
</CamcorderProfiles>
<CamcorderProfiles cameraId="5">
<EncoderProfile quality="qvga" fileFormat="3gp" duration="60">
<Video codec="h264"
bitRate="128000"
width="320"
height="240"
frameRate="30" />
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="cif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapseqcif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="192000"
width="176"
height="144"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapsecif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<ImageEncoding quality="95" />
<ImageEncoding quality="80" />
<ImageEncoding quality="70" />
<ImageDecoding memCap="20000000" />
</CamcorderProfiles>
<EncoderOutputFileFormat name="3gp" />
<EncoderOutputFileFormat name="mp4" />
<!--
If a codec is not enabled, it is invisible to the applications
In other words, the applications won't be able to use the codec
or query the capabilities of the codec at all if it is disabled
-->
<VideoEncoderCap name="h264" enabled="true"
minBitRate="64000" maxBitRate="40000000"
minFrameWidth="176" maxFrameWidth="1920"
minFrameHeight="144" maxFrameHeight="1080"
minFrameRate="15" maxFrameRate="30" />
<VideoEncoderCap name="h263" enabled="true"
minBitRate="64000" maxBitRate="2000000"
minFrameWidth="176" maxFrameWidth="800"
minFrameHeight="144" maxFrameHeight="480"
minFrameRate="15" maxFrameRate="30" />
<VideoEncoderCap name="m4v" enabled="true"
minBitRate="64000" maxBitRate="40000000"
minFrameWidth="176" maxFrameWidth="1920"
minFrameHeight="144" maxFrameHeight="1080"
minFrameRate="15" maxFrameRate="30" />
<AudioEncoderCap name="aac" enabled="true"
minBitRate="758" maxBitRate="288000"
minSampleRate="8000" maxSampleRate="48000"
minChannels="1" maxChannels="2" />
<AudioEncoderCap name="heaac" enabled="true"
minBitRate="8000" maxBitRate="64000"
minSampleRate="16000" maxSampleRate="48000"
minChannels="1" maxChannels="2" />
<AudioEncoderCap name="aaceld" enabled="true"
minBitRate="16000" maxBitRate="192000"
minSampleRate="16000" maxSampleRate="48000"
minChannels="1" maxChannels="2" />
<AudioEncoderCap name="amrwb" enabled="true"
minBitRate="6600" maxBitRate="23050"
minSampleRate="16000" maxSampleRate="16000"
minChannels="1" maxChannels="1" />
<AudioEncoderCap name="amrnb" enabled="true"
minBitRate="5525" maxBitRate="12200"
minSampleRate="8000" maxSampleRate="8000"
minChannels="1" maxChannels="1" />
<!--
FIXME:
We do not check decoder capabilities at present
At present, we only check whether windows media is visible
for TEST applications. For other applications, we do
not perform any checks at all.
-->
<VideoDecoderCap name="wmv" enabled="false"/>
<AudioDecoderCap name="wma" enabled="false"/>
</MediaSettings>

View File

@ -0,0 +1,867 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright 2013 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!DOCTYPE MediaSettings [
<!ELEMENT MediaSettings (CamcorderProfiles,
EncoderOutputFileFormat+,
VideoEncoderCap+,
AudioEncoderCap+,
VideoDecoderCap,
AudioDecoderCap)>
<!ELEMENT CamcorderProfiles (EncoderProfile+, ImageEncoding+, ImageDecoding, Camera)>
<!ELEMENT EncoderProfile (Video, Audio)>
<!ATTLIST EncoderProfile quality (high|low) #REQUIRED>
<!ATTLIST EncoderProfile fileFormat (mp4|3gp) #REQUIRED>
<!ATTLIST EncoderProfile duration (30|60) #REQUIRED>
<!ATTLIST EncoderProfile cameraId (0|1|2|3|4|5) #REQUIRED>
<!ELEMENT Video EMPTY>
<!ATTLIST Video codec (h264|h263|m4v) #REQUIRED>
<!ATTLIST Video bitRate CDATA #REQUIRED>
<!ATTLIST Video width CDATA #REQUIRED>
<!ATTLIST Video height CDATA #REQUIRED>
<!ATTLIST Video frameRate CDATA #REQUIRED>
<!ELEMENT Audio EMPTY>
<!ATTLIST Audio codec (amrnb|amrwb|aac) #REQUIRED>
<!ATTLIST Audio bitRate CDATA #REQUIRED>
<!ATTLIST Audio sampleRate CDATA #REQUIRED>
<!ATTLIST Audio channels (1|2) #REQUIRED>
<!ELEMENT ImageEncoding EMPTY>
<!ATTLIST ImageEncoding quality (90|80|70|60|50|40) #REQUIRED>
<!ELEMENT ImageDecoding EMPTY>
<!ATTLIST ImageDecoding memCap CDATA #REQUIRED>
<!ELEMENT Camera EMPTY>
<!ELEMENT EncoderOutputFileFormat EMPTY>
<!ATTLIST EncoderOutputFileFormat name (mp4|3gp) #REQUIRED>
<!ELEMENT VideoEncoderCap EMPTY>
<!ATTLIST VideoEncoderCap name (h264|h263|m4v|wmv) #REQUIRED>
<!ATTLIST VideoEncoderCap enabled (true|false) #REQUIRED>
<!ATTLIST VideoEncoderCap minBitRate CDATA #REQUIRED>
<!ATTLIST VideoEncoderCap maxBitRate CDATA #REQUIRED>
<!ATTLIST VideoEncoderCap minFrameWidth CDATA #REQUIRED>
<!ATTLIST VideoEncoderCap maxFrameWidth CDATA #REQUIRED>
<!ATTLIST VideoEncoderCap minFrameHeight CDATA #REQUIRED>
<!ATTLIST VideoEncoderCap maxFrameHeight CDATA #REQUIRED>
<!ATTLIST VideoEncoderCap minFrameRate CDATA #REQUIRED>
<!ATTLIST VideoEncoderCap maxFrameRate CDATA #REQUIRED>
<!ELEMENT AudioEncoderCap EMPTY>
<!ATTLIST AudioEncoderCap name (amrnb|amrwb|aac|wma) #REQUIRED>
<!ATTLIST AudioEncoderCap enabled (true|false) #REQUIRED>
<!ATTLIST AudioEncoderCap minBitRate CDATA #REQUIRED>
<!ATTLIST AudioEncoderCap maxBitRate CDATA #REQUIRED>
<!ATTLIST AudioEncoderCap minSampleRate CDATA #REQUIRED>
<!ATTLIST AudioEncoderCap maxSampleRate CDATA #REQUIRED>
<!ATTLIST AudioEncoderCap minChannels (1|2) #REQUIRED>
<!ATTLIST AudioEncoderCap maxChannels (1|2) #REQUIRED>
<!ELEMENT VideoDecoderCap EMPTY>
<!ATTLIST VideoDecoderCap name (wmv) #REQUIRED>
<!ATTLIST VideoDecoderCap enabled (true|false) #REQUIRED>
<!ELEMENT AudioDecoderCap EMPTY>
<!ATTLIST AudioDecoderCap name (wma) #REQUIRED>
<!ATTLIST AudioDecoderCap enabled (true|false) #REQUIRED>
]>
<!--
This file is used to declare the multimedia profiles and capabilities
on an android-powered device.
-->
<MediaSettings>
<!-- Each camcorder profile defines a set of predefined configuration parameters -->
<CamcorderProfiles cameraId="0">
<EncoderProfile quality="qvga" fileFormat="3gp" duration="60">
<Video codec="h264"
bitRate="128000"
width="320"
height="240"
frameRate="30" />
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="cif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="1080p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="17000000"
width="1920"
height="1080"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapseqcif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="192000"
width="176"
height="144"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapsecif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse1080p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="17000000"
width="1920"
height="1080"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<ImageEncoding quality="95" />
<ImageEncoding quality="80" />
<ImageEncoding quality="70" />
<ImageDecoding memCap="20000000" />
</CamcorderProfiles>
<CamcorderProfiles cameraId="1">
<EncoderProfile quality="qvga" fileFormat="3gp" duration="60">
<Video codec="h264"
bitRate="128000"
width="320"
height="240"
frameRate="30" />
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="cif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapseqcif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="192000"
width="176"
height="144"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapsecif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<ImageEncoding quality="95" />
<ImageEncoding quality="80" />
<ImageEncoding quality="70" />
<ImageDecoding memCap="20000000" />
</CamcorderProfiles>
<CamcorderProfiles cameraId="2">
<EncoderProfile quality="qvga" fileFormat="3gp" duration="60">
<Video codec="h264"
bitRate="128000"
width="320"
height="240"
frameRate="30" />
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="cif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="1080p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="17000000"
width="1920"
height="1080"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapseqcif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="192000"
width="176"
height="144"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapsecif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse1080p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="17000000"
width="1920"
height="1080"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<ImageEncoding quality="95" />
<ImageEncoding quality="80" />
<ImageEncoding quality="70" />
<ImageDecoding memCap="20000000" />
</CamcorderProfiles>
<CamcorderProfiles cameraId="3">
<EncoderProfile quality="qvga" fileFormat="3gp" duration="60">
<Video codec="h264"
bitRate="128000"
width="320"
height="240"
frameRate="30" />
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="cif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapseqcif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="192000"
width="176"
height="144"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapsecif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<ImageEncoding quality="95" />
<ImageEncoding quality="80" />
<ImageEncoding quality="70" />
<ImageDecoding memCap="20000000" />
</CamcorderProfiles>
<CamcorderProfiles cameraId="4">
<EncoderProfile quality="qvga" fileFormat="3gp" duration="60">
<Video codec="h264"
bitRate="128000"
width="320"
height="240"
frameRate="30" />
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="cif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="1080p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="17000000"
width="1920"
height="1080"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapseqcif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="192000"
width="176"
height="144"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapsecif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse1080p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="17000000"
width="1920"
height="1080"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<ImageEncoding quality="95" />
<ImageEncoding quality="80" />
<ImageEncoding quality="70" />
<ImageDecoding memCap="20000000" />
</CamcorderProfiles>
<CamcorderProfiles cameraId="5">
<EncoderProfile quality="qvga" fileFormat="3gp" duration="60">
<Video codec="h264"
bitRate="128000"
width="320"
height="240"
frameRate="30" />
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="cif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapseqcif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="192000"
width="176"
height="144"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="amrnb"
bitRate="12200"
sampleRate="8000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapsecif" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="1200000"
width="352"
height="288"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="6000000"
width="720"
height="480"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30">
<Video codec="h264"
bitRate="12000000"
width="1280"
height="720"
frameRate="30" />
<!-- audio setting is ignored -->
<Audio codec="aac"
bitRate="96000"
sampleRate="48000"
channels="1" />
</EncoderProfile>
<ImageEncoding quality="95" />
<ImageEncoding quality="80" />
<ImageEncoding quality="70" />
<ImageDecoding memCap="20000000" />
</CamcorderProfiles>
<EncoderOutputFileFormat name="3gp" />
<EncoderOutputFileFormat name="mp4" />
<!--
If a codec is not enabled, it is invisible to the applications
In other words, the applications won't be able to use the codec
or query the capabilities of the codec at all if it is disabled
-->
<VideoEncoderCap name="h264" enabled="true"
minBitRate="64000" maxBitRate="40000000"
minFrameWidth="176" maxFrameWidth="1920"
minFrameHeight="144" maxFrameHeight="1080"
minFrameRate="15" maxFrameRate="30" />
<VideoEncoderCap name="h263" enabled="true"
minBitRate="64000" maxBitRate="2000000"
minFrameWidth="176" maxFrameWidth="800"
minFrameHeight="144" maxFrameHeight="480"
minFrameRate="15" maxFrameRate="30" />
<VideoEncoderCap name="m4v" enabled="true"
minBitRate="64000" maxBitRate="40000000"
minFrameWidth="176" maxFrameWidth="1920"
minFrameHeight="144" maxFrameHeight="1080"
minFrameRate="15" maxFrameRate="30" />
<AudioEncoderCap name="aac" enabled="true"
minBitRate="758" maxBitRate="288000"
minSampleRate="8000" maxSampleRate="48000"
minChannels="1" maxChannels="2" />
<AudioEncoderCap name="heaac" enabled="true"
minBitRate="8000" maxBitRate="64000"
minSampleRate="16000" maxSampleRate="48000"
minChannels="1" maxChannels="2" />
<AudioEncoderCap name="aaceld" enabled="true"
minBitRate="16000" maxBitRate="192000"
minSampleRate="16000" maxSampleRate="48000"
minChannels="1" maxChannels="2" />
<AudioEncoderCap name="amrwb" enabled="true"
minBitRate="6600" maxBitRate="23050"
minSampleRate="16000" maxSampleRate="16000"
minChannels="1" maxChannels="1" />
<AudioEncoderCap name="amrnb" enabled="true"
minBitRate="5525" maxBitRate="12200"
minSampleRate="8000" maxSampleRate="8000"
minChannels="1" maxChannels="1" />
<!--
FIXME:
We do not check decoder capabilities at present
At present, we only check whether windows media is visible
for TEST applications. For other applications, we do
not perform any checks at all.
-->
<VideoDecoderCap name="wmv" enabled="false"/>
<AudioDecoderCap name="wma" enabled="false"/>
</MediaSettings>

File diff suppressed because it is too large Load Diff

2
odm.prop Normal file
View File

@ -0,0 +1,2 @@
# Fwk detect
ro.vendor.qti.va_odm.support=1

View File

@ -0,0 +1,9 @@
//
// Copyright (C) 2022 The LineageOS Project
// SPDX-License-Identifier: Apache-2.0
//
runtime_resource_overlay {
name: "SM6250LineageDialer",
product_specific: true,
}

View File

@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2022 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.dialer.xiaomi_sm6250">
<overlay
android:isStatic="true"
android:priority="100"
android:targetPackage="com.android.dialer" />
</manifest>

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2016 The CyanogenMod Project
Copyright (C) 2022 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources>
<bool name="call_recording_enabled">true</bool>
<!-- 1 (MIC) for microphone audio source (default)
4 (VOICE_CALL) if supported by device for voice call uplink + downlink audio source -->
<integer name="call_recording_audio_source">4</integer>
</resources>

View File

@ -0,0 +1,9 @@
//
// Copyright (C) 2022 The LineageOS Project
// SPDX-License-Identifier: Apache-2.0
//
runtime_resource_overlay {
name: "SM6250LineageSDK",
product_specific: true,
}

View File

@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2022 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="lineageos.platform.xiaomi_sm6250">
<overlay
android:isStatic="true"
android:priority="100"
android:targetPackage="lineageos.platform" />
</manifest>

View File

@ -0,0 +1,81 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2022 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources>
<!-- Hardware keys present on the device, stored as a bit field.
This integer should equal the sum of the corresponding value for each
of the following keys present:
1 - Home
2 - Back
4 - Menu
8 - Assistant (search)
16 - App switch
32 - Camera
64 - Volume rocker
For example, a device with Home, Back and Menu keys would set this
config to 7. -->
<integer name="config_deviceHardwareKeys">64</integer>
<!-- Hardware keys present on the device with the ability to wake, stored as a bit field.
This integer should equal the sum of the corresponding value for each
of the following keys present:
1 - Home
2 - Back
4 - Menu
8 - Assistant (search)
16 - App switch
32 - Camera
64 - Volume rocker
For example, a device with Home, Back and Menu keys would set this
config to 7. -->
<integer name="config_deviceHardwareWakeKeys">64</integer>
<!-- All the capabilities of the LEDs on this device, stored as a bit field.
This integer should equal the sum of the corresponding value for each
of the following capabilities present:
// Device has a color adjustable battery light.
LIGHTS_RGB_NOTIFICATION_LED = 1
// Device has a color adjustable notification light.
LIGHTS_RGB_BATTERY_LED = 2
LIGHTS_MULTIPLE_NOTIFICATION_LED = 4 (deprecated)
// The notification light has adjustable pulsing capability.
LIGHTS_PULSATING_LED = 8
// Device has a multi-segment battery light that is able to
// use the light brightness value to determine how many
// segments to show (in order to represent battery level).
LIGHTS_SEGMENTED_BATTERY_LED = 16
// The notification light supports HAL adjustable brightness
// via the alpha channel.
// Note: if a device notification light supports LIGHTS_RGB_NOTIFICATION_LED
// then HAL support is not necessary for brightness control. In this case,
// brightness support will be provided by lineage-sdk through the scaling of
// RGB color values.
LIGHTS_ADJUSTABLE_NOTIFICATION_LED_BRIGHTNESS = 32
// Device has a battery light.
LIGHTS_BATTERY_LED = 64
// The battery light supports HAL adjustable brightness via
// the alpha channel.
// Note: if a device battery light supports LIGHTS_RGB_BATTERY_LED then HAL
// support is not necessary for brightness control. In this case,
// brightness support will be provided by lineage-sdk through the scaling of
// RGB color values.
LIGHTS_ADJUSTABLE_BATTERY_LED_BRIGHTNESS = 128
For example, a device with notification and battery lights that supports
pulsating and RGB control would set this config to 75. -->
<integer name="config_deviceLightCapabilities">232</integer>
<!-- Whether device has screen with higher aspect ratio -->
<bool name="config_haveHigherAspectRatioScreen">true</bool>
<!-- Defines the actions shown in advanced reboot submenu -->
<string-array name="config_restartActionsList">
<item>restart</item>
<item>restart_recovery</item>
<item>restart_bootloader</item>
<item>restart_fastboot</item>
</string-array>
</resources>

View File

@ -0,0 +1,10 @@
//
// Copyright (C) 2022 The LineageOS Project
// SPDX-License-Identifier: Apache-2.0
//
runtime_resource_overlay {
name: "CarrierConfigResCommon",
aaptflags: ["--keep-raw-values"],
product_specific: true,
}

View File

@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2022 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.carrierconfig.overlay.common">
<overlay
android:isStatic="true"
android:priority="100"
android:targetPackage="com.android.carrierconfig" />
</manifest>

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,9 @@
//
// Copyright (C) 2022 The LineageOS Project
// SPDX-License-Identifier: Apache-2.0
//
runtime_resource_overlay {
name: "SM6250Frameworks",
vendor: true,
}

View File

@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2022 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="android.xiaomi_sm6250">
<overlay
android:isStatic="true"
android:priority="100"
android:targetPackage="android" />
</manifest>

View File

@ -0,0 +1,570 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2022 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources>
<!-- The default journal mode to use use when Write-Ahead Logging is not active.
Choices are: OFF, DELETE, TRUNCATE, PERSIST and MEMORY.
PERSIST may improve performance by reducing how often journal blocks are
reallocated (compared to truncation) resulting in better data block locality
and less churn of the storage media.
The PERSIST mode results in data persisting in the journal beyond the life of
a transaction, so it interacts poorly with SECURE_DELETE. -->
<string name="db_default_journal_mode" translatable="false">MEMORY</string>
<!-- The database synchronization mode when using the default journal mode.
FULL is safest and preserves durability at the cost of extra fsyncs.
NORMAL also preserves durability in non-WAL modes and uses checksums to ensure
integrity although there is a small chance that an error might go unnoticed.
Choices are: FULL, NORMAL, OFF. -->
<string name="db_default_sync_mode" translatable="false">OFF</string>
<!-- The database synchronization mode when using Write-Ahead Logging.
From https://www.sqlite.org/pragma.html#pragma_synchronous:
WAL mode is safe from corruption with synchronous=NORMAL, and probably DELETE mode is safe
too on modern filesystems. WAL mode is always consistent with synchronous=NORMAL, but WAL
mode does lose durability. A transaction committed in WAL mode with
synchronous=NORMAL might roll back following a power loss or system crash.
Transactions are durable across application crashes regardless of the synchronous setting
or journal mode. The synchronous=NORMAL setting is a good choice for most applications
running in WAL mode.
Choices are: FULL, NORMAL, OFF. -->
<string name="db_wal_sync_mode" translatable="false">OFF</string>
<!-- Color mode to use when accessibility transforms are enabled. This color mode must be
supported by the device, but not necessarily appear in config_availableColorModes. The
regularly selected color mode will be used if this value is negative. -->
<integer name="config_accessibilityColorMode">2</integer>
<!-- Array of hysteresis constraint values for brightening, represented as tenths of a
percent. The length of this array is assumed to be one greater than
config_ambientThresholdLevels. The brightening threshold is calculated as
lux * (1.0f + CONSTRAINT_VALUE). When the current lux is higher than this threshold,
the screen brightness is recalculated. See the config_ambientThresholdLevels
description for how the constraint value is chosen. -->
<integer-array name="config_ambientBrighteningThresholds">
<item>11373</item>
<item>5000</item>
<item>4333</item>
<item>3666</item>
<item>3000</item>
<item>2760</item>
<item>2520</item>
<item>2280</item>
<item>2040</item>
<item>1800</item>
<item>800</item>
<item>527</item>
<item>500</item>
<item>470</item>
<item>396</item>
<item>322</item>
<item>248</item>
<item>174</item>
<item>99</item>
<item>99</item>
</integer-array>
<!-- Array of hysteresis constraint values for darkening, represented as tenths of a
percent. The length of this array is assumed to be one greater than
config_ambientThresholdLevels. The darkening threshold is calculated as
lux * (1.0f - CONSTRAINT_VALUE). When the current lux is lower than this threshold,
the screen brightness is recalculated. See the config_ambientThresholdLevels
description for how the constraint value is chosen. -->
<integer-array name="config_ambientDarkeningThresholds">
<item>853</item>
<item>700</item>
<item>683</item>
<item>666</item>
<item>650</item>
<item>640</item>
<item>630</item>
<item>620</item>
<item>610</item>
<item>600</item>
<item>500</item>
<item>500</item>
<item>440</item>
<item>385</item>
<item>348</item>
<item>311</item>
<item>274</item>
<item>237</item>
<item>200</item>
<item>200</item>
</integer-array>
<!-- Array of ambient lux threshold values. This is used for determining hysteresis constraint
values by calculating the index to use for lookup and then setting the constraint value
to the corresponding value of the array. The new brightening hysteresis constraint value
is the n-th element of config_ambientBrighteningThresholds, and the new darkening
hysteresis constraint value is the n-th element of config_ambientDarkeningThresholds.
The (zero-based) index is calculated as follows: (MAX is the largest index of the array)
condition calculated index
value < level[0] 0
level[n] <= value < level[n+1] n+1
level[MAX] <= value MAX+1 -->
<integer-array name="config_ambientThresholdLevels">
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
<item>5</item>
<item>6</item>
<item>7</item>
<item>8</item>
<item>9</item>
<item>10</item>
<item>20</item>
<item>30</item>
<item>40</item>
<item>50</item>
<item>60</item>
<item>70</item>
<item>80</item>
<item>90</item>
<item>100</item>
</integer-array>
<!-- Stability requirements in milliseconds for accepting a new brightness level. This is used
for debouncing the light sensor. Different constants are used to debounce the light sensor
when adapting to brighter or darker environments. This parameter controls how quickly
brightness changes occur in response to an observed change in light level that exceeds the
hysteresis threshold. -->
<integer name="config_autoBrightnessBrighteningLightDebounce">2000</integer>
<integer name="config_autoBrightnessDarkeningLightDebounce">4000</integer>
<!-- Array of desired screen brightness in nits corresponding to the lux values
in the config_autoBrightnessLevels array. As with config_screenBrightnessMinimumNits and
config_screenBrightnessMaximumNits, the display brightness is defined as the measured
brightness of an all-white image.
If this is defined then:
- config_autoBrightnessLcdBacklightValues should not be defined
- config_screenBrightnessNits must be defined
- config_screenBrightnessBacklight must be defined
This array should have size one greater than the size of the config_autoBrightnessLevels
array. The brightness values must be non-negative and non-decreasing. This must be
overridden in platform specific overlays -->
<integer-array name="config_autoBrightnessDisplayValuesNits">
<item>5</item> <!-- 0 - 1 -->
<item>10</item> <!-- 1 - 2 -->
<item>18</item> <!-- 2 - 3 -->
<item>22</item> <!-- 3 - 4 -->
<item>24</item> <!-- 4 - 8 -->
<item>31</item> <!-- 8 - 12 -->
<item>35</item> <!-- 12 - 20 -->
<item>41</item> <!-- 20 - 33 -->
<item>48</item> <!-- 33 - 55 -->
<item>56</item> <!-- 55 - 90 -->
<item>66</item> <!-- 90 - 148 -->
<item>80</item> <!-- 148 - 245 -->
<item>98</item> <!-- 245 - 403 -->
<item>125</item> <!-- 403 - 665 -->
<item>162</item> <!-- 665 - 1097 -->
<item>208</item> <!-- 1097 - 1808 -->
<item>265</item> <!-- 1808 - 2981 -->
<item>328</item> <!-- 2981 - 5000 -->
<item>450</item> <!-- 5000+ -->
</integer-array>
<!-- Array of light sensor lux values to define our levels for auto backlight brightness support.
The N entries of this array define N + 1 control points as follows:
(1-based arrays)
Point 1: (0, value[1]): lux <= 0
Point 2: (level[1], value[2]): 0 < lux <= level[1]
Point 3: (level[2], value[3]): level[2] < lux <= level[3]
...
Point N+1: (level[N], value[N+1]): level[N] < lux
The control points must be strictly increasing. Each control point
corresponds to an entry in the brightness backlight values arrays.
For example, if lux == level[1] (first element of the levels array)
then the brightness will be determined by value[2] (second element
of the brightness values array).
Spline interpolation is used to determine the auto-brightness
backlight values for lux levels between these control points.
Must be overridden in platform specific overlays -->
<integer-array name="config_autoBrightnessLevels">
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
<item>8</item>
<item>12</item>
<item>20</item>
<item>33</item>
<item>55</item>
<item>90</item>
<item>148</item>
<item>245</item>
<item>403</item>
<item>665</item>
<item>1097</item>
<item>1808</item>
<item>2981</item>
<item>5000</item>
</integer-array>
<!-- Flag indicating whether the we should enable the automatic brightness in Settings.
Software implementation will be used if config_hardware_auto_brightness_available is not set -->
<bool name="config_automatic_brightness_available">true</bool>
<!-- Indicate available ColorDisplayManager.COLOR_MODE_xxx. -->
<integer-array name="config_availableColorModes">
<item>0</item> <!-- COLOR_MODE_NATURAL -->
<item>1</item> <!-- COLOR_MODE_BOOSTED -->
<item>3</item> <!-- COLOR_MODE_AUTOMATIC -->
</integer-array>
<!-- List of biometric sensors on the device, in decreasing strength. Consumed by AuthService
when registering authenticators with BiometricService. Format must be ID:Modality:Strength,
where: IDs are unique per device, Modality as defined in BiometricAuthenticator.java,
and Strength as defined in Authenticators.java -->
<string-array name="config_biometric_sensors" translatable="false" >
<item>0:2:15</item> <!-- ID0:Fingerprint:Strong -->
</string-array>
<!-- Boolean indicating if current platform supports HFP inband ringing -->
<bool name="config_bluetooth_hfp_inband_ringing_support">true</bool>
<!-- Boolean indicating if current platform supports BLE peripheral mode -->
<bool name="config_bluetooth_le_peripheral_mode_supported">true</bool>
<!-- Operating volatage for bluetooth controller. 0 by default-->
<integer name="config_bluetooth_operating_voltage_mv">3300</integer>
<!-- Set to true to add links to Cell Broadcast app from Settings and MMS app. -->
<bool name="config_cellBroadcastAppLinks">true</bool>
<!-- Default list of files pinned by the Pinner Service -->
<string-array translatable="false" name="config_defaultPinnerServiceFiles">
<item>"/system/framework/framework.jar"</item>
<item>"/system/framework/services.jar"</item>
<item>"/apex/com.android.art/javalib/core-oj.jar"</item>
<item>"/apex/com.android.art/javalib/core-libart.jar"</item>
<item>"/system_ext/priv-app/SystemUI/SystemUI.apk"</item>
<item>"/system/bin/surfaceflinger"</item>
</string-array>
<!-- Flag specifying whether VoLTE is available on device -->
<bool name="config_device_volte_available">true</bool>
<!-- Flag specifying whether VT is available on device -->
<bool name="config_device_vt_available">true</bool>
<!-- Flag specifying whether WFC over IMS is available on device -->
<bool name="config_device_wfc_ims_available">true</bool>
<!-- The following two arrays specify which color space to use for display composition when a
certain color mode is active.
Composition color spaces are defined in android.view.Display.COLOR_MODE_xxx, and color
modes are defined in ColorDisplayManager.COLOR_MODE_xxx and
ColorDisplayManager.VENDOR_COLOR_MODE_xxx.
The color space COLOR_MODE_DEFAULT (0) lets the system select the most appropriate
composition color space for currently displayed content. Other values (e.g.,
COLOR_MODE_SRGB) override system selection; these other color spaces must be supported by
the device for for display composition.
If a color mode does not have a corresponding color space specified in this array, the
currently set composition color space will not be modified.-->
<integer-array name="config_displayCompositionColorModes">
<item>0</item> <!-- COLOR_MODE_NATURAL -->
<item>1</item> <!-- COLOR_MODE_BOOSTED -->
<item>3</item> <!-- COLOR_MODE_AUTOMATIC -->
</integer-array>
<integer-array name="config_displayCompositionColorSpaces">
<item>0</item> <!-- COLOR_MODE_DEFAULT -->
<item>0</item> <!-- COLOR_MODE_DEFAULT -->
<item>9</item> <!-- COLOR_MODE_DISPLAY_P3 -->
</integer-array>
<!-- If true, the doze component is not started until after the screen has been
turned off and the screen off animation has been performed. -->
<bool name="config_dozeAfterScreenOffByDefault">true</bool>
<!-- Flag specifying whether or not IMS will use the ImsResolver dynamically -->
<bool name="config_dynamic_bind_ims">true</bool>
<!-- ComponentName of a dream to show whenever the system would otherwise have
gone to sleep. When the PowerManager is asked to go to sleep, it will instead
try to start this dream if possible. The dream should typically call startDozing()
to put the display into a low power state and allow the application processor
to be suspended. When the dream ends, the system will go to sleep as usual.
Specify the component name or an empty string if none.
Note that doze dreams are not subject to the same start conditions as ordinary dreams.
Doze dreams will run whenever the power manager is in a dozing state. -->
<string name="config_dozeComponent" translatable="false">com.android.systemui/com.android.systemui.doze.DozeService</string>
<!-- Enables or disables haptic effect when the text insertion/selection handle is moved
manually by the user. Off by default, since the expected haptic feedback may not be
available on some devices. -->
<bool name="config_enableHapticTextHandle">true</bool>
<!-- Whether or not wcg mode should be enabled on this device -->
<bool name="config_enableWcgMode">true</bool>
<!-- Is the device capable of hot swapping an ICC Card -->
<bool name="config_hotswapCapable">true</bool>
<!-- Is the notification LED intrusive? Used to decide if there should be a disable option -->
<bool name="config_intrusiveNotificationLed">true</bool>
<!-- Indicates whether device has a power button fingerprint sensor. -->
<bool name="config_is_powerbutton_fps">true</bool>
<!-- Vibrator pattern for a very short but reliable vibration for soft keyboard tap -->
<integer-array name="config_keyboardTapVibePattern">
<item>40</item>
</integer-array>
<!-- Vibrator pattern for feedback about a long screen/key press -->
<integer-array name="config_longPressVibePattern">
<item>0</item>
<item>1</item>
<item>20</item>
<item>21</item>
</integer-array>
<!-- Controls the navigation bar interaction mode:
0: 3 button mode (back, home, overview buttons)
1: 2 button mode (back, home buttons + swipe up for overview)
2: gestures only for back, home and overview -->
<integer name="config_navBarInteractionMode">2</integer>
<!-- Number of physical SIM slots on the device. This includes both eSIM and pSIM slots, and
is not necessarily the same as the number of phones/logical modems supported by the device.
For example, a multi-sim device can have 2 phones/logical modems, but 3 physical slots,
or a single SIM device can have 1 phones/logical modems, but 2 physical slots (one eSIM
and one pSIM) -->
<integer name="config_num_physical_slots">2</integer>
<!-- The bounding path of the cutout region of the main built-in display.
Must either be empty if there is no cutout region, or a string that is parsable by
{@link android.util.PathParser}.
The path is assumed to be specified in display coordinates with pixel units and in
the display's native orientation, with the origin of the coordinate system at the
center top of the display.
To facilitate writing device-independent emulation overlays, the marker `@dp` can be
appended after the path string to interpret coordinates in dp instead of px units.
Note that a physical cutout should be configured in pixels for the best results.
Example for a 10px x 10px square top-center cutout:
<string ...>M -5,0 L -5,10 L 5,10 L 5,0 Z</string>
Example for a 10dp x 10dp square top-center cutout:
<string ...>M -5,0 L -5,10 L 5,10 L 5,0 Z @dp</string>
@see https://www.w3.org/TR/SVG/paths.html#PathData
-->
<string name="config_mainBuiltInDisplayCutout" translatable="false">
M 0,0 H -36 V 102 H 36 V 0 H 0 Z
</string>
<!-- Configure mobile tcp buffer sizes in the form:
rat-name:rmem_min,rmem_def,rmem_max,wmem_min,wmem_def,wmem_max
If no value is found for the rat-name in use, the system default will be applied.
-->
<string-array name="config_mobile_tcp_buffers">
<item>5gnr:2097152,6291456,16777216,512000,2097152,8388608</item>
<item>lte:2097152,4194304,8388608,262144,524288,1048576</item>
<item>lte_ca:4096,6291456,12582912,4096,1048576,2097152</item>
<item>umts:4094,87380,1220608,4096,16384,1220608</item>
<item>hspa:4094,87380,1220608,4096,16384,1220608</item>
<item>hsupa:4094,87380,1220608,4096,16384,1220608</item>
<item>hsdpa:4094,87380,1220608,4096,16384,1220608</item>
<item>hspap:4094,87380,1220608,4096,16384,1220608</item>
<item>edge:4093,26280,35040,4096,16384,35040</item>
<item>gprs:4092,8760,11680,4096,8760,11680</item>
<item>evdo:4094,87380,524288,4096,16384,262144</item>
</string-array>
<!-- Should the pinner service pin the Home application? -->
<bool name="config_pinnerHomeApp">true</bool>
<!-- Power Management: Specifies whether to decouple the auto-suspend state of the
device from the display on/off state.
When false, autosuspend_disable() will be called before the display is turned on
and autosuspend_enable() will be called after the display is turned off.
This mode provides best compatibility for devices using legacy power management
features such as early suspend / late resume.
When true, autosuspend_display() and autosuspend_enable() will be called
independently of whether the display is being turned on or off. This mode
enables the power manager to suspend the application processor while the
display is on.
This resource should be set to "true" when a doze component has been specified
to maximize power savings but not all devices support it.
Refer to autosuspend.h for details.
-->
<bool name="config_powerDecoupleAutoSuspendModeFromDisplay">true</bool>
<!-- Power Management: Specifies whether to decouple the interactive state of the
device from the display on/off state.
When false, setInteractive(..., true) will be called before the display is turned on
and setInteractive(..., false) will be called after the display is turned off.
This mode provides best compatibility for devices that expect the interactive
state to be tied to the display state.
When true, setInteractive(...) will be called independently of whether the display
is being turned on or off. This mode enables the power manager to reduce
clocks and disable the touch controller while the display is on.
This resource should be set to "true" when a doze component has been specified
to maximize power savings but not all devices support it.
Refer to power.h for details.
-->
<bool name="config_powerDecoupleInteractiveModeFromDisplay">true</bool>
<!-- Telephony qualified networks service package name to bind to by default. -->
<string name="config_qualified_networks_service_package" translatable="false">vendor.qti.iwlan</string>
<!-- An array describing the screen's backlight values corresponding to the brightness
values in the config_screenBrightnessNits array. -->
<integer-array name="config_screenBrightnessBacklight">
<item>1</item>
<item>255</item>
</integer-array>
<!-- Screen brightness used to dim the screen while dozing in a very low power state.
May be less than the minimum allowed brightness setting
that can be set by the user. -->
<integer name="config_screenBrightnessDoze">12</integer>
<!-- An array of floats describing the screen brightness in nits corresponding to the backlight
values in the config_screenBrightnessBacklight array. On OLED displays these values
should be measured with an all white image while the display is in the fully on state.
Note that this value should *not* reflect the maximum brightness value for any high
brightness modes but only the maximum brightness value obtainable in a sustainable manner.
This array should be equal in size to config_screenBrightnessBacklight -->
<integer-array name="config_screenBrightnessNits">
<item>2</item>
<item>450</item>
</integer-array>
<!-- Default screen brightness setting
Must be in the range specified by minimum and maximum.
Equivalent to 67/255 (default for this device) -->
<item name="config_screenBrightnessSettingDefaultFloat" format="float" type="dimen">0.26274509804</item>
<!-- Maximum screen brightness allowed by the power manager.
The user is forbidden from setting the brightness above this level. -->
<item name="config_screenBrightnessSettingMaximumFloat" format="float" type="dimen">1.0</item>
<!-- Minimum screen brightness setting allowed by power manager.
The user is forbidden from setting the brightness below this level.
Equivalent to 1/255. -->
<item name="config_screenBrightnessSettingMinimumFloat" format="float" type="dimen">0.0</item>
<!-- Boolean indicating whether the HWC setColorTransform function can be performed efficiently
in hardware. -->
<bool name="config_setColorTransformAccelerated">true</bool>
<!-- An array of arrays of side fingerprint sensor properties relative to each display.
Note: this value is temporary and is expected to be queried directly
from the HAL in the future. -->
<array name="config_sfps_sensor_props">
<item>@array/config_sfps_sensor_props_0</item>
</array>
<array name="config_sfps_sensor_props_0">
<item></item> <!-- displayId -->
<item>1080</item> <!-- sensorLocationX -->
<item>760</item> <!-- sensorLocationY -->
<item>100</item> <!-- sensorRadius -->
</array>
<!-- Whether a software navigation bar should be shown. NOTE: in the future this may be
autodetected from the Configuration. -->
<bool name="config_showNavigationBar">true</bool>
<!-- Shutdown if the battery temperature exceeds (this value * 0.1) Celsius. -->
<integer name="config_shutdownBatteryTemperature">600</integer>
<!-- Flag indicating if the speed up audio on mt call code should be executed -->
<bool name="config_speed_up_audio_on_mt_calls">true</bool>
<!-- Whether the Unprocessed audio source supports the required frequency range and level -->
<bool name="config_supportAudioSourceUnprocessed">true</bool>
<!-- Whether device supports double tap to wake -->
<bool name="config_supportDoubleTapWake">true</bool>
<!-- True if the device supports Sustained Performance Mode-->
<bool name="config_sustainedPerformanceModeSupported">true</bool>
<!-- Config determines whether to update phone object when voice registration
state changes. Voice radio tech change will always trigger an update of
phone object irrespective of this config -->
<bool name="config_switch_phone_on_voice_reg_state_change">false</bool>
<!-- If this is true, the screen will come on when you unplug usb/power/whatever. -->
<bool name="config_unplugTurnsOnScreen">true</bool>
<!-- When true use the linux /dev/input/event subsystem to detect the switch changes
on the headphone/microphone jack. When false use the older uevent framework. -->
<bool name="config_useDevInputEventForAudioJack">true</bool>
<!-- Vibrator pattern for feedback about touching a virtual key -->
<integer-array name="config_virtualKeyVibePattern">
<item>0</item>
<item>10</item>
<item>20</item>
<item>30</item>
</integer-array>
<!-- Set to true if the wifi display supports compositing content stored
in gralloc protected buffers. For this to be true, there must exist
a protected hardware path for surface flinger to composite and send
protected buffers to the wifi display video encoder.
If this flag is false, we advise applications not to use protected
buffers (if possible) when presenting content to a wifi display because
the content may be blanked.
This flag controls whether the {@link Display#FLAG_SUPPORTS_PROTECTED_BUFFERS}
flag is set for wifi displays.
-->
<bool name="config_wifiDisplaySupportsProtectedBuffers">true</bool>
<!-- IWLAN network service package name to bind to by default. If none is specified in an overlay, an
empty string is passed in -->
<string name="config_wlan_network_service_package" translatable="false">vendor.qti.iwlan</string>
<!-- This string array should be overridden by the device to present a list of network
attributes. This is used by the connectivity manager to decide which networks can coexist
based on the hardware -->
<!-- An Array of "[Connection name],[ConnectivityManager.TYPE_xxxx],
[associated radio-type],[priority],[restoral-timer(ms)],[dependencyMet] -->
<!-- the 5th element "resore-time" indicates the number of milliseconds to delay
before automatically restore the default connection. Set -1 if the connection
does not require auto-restore. -->
<!-- the 6th element indicates boot-time dependency-met value. -->
<string-array translatable="false" name="networkAttributes">
<item>wifi,1,1,1,-1,true</item>
<item>mobile,0,0,0,-1,true</item>
<item>mobile_mms,2,0,4,60000,true</item>
<item>mobile_supl,3,0,2,60000,true</item>
<item>mobile_dun,4,0,2,60000,true</item>
<item>mobile_hipri,5,0,3,60000,true</item>
<item>mobile_fota,10,0,2,60000,true</item>
<item>mobile_ims,11,0,2,60000,true</item>
<item>mobile_cbs,12,0,2,60000,true</item>
<item>bluetooth,7,7,2,-1,true</item>
<item>mobile_emergency,15,0,5,-1,true</item>
<item>ethernet,9,9,9,-1,true</item>
</string-array>
<!-- This string array should be overridden by the device to present a list of radio
attributes. This is used by the connectivity manager to decide which networks can coexist
based on the hardware -->
<!-- An Array of "[ConnectivityManager connectionType],
[# simultaneous connection types]" -->
<string-array translatable="false" name="radioAttributes">
<item>"1,1"</item>
<item>"0,1"</item>
<item>"7,1"</item>
</string-array>
<!-- Boolean indicating if restoring network selection should be skipped -->
<!-- The restoring is handled by modem if it is true-->
<bool name="skip_restoring_network_selection">true</bool>
</resources>

View File

@ -0,0 +1,22 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2022 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources>
<!-- Radius of the software rounded corners at the bottom of the display in its natural
orientation. If zero, the value of rounded_corner_radius is used. -->
<dimen name="rounded_corner_radius_bottom">93px</dimen>
<!-- Radius of the software rounded corners at the top of the display in its natural
orientation. If zero, the value of rounded_corner_radius is used. -->
<dimen name="rounded_corner_radius_top">93px</dimen>
<!-- Height of the status bar in landscape -->
<dimen name="status_bar_height_landscape">24dp</dimen>
<!-- Height of the status bar in portrait -->
<dimen name="status_bar_height_portrait">102px</dimen>
</resources>

View File

@ -0,0 +1,101 @@
<?xml version="1.0" encoding="utf-8"?>
<device name="Android">
<item name="battery.capacity">5020</item>
<array name="cpu.clusters.cores">
<value>6</value>
<value>2</value>
</array>
<item name="cpu.suspend">4.65</item>
<item name="cpu.idle">0.52</item>
<item name="cpu.active">1</item>
<item name="cpu.cluster_power.cluster0">12.10</item>
<item name="cpu.cluster_power.cluster1">16.43</item>
<array name="cpu.core_speeds.cluster0">
<value>300000</value>
<value>576000</value>
<value>768000</value>
<value>1017600</value>
<value>1248000</value>
<value>1324800</value>
<value>1516800</value>
<value>1612800</value>
<value>1708800</value>
<value>1804800</value>
</array>
<array name="cpu.core_speeds.cluster1">
<value>652800</value>
<value>825600</value>
<value>979200</value>
<value>1113600</value>
<value>1267200</value>
<value>1555200</value>
<value>1708800</value>
<value>1843200</value>
<value>1900800</value>
<value>1996800</value>
<value>2112000</value>
<value>2208000</value>
</array>
<array name="cpu.core_power.cluster0">
<value>4.2</value>
<value>8.28</value>
<value>11.99</value>
<value>15.06</value>
<value>23.81</value>
<value>27.99</value>
<value>38.22</value>
<value>51.99</value>
<value>62.37</value>
<value>71.82</value>
</array>
<array name="cpu.core_power.cluster1">
<value>11.06</value>
<value>23.81</value>
<value>35.09</value>
<value>44.08</value>
<value>73.08</value>
<value>87.18</value>
<value>134.31</value>
<value>192.47</value>
<value>216.45</value>
<value>257.83</value>
<value>289.78</value>
<value>337.24</value>
</array>
<item name="screen.on.display0">82.45</item>
<item name="screen.full.display0">242.93</item>
<item name="camera.flashlight">245.859</item>
<item name="camera.avg">500</item>
<item name="video">83.29</item>
<item name="audio">37.41</item>
<item name="wifi.controller.idle">2</item>
<item name="wifi.controller.rx">220</item>
<item name="wifi.controller.tx">150</item>
<item name="wifi.controller.voltage">3700</item>
<item name="modem.controller.sleep">1</item>
<item name="modem.controller.idle">1</item>
<item name="modem.controller.rx">100</item>
<array name="modem.controller.tx">
<value>90</value>
<value>100</value>
<value>110</value>
<value>120</value>
<value>130</value>
</array>
<item name="modem.controller.voltage">3700</item>
<array name="gps.signalqualitybased">
<value>100</value>
<value>110</value>
</array>
<item name="gps.voltage">3700</item>
<item name="bluetooth.controller.idle">1</item>
<item name="bluetooth.controller.rx">50</item>
<item name="bluetooth.controller.tx">50</item>
<item name="bluetooth.controller.voltage">3300</item>
<item name="radio.active">100</item>
<item name="radio.scanning">50</item>
<array name="radio.on">
<value>7</value>
<value>5</value>
</array>
</device>

View File

@ -0,0 +1,9 @@
//
// Copyright (C) 2022 The LineageOS Project
// SPDX-License-Identifier: Apache-2.0
//
runtime_resource_overlay {
name: "SM6250SystemUI",
vendor: true,
}

View File

@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2022 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.systemui.xiaomi_sm6250">
<overlay
android:isStatic="true"
android:priority="100"
android:targetPackage="com.android.systemui" />
</manifest>

View File

@ -0,0 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2022 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources>
<!-- Location on the screen of the center of the fingerprint sensor. -->
<dimen name="physical_fingerprint_sensor_center_screen_location_x">1080px</dimen>
<dimen name="physical_fingerprint_sensor_center_screen_location_y">760px</dimen>
<!-- Location on the screen of the center of the physical power button. -->
<dimen name="physical_power_button_center_screen_location_y">760px</dimen>
<!-- Pad content in navbar for rounded corners -->
<dimen name="rounded_corner_content_padding">16dp</dimen>
</resources>

View File

@ -0,0 +1,9 @@
//
// Copyright (C) 2022 The LineageOS Project
// SPDX-License-Identifier: Apache-2.0
//
runtime_resource_overlay {
name: "TelephonyResCommon",
product_specific: true,
}

View File

@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2022 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.phone.overlay.common">
<overlay
android:isStatic="true"
android:priority="100"
android:targetPackage="com.android.phone" />
</manifest>

View File

@ -0,0 +1,35 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2022 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources>
<!-- Determine whether we should show the "listen for instructions" screen after
successfully placing the OTA call -->
<integer name="OtaShowListeningScreen">1</integer>
<!-- Show Preferred Network Type options in No SIM case -->
<bool name="config_no_sim_display_network_modes">true</bool>
<!-- Flag indicating whether the device supports RTT (real-time text) -->
<bool name="config_support_rtt">true</bool>
<!-- Determine whether calls to mute the microphone in PhoneUtils
are routed through the android.media.AudioManager class (true) or through
the com.android.internal.telephony.Phone interface (false). -->
<bool name="send_mic_mute_to_AudioManager">true</bool>
<!-- String indicating the package name of the device GbaService implementation. -->
<string name="config_gba_package" translatable="false">com.qualcomm.qti.uimGbaApp</string>
<!-- String indicating the package name of the device ImsService implementation for MMTEL. -->
<string name="config_ims_mmtel_package" translatable="false">org.codeaurora.ims</string>
<!-- String indicating the package name of the device ImsService implementation for RCS. -->
<string name="config_ims_rcs_package" translatable="false">org.codeaurora.ims</string>
<!-- The package name for the platform number verification supplier app. -->
<string name="platform_number_verification_package" translatable="false">com.google.android.gms</string>
</resources>

View File

@ -0,0 +1,9 @@
//
// Copyright (C) 2022 The LineageOS Project
// SPDX-License-Identifier: Apache-2.0
//
runtime_resource_overlay {
name: "WifiOverlay",
vendor: true
}

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2022 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.wifi.resources.xiaomi_sm6250">
<overlay
android:isStatic="true"
android:priority="100"
android:targetName="WifiCustomization"
android:targetPackage="com.android.wifi.resources" />
</manifest>

View File

@ -0,0 +1,67 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2019 The Android Open Source Project
Copyright (C) 2022 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources>
<!-- Boolean indicating whether the wifi chipset has 5GHz frequency band support -->
<bool name="config_wifi5ghzSupport">true</bool>
<!-- Boolean indicating whether the wifi chipset has dual frequency band support -->
<bool name="config_wifi_dual_band_support">true</bool>
<!-- Boolean indicating whether the wifi chipset has background scan support -->
<bool name="config_wifi_background_scan_support">true</bool>
<!-- Wifi driver supports batched scan -->
<bool name="config_wifi_batched_scan_supported">true</bool>
<!-- Configure wifi tcp buffersizes in the form:
rmem_min,rmem_def,rmem_max,wmem_min,wmem_def,wmem_max -->
<string name="config_wifi_tcp_buffers" translatable="false">524288,1048576,5505024,262144,524288,5505024</string>
<!-- Channel list for softap 2G band. Empty means all channels -->
<string translatable="false" name="config_wifiSoftap2gChannelList"></string>
<!-- Channel list for softap 5G band. Empty means all channels -->
<string translatable="false" name="config_wifiSoftap5gChannelList"></string>
<!-- True if the firmware supports p2p MAC randomization -->
<bool name="config_wifi_p2p_mac_randomization_supported">true</bool>
<!-- True if the firmware supports connected MAC randomization -->
<bool name="config_wifi_connected_mac_randomization_supported">true</bool>
<!-- Enable ACS (auto channel selection) for Wifi hotspot (SAP) -->
<bool name="config_wifi_softap_acs_supported">true</bool>
<!-- Enable 802.11ac for Wifi hotspot (SAP) -->
<bool name="config_wifi_softap_ieee80211ac_supported">true</bool>
<!-- Boolean indicating whether 802.11r Fast BSS Transition is enabled on this platform -->
<bool name="config_wifi_fast_bss_transition_enabled">true</bool>
<!-- Enable adding minimum confirmation duration when sending network score to connectivity service. -->
<bool name="config_wifiMinConfirmationDurationSendNetworkScoreEnabled">true</bool>
<!-- Integer delay in milliseconds before set wlan interface up during watchdog recovery -->
<integer name="config_wifi_framework_recovery_timeout_delay">3000</integer>
<!-- Disable WPA2 to WPA3 auto-upgrade -->
<bool name="config_wifiSaeUpgradeEnabled">false</bool>
<!-- Wifi driver supports WPA3 Simultaneous Authentication of Equals (WPA3-SAE) for softap -->
<bool name="config_wifi_softap_sae_supported">true</bool>
<!-- Wifi driver Automatic channel selection (ACS) for softap to include DFS channels -->
<bool name="config_wifiSoftapAcsIncludeDfs">true</bool>
<!-- Integer indicating maximum hardware supported client number of soft ap -->
<integer name="config_wifiHardwareSoftapMaxClientCount">32</integer>
<!-- Boolean indicating that wifi only link configuratios that have exact same credentials (i.e PSK) -->
<bool name="config_wifi_only_link_same_credential_configurations">false</bool>
</resources>

View File

@ -0,0 +1,14 @@
<?xml version="1.0" ?>
<permissions>
<privapp-permissions package="com.android.hotwordenrollment.okgoogle">
<permission name="android.permission.INTERACT_ACROSS_USERS"/>
<permission name="android.permission.KEYPHRASE_ENROLLMENT_APPLICATION"/>
<permission name="android.permission.MANAGE_VOICE_KEYPHRASES"/>
</privapp-permissions>
<privapp-permissions package="com.android.hotwordenrollment.xgoogle">
<permission name="android.permission.INTERACT_ACROSS_USERS"/>
<permission name="android.permission.KEYPHRASE_ENROLLMENT_APPLICATION"/>
<permission name="android.permission.MANAGE_VOICE_KEYPHRASES"/>
</privapp-permissions>
</permissions>

File diff suppressed because it is too large Load Diff

37
releasetools.py Normal file
View File

@ -0,0 +1,37 @@
# Copyright (C) 2021 The LineageOS Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
# http://www.apache.org/licenses/LICENSE-2.0
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import common
def FullOTA_InstallEnd(info):
OTA_InstallEnd(info)
return
def IncrementalOTA_InstallEnd(info):
OTA_InstallEnd(info)
return
def AddImage(info, basename, dest):
path = "IMAGES/" + basename
if path not in info.input_zip.namelist():
return
data = info.input_zip.read(path)
common.ZipWriteStr(info.output_zip, basename, data)
info.script.AppendExtra('package_extract_file("%s", "%s");' % (basename, dest))
def OTA_InstallEnd(info):
info.script.Print("Patching firmware images...")
AddImage(info, "dtbo.img", "/dev/block/bootdevice/by-name/dtbo")
AddImage(info, "vbmeta.img", "/dev/block/bootdevice/by-name/vbmeta")
AddImage(info, "vbmeta_system.img", "/dev/block/bootdevice/by-name/vbmeta_system")
return

View File

@ -4,9 +4,64 @@
// SPDX-License-Identifier: Apache-2.0
//
// Init scripts
sh_binary {
name: "init.qcom.early_boot.sh",
src: "bin/init.qcom.early_boot.sh",
vendor: true,
}
sh_binary {
name: "init.qcom.sh",
src: "bin/init.qcom.sh",
vendor: true,
}
sh_binary {
name: "init.qti.chg_policy.sh",
src: "bin/init.qti.chg_policy.sh",
vendor: true,
}
// fstab
prebuilt_etc {
name: "fstab.qcom",
src: "etc/fstab.qcom",
vendor: true,
}
// Init configuration files
prebuilt_etc {
name: "init.device.rc",
src: "etc/init.device.rc",
sub_dir: "init/hw",
vendor: true,
}
prebuilt_etc {
name: "init.qcom.power.rc",
src: "etc/init.qcom.power.rc",
sub_dir: "init/hw",
vendor: true,
}
prebuilt_etc {
name: "init.qcom.rc",
src: "etc/init.qcom.rc",
sub_dir: "init/hw",
vendor: true,
}
prebuilt_etc {
name: "init.target.rc",
src: "etc/init.target.rc",
sub_dir: "init/hw",
vendor: true,
}
prebuilt_etc {
name: "ueventd.qcom.rc",
filename: "ueventd.rc",
src: "etc/ueventd.qcom.rc",
vendor: true,
}

View File

@ -0,0 +1,64 @@
#! /vendor/bin/sh
# Copyright (c) 2012-2013,2016,2018-2020 The Linux Foundation. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials provided with the distribution.
# * Neither the name of The Linux Foundation nor
# the names of its contributors may be used to endorse or promote
# products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
export PATH=/vendor/bin
echo "detect" > /sys/class/drm/card0-DSI-1/status
#For drm based display driver
vbfile=/sys/module/drm/parameters/vblankoffdelay
if [ -w $vbfile ]; then
echo -1 > $vbfile
else
log -t DRM_BOOT -p w "file: '$vbfile' or perms doesn't exist"
fi
function set_perms() {
#Usage set_perms <filename> <ownership> <permission>
chown -h $2 $1
chmod $3 $1
}
set_perms /sys/devices/virtual/hdcp/msm_hdcp/min_level_change system.graphics 0660
# allow system_graphics group to access pmic secure_mode node
set_perms /sys/class/lcd_bias/secure_mode system.graphics 0660
set_perms /sys/class/leds/wled/secure_mode system.graphics 0660
boot_reason=`cat /proc/sys/kernel/boot_reason`
reboot_reason=`getprop ro.boot.alarmboot`
if [ "$boot_reason" = "3" ] || [ "$reboot_reason" = "true" ]; then
setprop ro.vendor.alarm_boot true
else
setprop ro.vendor.alarm_boot false
fi
# copy GPU frequencies to vendor property
if [ -f /sys/class/kgsl/kgsl-3d0/gpu_available_frequencies ]; then
gpu_freq=`cat /sys/class/kgsl/kgsl-3d0/gpu_available_frequencies` 2> /dev/null
setprop vendor.gpu.available_frequencies "$gpu_freq"
fi

52
rootdir/bin/init.qcom.sh Normal file
View File

@ -0,0 +1,52 @@
#! /vendor/bin/sh
# Copyright (c) 2009-2016, The Linux Foundation. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials provided with the distribution.
# * Neither the name of The Linux Foundation nor
# the names of its contributors may be used to endorse or promote
# products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
#
# Make modem config folder and copy firmware config to that folder for RIL
#
if [ -f /data/vendor/modem_config/ver_info.txt ]; then
prev_version_info=`cat /data/vendor/modem_config/ver_info.txt`
else
prev_version_info=""
fi
cur_version_info=`cat /vendor/firmware_mnt/verinfo/ver_info.txt`
if [ ! -f /vendor/firmware_mnt/verinfo/ver_info.txt -o "$prev_version_info" != "$cur_version_info" ]; then
# add W for group recursively before delete
chmod g+w -R /data/vendor/modem_config/*
rm -rf /data/vendor/modem_config/*
# preserve the read only mode for all subdir and files
cp --preserve=m -dr /vendor/firmware_mnt/image/modem_pr/mcfg/configs/* /data/vendor/modem_config
cp --preserve=m -d /vendor/firmware_mnt/verinfo/ver_info.txt /data/vendor/modem_config/
cp --preserve=m -d /vendor/firmware_mnt/image/modem_pr/mbn_ota.txt /data/vendor/modem_config/
# the group must be root, otherwise this script could not add "W" for group recursively
chown -hR radio.root /data/vendor/modem_config/*
fi
chmod g-w /data/vendor/modem_config
setprop ro.vendor.ril.mbn_copy_completed 1

View File

@ -0,0 +1,48 @@
#! /vendor/bin/sh
#
# Copyright (c) 2019-2021 Qualcomm Technologies, Inc.
# All Rights Reserved.
# Confidential and Proprietary - Qualcomm Technologies, Inc.
#
# Copyright (c) 2019 The Linux Foundation. All rights reserved.
#
export PATH=/vendor/bin
soc_id=`getprop ro.vendor.qti.soc_id`
if [ "$soc_id" -eq 415 ] || [ "$soc_id" -eq 439 ] || [ "$soc_id" -eq 450 ] || [ "$soc_id" -eq 475 ] || [ "$soc_id" -eq 497 ] || [ "$soc_id" -eq 498 ] || [ "$soc_id" -eq 499 ] || [ "$soc_id" -eq 515 ]; then
setprop persist.vendor.hvdcp_opti.start 2
exit 0
fi
if [ "$soc_id" -eq 441 ] || [ "$soc_id" -eq 471 ]; then
#Scuba does not support usb-pd or charge pumps
find /sys/class/power_supply/battery/ -type f -maxdepth 1 | xargs chown system.system
find /sys/class/power_supply/bms/ -type f -maxdepth 1 | xargs chown system.system
find /sys/class/power_supply/main/ -type f -maxdepth 1 | xargs chown system.system
find /sys/class/power_supply/usb/ -type f -maxdepth 1 | xargs chown system.system
else
find /sys/class/power_supply/battery/ -type f -maxdepth 1 | xargs chown system.system
find /sys/class/power_supply/bms/ -type f -maxdepth 1 | xargs chown system.system
find /sys/class/power_supply/main/ -type f -maxdepth 1 | xargs chown system.system
find /sys/class/power_supply/usb/ -type f -maxdepth 1 | xargs chown system.system
find /sys/class/power_supply/charge_pump_master/ -type f -maxdepth 1 | xargs chown system.system
find /sys/class/power_supply/pc_port/ -type f -maxdepth 1 | xargs chown system.system
find /sys/class/power_supply/dc/ -type f -maxdepth 1 | xargs chown system.system
find /sys/class/power_supply/parallel/ -type f -maxdepth 1 | xargs chown system.system
find /sys/class/usbpd/usbpd0/ -type f -maxdepth 1 | xargs chown system.system
find /sys/class/qc-vdm/ -type f -maxdepth 1 | xargs chown system.system
find /sys/class/charge_pump/ -type f -maxdepth 1 | xargs chown system.system
find /sys/class/qcom-battery/ -type f -maxdepth 1 | xargs chown system.system
for i in 0 1 2 3 4 5 6 7 8 9
do
devname=`cat /sys/bus/iio/devices/iio:device$i/name`
if [[ "$devname" == *smb* ]] || [[ "$devname" == *qg* ]] || [[ "$devname" == *div2_cp* ]] || [[ "$devname" == *div2-cp* ]]; then
find /sys/bus/iio/devices/iio:device$i/ -type f -maxdepth 1 | xargs chown system.system
fi
done
fi
setprop persist.vendor.hvdcp_opti.start 1

53
rootdir/etc/fstab.qcom Normal file
View File

@ -0,0 +1,53 @@
# Copyright (c) 2018-2019, The Linux Foundation. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above
# copyright notice, this list of conditions and the following
# disclaimer in the documentation and/or other materials provided
# with the distribution.
# * Neither the name of The Linux Foundation nor the names of its
# contributors may be used to endorse or promote products derived
# from this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
# BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
# BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
# OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
# IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# Android fstab file.
# The filesystem that contains the filesystem checker binary (typically /system) cannot
# specify MF_CHECK, and must come before any filesystems that do specify MF_CHECK
#<src> <mnt_point> <type> <mnt_flags and options> <fs_mgr_flags>
system /system ext4 ro,barrier=1,discard wait,logical,first_stage_mount,avb=vbmeta_system,avb_keys=/avb/q-gsi.avbpubkey:/avb/r-gsi.avbpubkey:/avb/s-gsi.avbpubkey
system_ext /system_ext ext4 ro,barrier=1,discard wait,logical,first_stage_mount,avb
product /product ext4 ro,barrier=1,discard wait,logical,first_stage_mount,avb
vendor /vendor ext4 ro,barrier=1,discard wait,logical,first_stage_mount,avb=vbmeta
/dev/block/bootdevice/by-name/cache /cache ext4 nosuid,noatime,nodev,barrier=1 wait
/dev/block/bootdevice/by-name/boot /boot emmc defaults defaults
/dev/block/bootdevice/by-name/recovery /recovery emmc defaults defaults
/dev/block/by-name/metadata /metadata ext4 noatime,nosuid,nodev,discard wait,check,formattable,first_stage_mount
/dev/block/bootdevice/by-name/userdata /data f2fs noatime,nosuid,nodev,discard,reserve_root=32768,resgid=1065,fsync_mode=nobarrier,inlinecrypt latemount,wait,check,formattable,fileencryption=aes-256-xts:aes-256-cts:v2+inlinecrypt_optimized+wrappedkey_v0,metadata_encryption=aes-256-xts:wrappedkey_v0,keydirectory=/metadata/vold/metadata_encryption,quota,reservedsize=128M,sysfs_path=/sys/devices/platform/soc/1d84000.ufshc,checkpoint=fs
/devices/platform/soc/8804000.sdhci/mmc_host* /storage/sdcard1 vfat nosuid,nodev wait,voldmanaged=sdcard1:auto,encryptable=footer
/devices/platform/soc/1da4000.ufshc_card/host* /storage/sdcard1 vfat nosuid,nodev wait,voldmanaged=sdcard1:auto,encryptable=footer
/dev/block/bootdevice/by-name/modem /vendor/firmware_mnt vfat ro,shortname=lower,uid=1000,gid=1000,dmask=227,fmask=337,context=u:object_r:firmware_file:s0 wait
/dev/block/bootdevice/by-name/dsp /vendor/dsp ext4 ro,nosuid,nodev,barrier=1 wait
/dev/block/bootdevice/by-name/persist /mnt/vendor/persist ext4 noatime,nosuid,nodev,barrier=1 wait,check
/dev/block/bootdevice/by-name/bluetooth /vendor/bt_firmware vfat ro,shortname=lower,uid=1002,gid=3002,dmask=227,fmask=337,context=u:object_r:bt_firmware_file:s0 wait
/devices/platform/soc/a600000.ssusb/a600000.dwc3/xhci-hcd.0.auto* /storage/usbotg vfat nosuid,nodev wait,voldmanaged=usbotg:auto
# Need to have this entry in here even though the mount point itself is no longer needed.
# The update_engine code looks for this entry in order to determine the boot device address
# and fails if it does not find it.
/dev/block/bootdevice/by-name/misc /misc emmc defaults defaults
/dev/block/zram0 none swap defaults zramsize=50%

View File

@ -0,0 +1,128 @@
# Copyright (c) 2012-2013, 2016-2020, The Linux Foundation. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials provided with the distribution.
# * Neither the name of The Linux Foundation nor
# the names of its contributors may be used to endorse or promote
# products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
on enable-low-power
# Apply settings for atoll
# Enable bus-dcvs
write /sys/devices/platform/soc/soc:qcom,cpu-cpu-llcc-bw/devfreq/soc:qcom,cpu-cpu-llcc-bw/governor bw_hwmon
write /sys/devices/platform/soc/soc:qcom,cpu-cpu-llcc-bw/devfreq/soc:qcom,cpu-cpu-llcc-bw/bw_hwmon/mbps_zones "2288 4577 7110 9155 12298 14236"
write /sys/devices/platform/soc/soc:qcom,cpu-cpu-llcc-bw/devfreq/soc:qcom,cpu-cpu-llcc-bw/bw_hwmon/sample_ms 4
write /sys/devices/platform/soc/soc:qcom,cpu-cpu-llcc-bw/devfreq/soc:qcom,cpu-cpu-llcc-bw/bw_hwmon/io_percent 68
write /sys/devices/platform/soc/soc:qcom,cpu-cpu-llcc-bw/devfreq/soc:qcom,cpu-cpu-llcc-bw/bw_hwmon/hist_memory 20
write /sys/devices/platform/soc/soc:qcom,cpu-cpu-llcc-bw/devfreq/soc:qcom,cpu-cpu-llcc-bw/bw_hwmon/hyst_length 0
write /sys/devices/platform/soc/soc:qcom,cpu-cpu-llcc-bw/devfreq/soc:qcom,cpu-cpu-llcc-bw/bw_hwmon/down_thres 80
write /sys/devices/platform/soc/soc:qcom,cpu-cpu-llcc-bw/devfreq/soc:qcom,cpu-cpu-llcc-bw/bw_hwmon/guard_band_mbps 0
write /sys/devices/platform/soc/soc:qcom,cpu-cpu-llcc-bw/devfreq/soc:qcom,cpu-cpu-llcc-bw/bw_hwmon/up_scale 250
write /sys/devices/platform/soc/soc:qcom,cpu-cpu-llcc-bw/devfreq/soc:qcom,cpu-cpu-llcc-bw/bw_hwmon/idle_mbps 1600
write /sys/devices/platform/soc/soc:qcom,cpu-cpu-llcc-bw/devfreq/soc:qcom,cpu-cpu-llcc-bw/polling_interval 50
write /sys/devices/platform/soc/soc:qcom,cpu-llcc-ddr-bw/devfreq/soc:qcom,cpu-llcc-ddr-bw/governor bw_hwmon
write /sys/devices/platform/soc/soc:qcom,cpu-llcc-ddr-bw/devfreq/soc:qcom,cpu-llcc-ddr-bw/bw_hwmon/mbps_zones "1144 1720 2086 2929 3879 5931 6881 8137"
write /sys/devices/platform/soc/soc:qcom,cpu-llcc-ddr-bw/devfreq/soc:qcom,cpu-llcc-ddr-bw/bw_hwmon/sample_ms 4
write /sys/devices/platform/soc/soc:qcom,cpu-llcc-ddr-bw/devfreq/soc:qcom,cpu-llcc-ddr-bw/bw_hwmon/io_percent 68
write /sys/devices/platform/soc/soc:qcom,cpu-llcc-ddr-bw/devfreq/soc:qcom,cpu-llcc-ddr-bw/bw_hwmon/hist_memory 20
write /sys/devices/platform/soc/soc:qcom,cpu-llcc-ddr-bw/devfreq/soc:qcom,cpu-llcc-ddr-bw/bw_hwmon/hyst_length 0
write /sys/devices/platform/soc/soc:qcom,cpu-llcc-ddr-bw/devfreq/soc:qcom,cpu-llcc-ddr-bw/bw_hwmon/down_thres 80
write /sys/devices/platform/soc/soc:qcom,cpu-llcc-ddr-bw/devfreq/soc:qcom,cpu-llcc-ddr-bw/bw_hwmon/guard_band_mbps 0
write /sys/devices/platform/soc/soc:qcom,cpu-llcc-ddr-bw/devfreq/soc:qcom,cpu-llcc-ddr-bw/bw_hwmon/up_scale 250
write /sys/devices/platform/soc/soc:qcom,cpu-llcc-ddr-bw/devfreq/soc:qcom,cpu-llcc-ddr-bw/bw_hwmon/idle_mbps 1600
write /sys/devices/platform/soc/soc:qcom,cpu-llcc-ddr-bw/devfreq/soc:qcom,cpu-llcc-ddr-bw/polling_interval 40
write /sys/devices/virtual/npu/msm_npu/pwr 1
write /sys/devices/platform/soc/soc:qcom,npu-npu-ddr-bw/devfreq/soc:qcom,npu-npu-ddr-bw/governor bw_hwmon
write /sys/devices/platform/soc/soc:qcom,npu-npu-ddr-bw/devfreq/soc:qcom,npu-npu-ddr-bw/bw_hwmon/mbps_zones "1144 1720 2086 2929 3879 5931 6881 8137"
write /sys/devices/platform/soc/soc:qcom,npu-npu-ddr-bw/devfreq/soc:qcom,npu-npu-ddr-bw/bw_hwmon/sample_ms 4
write /sys/devices/platform/soc/soc:qcom,npu-npu-ddr-bw/devfreq/soc:qcom,npu-npu-ddr-bw/bw_hwmon/io_percent 80
write /sys/devices/platform/soc/soc:qcom,npu-npu-ddr-bw/devfreq/soc:qcom,npu-npu-ddr-bw/bw_hwmon/hist_memory 20
write /sys/devices/platform/soc/soc:qcom,npu-npu-ddr-bw/devfreq/soc:qcom,npu-npu-ddr-bw/bw_hwmon/hyst_length 10
write /sys/devices/platform/soc/soc:qcom,npu-npu-ddr-bw/devfreq/soc:qcom,npu-npu-ddr-bw/bw_hwmon/down_thres 30
write /sys/devices/platform/soc/soc:qcom,npu-npu-ddr-bw/devfreq/soc:qcom,npu-npu-ddr-bw/bw_hwmon/guard_band_mbps 0
write /sys/devices/platform/soc/soc:qcom,npu-npu-ddr-bw/devfreq/soc:qcom,npu-npu-ddr-bw/bw_hwmon/up_scale 250
write /sys/devices/platform/soc/soc:qcom,npu-npu-ddr-bw/devfreq/soc:qcom,npu-npu-ddr-bw/bw_hwmon/idle_mbps 0
write /sys/devices/platform/soc/soc:qcom,npu-npu-ddr-bw/devfreq/soc:qcom,npu-npu-ddr-bw/polling_interval 40
write /sys/devices/platform/soc/soc:qcom,npudsp-npu-ddr-bw/devfreq/soc:qcom,npudsp-npu-ddr-bw/governor bw_hwmon
write /sys/devices/platform/soc/soc:qcom,npudsp-npu-ddr-bw/devfreq/soc:qcom,npudsp-npu-ddr-bw/bw_hwmon/mbps_zones "1144 1720 2086 2929 3879 5931 6881 8137"
write /sys/devices/platform/soc/soc:qcom,npudsp-npu-ddr-bw/devfreq/soc:qcom,npudsp-npu-ddr-bw/bw_hwmon/sample_ms 4
write /sys/devices/platform/soc/soc:qcom,npudsp-npu-ddr-bw/devfreq/soc:qcom,npudsp-npu-ddr-bw/bw_hwmon/io_percent 80
write /sys/devices/platform/soc/soc:qcom,npudsp-npu-ddr-bw/devfreq/soc:qcom,npudsp-npu-ddr-bw/bw_hwmon/hist_memory 20
write /sys/devices/platform/soc/soc:qcom,npudsp-npu-ddr-bw/devfreq/soc:qcom,npudsp-npu-ddr-bw/bw_hwmon/hyst_length 10
write /sys/devices/platform/soc/soc:qcom,npudsp-npu-ddr-bw/devfreq/soc:qcom,npudsp-npu-ddr-bw/bw_hwmon/down_thres 30
write /sys/devices/platform/soc/soc:qcom,npudsp-npu-ddr-bw/devfreq/soc:qcom,npudsp-npu-ddr-bw/bw_hwmon/guard_band_mbps 0
write /sys/devices/platform/soc/soc:qcom,npudsp-npu-ddr-bw/devfreq/soc:qcom,npudsp-npu-ddr-bw/bw_hwmon/up_scale 250
write /sys/devices/platform/soc/soc:qcom,npudsp-npu-ddr-bw/devfreq/soc:qcom,npudsp-npu-ddr-bw/bw_hwmon/idle_mbps 0
write /sys/devices/platform/soc/soc:qcom,npudsp-npu-ddr-bw/devfreq/soc:qcom,npudsp-npu-ddr-bw/polling_interval 40
write /sys/devices/virtual/npu/msm_npu/pwr 0
# Enable mem_latency governor for L3, LLCC, and DDR scaling
write /sys/devices/platform/soc/soc:qcom,cpu0-cpu-llcc-lat/devfreq/soc:qcom,cpu0-cpu-llcc-lat/governor mem_latency
write /sys/devices/platform/soc/soc:qcom,cpu0-cpu-llcc-lat/devfreq/soc:qcom,cpu0-cpu-llcc-lat/polling_interval 10
write /sys/devices/platform/soc/soc:qcom,cpu0-cpu-llcc-lat/devfreq/soc:qcom,cpu0-cpu-llcc-lat/mem_latency/ratio_ceil 400
write /sys/devices/platform/soc/soc:qcom,cpu0-cpu-l3-lat/devfreq/soc:qcom,cpu0-cpu-l3-lat/governor mem_latency
write /sys/devices/platform/soc/soc:qcom,cpu0-cpu-l3-lat/devfreq/soc:qcom,cpu0-cpu-l3-lat/polling_interval 10
write /sys/devices/platform/soc/soc:qcom,cpu0-cpu-l3-lat/devfreq/soc:qcom,cpu0-cpu-l3-lat/mem_latency/ratio_ceil 400
write /sys/devices/platform/soc/soc:qcom,cpu0-llcc-ddr-lat/devfreq/soc:qcom,cpu0-llcc-ddr-lat/governor mem_latency
write /sys/devices/platform/soc/soc:qcom,cpu0-llcc-ddr-lat/devfreq/soc:qcom,cpu0-llcc-ddr-lat/polling_interval 10
write /sys/devices/platform/soc/soc:qcom,cpu0-llcc-ddr-lat/devfreq/soc:qcom,cpu0-llcc-ddr-lat/mem_latency/ratio_ceil 400
write /sys/devices/platform/soc/soc:qcom,cpu6-cpu-llcc-lat/devfreq/soc:qcom,cpu6-cpu-llcc-lat/governor mem_latency
write /sys/devices/platform/soc/soc:qcom,cpu6-cpu-llcc-lat/devfreq/soc:qcom,cpu6-cpu-llcc-lat/polling_interval 10
write /sys/devices/platform/soc/soc:qcom,cpu6-cpu-llcc-lat/devfreq/soc:qcom,cpu6-cpu-llcc-lat/mem_latency/ratio_ceil 400
write /sys/devices/platform/soc/soc:qcom,cpu6-cpu-l3-lat/devfreq/soc:qcom,cpu6-cpu-l3-lat/governor mem_latency
write /sys/devices/platform/soc/soc:qcom,cpu6-cpu-l3-lat/devfreq/soc:qcom,cpu6-cpu-l3-lat/polling_interval 10
# Gold L3 ratio ceil is 4000
write /sys/devices/platform/soc/soc:qcom,cpu6-cpu-l3-lat/devfreq/soc:qcom,cpu6-cpu-l3-lat/mem_latency/ratio_ceil 4000
write /sys/devices/platform/soc/soc:qcom,cpu6-llcc-ddr-lat/devfreq/soc:qcom,cpu6-llcc-ddr-lat/governor mem_latency
write /sys/devices/platform/soc/soc:qcom,cpu6-llcc-ddr-lat/devfreq/soc:qcom,cpu6-llcc-ddr-lat/polling_interval 10
write /sys/devices/platform/soc/soc:qcom,cpu6-llcc-ddr-lat/devfreq/soc:qcom,cpu6-llcc-ddr-lat/mem_latency/ratio_ceil 400
# Enable cdspl3 governor for L3 cdsp nodes
write /sys/devices/platform/soc/soc:qcom,cdsp-cdsp-l3-lat/devfreq/soc:qcom,cdsp-cdsp-l3-lat/governor cdspl3
# Enable compute governor for gold latfloor
write /sys/devices/platform/soc/soc:qcom,cpu6-cpu-ddr-latfloor/devfreq/soc:qcom,cpu6-cpu-ddr-latfloor/governor compute
write /sys/devices/platform/soc/soc:qcom,cpu6-cpu-ddr-latfloor/devfreq/soc:qcom,cpu6-cpu-ddr-latfloor/polling_interval 10
# Turn on sleep modes
write /sys/module/lpm_levels/parameters/sleep_disabled 0
# Enable idle state listener
write /sys/class/drm/card0/device/idle_encoder_mask 1
write /sys/class/drm/card0/device/idle_timeout_ms 100
# Enable PowerHAL hint processing
setprop vendor.powerhal.init 1
on property:sys.boot_completed=1
trigger enable-low-power
on property:init.svc.recovery=running
trigger enable-low-power

879
rootdir/etc/init.qcom.rc Normal file
View File

@ -0,0 +1,879 @@
# Copyright (c) 2009-2012, 2014-2020, The Linux Foundation. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials provided with the distribution.
# * Neither the name of The Linux Foundation nor
# the names of its contributors may be used to endorse or promote
# products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
import /vendor/etc/init/hw/init.qcom.usb.rc
import /vendor/etc/init/hw/init.qcom.power.rc
import /vendor/etc/init/hw/init.device.rc
import /vendor/etc/init/hw/init.target.rc
on early-init
mount debugfs debugfs /sys/kernel/debug
chmod 0755 /sys/kernel/debug
# create symlink for vendor mount points
symlink /vendor/firmware_mnt /firmware
symlink /vendor/bt_firmware /bt_firmware
symlink /vendor/dsp /dsp
# Change ownership of hw_recovery related nodes
chown system graphics /sys/kernel/debug/dri/0/debug/dump
chown system graphics /sys/kernel/debug/dri/0/debug/recovery_reg
chown system graphics /sys/kernel/debug/dri/0/debug/recovery_dbgbus
chown system graphics /sys/kernel/debug/dri/0/debug/recovery_vbif_dbgbus
chown system graphics /sys/kernel/debug/dri/0/debug/recovery_dsi_dbgbus
# Change ownership of sysfs power control node
chown system graphics /sys/class/drm/card0/device/power/control
# Change ownership of sw_sync node
chown system graphics /sys/kernel/debug/sync/sw_sync
chmod 0666 /sys/kernel/debug/sync/sw_sync
#Disable UFS clock scaling
write /sys/bus/platform/devices/1d84000.ufshc/clkscale_enable 0
chown root system /dev/kmsg
chmod 0620 /dev/kmsg
# Load WIGIG platform driver
exec u:r:vendor_modprobe:s0 -- /vendor/bin/modprobe -a -d /vendor/lib/modules msm_11ad_proxy
on init
# Create cgroup mount point for memory
mkdir /sys/fs/cgroup/memory/bg 0750 root system
write /sys/fs/cgroup/memory/bg/memory.swappiness 140
write /sys/fs/cgroup/memory/bg/memory.move_charge_at_immigrate 1
chown root system /sys/fs/cgroup/memory/bg/tasks
chmod 0660 /sys/fs/cgroup/memory/bg/tasks
on post-fs
chmod 0755 /sys/kernel/debug/tracing
chmod 0660 /sys/class/leds/red/brightness
chown system system /sys/class/leds/red/brightness
mkdir /mnt/vendor/dsp 0770 root root
copy /vendor/dsp/cdsp/fastrpc_shell_3 /mnt/vendor/dsp/fastrpc_shell_3
chmod 0644 /mnt/vendor/dsp/fastrpc_shell_3
mount none /mnt/vendor/dsp/fastrpc_shell_3 /vendor/dsp/cdsp/fastrpc_shell_3 bind
on early-boot
# set RLIMIT_MEMLOCK to 64MB
setrlimit 8 67108864 67108864
# Allow subsystem (modem etc) debugging
write /sys/kernel/boot_adsp/boot 1
write /sys/kernel/boot_cdsp/boot 1
write /sys/devices/virtual/npu/msm_npu/boot 1
write /sys/devices/virtual/cvp/cvp/boot 1
exec u:r:vendor_qti_init_shell:s0 -- /vendor/bin/init.qcom.early_boot.sh
chown system system /mnt/vendor/persist/data/pfm/licenses
chmod 0775 /mnt/vendor/persist/data/pfm/licenses
chown system system /mnt/vendor/persist/data/pfm/licenses/store_0
chmod 0664 /mnt/vendor/persist/data/pfm/licenses/store_0
chown system system /mnt/vendor/persist/data/pfm/licenses/store_1
chmod 0664 /mnt/vendor/persist/data/pfm/licenses/store_1
chown system system /mnt/vendor/persist/data/pfm/licenses/store_2
chmod 0664 /mnt/vendor/persist/data/pfm/licenses/store_2
chown system system /mnt/vendor/persist/data/pfm/licenses/store_3
chmod 0664 /mnt/vendor/persist/data/pfm/licenses/store_3
chown system system /mnt/vendor/persist/data/pfm/licenses/store_4
chmod 0664 /mnt/vendor/persist/data/pfm/licenses/store_4
# SSR
write /sys/bus/msm_subsys/devices/subsys0/restart_level RELATED
write /sys/bus/msm_subsys/devices/subsys1/restart_level RELATED
write /sys/bus/msm_subsys/devices/subsys2/restart_level RELATED
write /sys/bus/msm_subsys/devices/subsys3/restart_level RELATED
write /sys/bus/msm_subsys/devices/subsys4/restart_level RELATED
write /sys/bus/msm_subsys/devices/subsys5/restart_level RELATED
write /sys/bus/msm_subsys/devices/subsys6/restart_level RELATED
on boot
chown bluetooth bluetooth /sys/module/bluetooth_power/parameters/power
chown bluetooth net_bt /sys/class/rfkill/rfkill0/type
chown bluetooth net_bt /sys/class/rfkill/rfkill0/state
chown bluetooth bluetooth /proc/bluetooth/sleep/proto
chown bluetooth bluetooth /sys/module/hci_uart/parameters/ath_lpm
chown bluetooth bluetooth /sys/module/hci_uart/parameters/ath_btwrite
chown system system /sys/module/sco/parameters/disable_esco
chown bluetooth bluetooth /sys/module/hci_smd/parameters/hcismd_set
chown system system /sys/module/msm_core/parameters/polling_interval
chown system system /sys/module/msm_core/parameters/disabled
chown system system /sys/kernel/debug/msm_core/enable
chown system system /sys/kernel/debug/msm_core/ptable
chown system system /sys/kernel/boot_slpi/ssr
chown system system /sys/module/radio_iris_transport/parameters/fmsmd_set
chmod 0660 /sys/module/bluetooth_power/parameters/power
chmod 0660 /sys/module/hci_smd/parameters/hcismd_set
chmod 0660 /sys/module/radio_iris_transport/parameters/fmsmd_set
chmod 0660 /sys/class/rfkill/rfkill0/state
chmod 0660 /proc/bluetooth/sleep/proto
chown bluetooth net_bt /dev/ttyHS0
chmod 0660 /sys/module/hci_uart/parameters/ath_lpm
chmod 0660 /sys/module/hci_uart/parameters/ath_btwrite
chmod 0660 /dev/ttyHS0
chown bluetooth bluetooth /sys/devices/platform/msm_serial_hs.0/clock
chmod 0660 /sys/devices/platform/msm_serial_hs.0/clock
chmod 0660 /dev/ttyHS2
chown bluetooth bluetooth /dev/ttyHS2
chown bluetooth net_bt /sys/class/rfkill/rfkill0/device/extldo
chmod 0660 /sys/class/rfkill/rfkill0/device/extldo
#add flashlight
chmod 0660 /sys/class/leds/flashlight/brightness
chown system system /sys/class/leds/flashlight/brightness
#define back flash and front flash
chmod 0660 /sys/class/leds/led:flash_0/brightness
chmod 0660 /sys/class/leds/led:flash_1/brightness
chmod 0660 /sys/class/leds/led:flash_2/brightness
chmod 0660 /sys/class/leds/led:torch_0/brightness
chmod 0660 /sys/class/leds/led:torch_1/brightness
chmod 0660 /sys/class/leds/led:torch_2/brightness
chmod 0660 /sys/class/leds/led:switch_0/brightness
chmod 0660 /sys/class/leds/led:switch_1/brightness
chmod 0660 /sys/class/leds/flashlight/brightness
chmod 0777 /sys/class/ant_class/ant_state
chmod 0777 /sys/class/ant_div_class/ant_div_state
chown system system /sys/class/leds/led:flash_0/brightness
chown system system /sys/class/leds/led:flash_1/brightness
chown system system /sys/class/leds/led:flash_2/brightness
chown system system /sys/class/leds/led:torch_0/brightness
chown system system /sys/class/leds/led:torch_1/brightness
chown system system /sys/class/leds/led:torch_2/brightness
chown system system /sys/class/leds/led:switch_0/brightness
chown system system /sys/class/leds/led:switch_1/brightness
chown system system /sys/class/leds/flashlight/brightness
chown system system /sys/class/ant_class/ant_state
chown system system /sys/class/ant_div_class/ant_div_state
# This location is used by QCRIL to host UNIX domain
# socket files used for internal IPC within QCRIL
# modules
mkdir /dev/socket/qmux_radio 0770 radio radio
chmod 2770 /dev/socket/qmux_radio
mkdir /persist/drm 0770 system system
mkdir /persist/bluetooth 0770 bluetooth bluetooth
mkdir /persist/misc 0770 system system
mkdir /persist/alarm 0770 system system
mkdir /mnt/vendor/persist/time 0770 system system
mkdir /mnt/vendor/persist/secnvm 0770 system system
mkdir /mnt/vendor/persist/iar_db 0770 system system
mkdir /mnt/vendor/spunvm 0770 system system
#Create WIGIG socket area
mkdir /dev/socket/wigig 0770 wifi wifi
setprop wifi.interface wlan0
setprop ro.telephony.call_ring.multiple false
#Remove SUID bit for iproute2 ip tool
chmod 0755 /system/bin/ip
chmod 0444 /sys/devices/platform/msm_hsusb/gadget/usb_state
setprop net.tcp.2g_init_rwnd 10
# To prevent out of order acknowledgements from making
# connection tracking to treat them as not belonging to
# the connection they belong to.
# Otherwise, a weird issue happens in which some long
# connections on high-throughput links get dropped when
# an ack packet comes out of order
write /proc/sys/net/netfilter/nf_conntrack_tcp_be_liberal 1
# Set the console loglevel to < KERN_WARN
# Set the default message loglevel to KERN_INFO
write /proc/sys/kernel/printk "4 6 1 7"
# Allow access for CCID command/response timeout configuration
chown system system /sys/module/ccid_bridge/parameters/bulk_msg_timeout
# bond0 used by FST Manager
chown wifi wifi /sys/class/net/bond0/bonding/queue_id
# Allow access to emmc rawdump block partition and dload sysfs node
chown root system /dev/block/bootdevice/by-name/rawdump
chmod 0660 /dev/block/bootdevice/by-name/rawdump
chown root system /sys/kernel/dload/emmc_dload
chmod 0660 /sys/kernel/dload/emmc_dload
chown root system /dev/block/bootdevice/by-name/ramdump
chmod 0660 /dev/block/bootdevice/by-name/ramdump
chown root system /sys/kernel/dload/dload_mode
chmod 0660 /sys/kernel/dload/dload_mode
chown system system /sys/class/backlight/panel0-backlight/brightness
chown system system /sys/class/backlight/panel0-backlight/max_brightness
chown system system /sys/class/backlight/panel1-backlight/brightness
chown system system /sys/class/backlight/panel1-backlight/max_brightness
# Allow access to sensors device attributes
chown system system /sys/class/sensors/MPU6050-accel/enable
chown system system /sys/class/sensors/MPU6050-accel/poll_delay
chown system system /sys/class/sensors/MPU6050-gyro/enable
chown system system /sys/class/sensors/MPU6050-gyro/poll_delay
chown system system /sys/class/sensors/apds9930-light/enable
chown system system /sys/class/sensors/apds9930-light/poll_delay
chown system system /sys/class/sensors/apds9930-proximity/enable
chown system system /sys/class/sensors/apds9930-proximity/poll_delay
# Create directory used for display
# for backward compatibility
mkdir /persist/display 0770 system graphics
mkdir /mnt/vendor/persist/display 0770 system graphics
# Enable qcrild and data services on boot so process starts in main
enable vendor.qcrild
enable vendor.qcrild2
enable vendor.dataqti
enable vendor.dataadpl
# Create vpp directory
mkdir /mnt/vendor/persist/vpp 0770 media media
# Create hvdcp_opti directory
mkdir /mnt/vendor/persist/hvdcp_opti 0770 root system
#Create camera directory
mkdir /mnt/vendor/persist/camera 0755 system cameraserver
# Create pa-cal driver directory lct-20181009
mkdir /mnt/vendor/persist/audio 0770 audio audio
# limit discard size to 128MB in order to avoid long IO latency
write /sys/block/sda/queue/discard_max_bytes 134217728
# msm specific files that need to be created on /data
on post-fs-data
mkdir /data/vendor/misc 01771 system system
# Create directory used by display clients
mkdir /data/vendor/display 0770 system graphics
# Change lm related dirs
mkdir /data/vendor/lm 0700 root root
# Create directory used by powermodule
mkdir /data/vendor/pwr 0700 root root
# Create directory used by media clients
mkdir /data/vendor/media 0770 mediacodec media
# Create /data/vendor/tzstorage directory for SFS listener
mkdir /data/vendor/tzstorage 0770 system system
# Create directory for apps access via QTEEConnector
mkdir /data/vendor/qtee 0770 system system
#Create folder of camera
mkdir /data/vendor/camera 0770 system camera
#Create directory for tftp
mkdir /data/vendor/tombstones 0771 system system
mkdir /data/vendor/tombstones/rfs 0771 system system
mkdir /data/vendor/ramdump 0771 root system
mkdir /data/vendor/bluetooth 0770 bluetooth bluetooth
mkdir /data/vendor/ramdump/bluetooth 0770 bluetooth bluetooth
# Create the directories used by the Wireless subsystem
mkdir /data/vendor/wifi 0770 wifi wifi
mkdir /data/vendor/wifi/sockets 0770 wifi wifi
mkdir /data/vendor/wifi/hostapd 0770 wifi wifi
mkdir /data/vendor/wifi/hostapd/ctrl 0770 wifi wifi
mkdir /data/vendor/wifi/wpa_supplicant 0770 wifi wifi
mkdir /data/vendor/wifi/wigig_hostapd 0770 wifi wifi
mkdir /data/vendor/wifi/wpa 0770 wifi wifi
mkdir /data/vendor/wifi/wpa/sockets 0770 wifi wifi
# Create the directories used by WiGig Sensing
mkdir /data/vendor/sensing 0770 system wifi
# Create the directories used by CnE subsystem
mkdir /data/vendor/connectivity 0771 radio radio
chown radio radio /data/vendor/connectivity
# Create directory used by audio subsystem
mkdir /data/vendor/audio 0770 audio audio
# Create directory for audio delta files
mkdir /data/vendor/audio/acdbdata 0770 media audio
mkdir /data/vendor/audio/acdbdata/delta 0770 media audio
# Create directory for radio
mkdir /data/vendor/radio 0770 system radio
rm /data/vendor/radio/shmbus
# Create directory for modem_config
mkdir /data/vendor/modem_config 0570 radio root
# Mounting of persist is moved to 'on emmc-fs' and 'on fs' sections
# We chown/chmod /persist again so because mount is run as root + defaults
chown root system /persist
chmod 0771 /persist
chown system system /persist/WCNSS_qcom_wlan_nv.bin
chmod 0664 /sys/devices/platform/msm_sdcc.1/polling
chmod 0664 /sys/devices/platform/msm_sdcc.2/polling
chmod 0664 /sys/devices/platform/msm_sdcc.3/polling
chmod 0664 /sys/devices/platform/msm_sdcc.4/polling
# Chown polling nodes as needed from UI running on system server
chown system system /sys/devices/platform/msm_sdcc.1/polling
chown system system /sys/devices/platform/msm_sdcc.2/polling
chown system system /sys/devices/platform/msm_sdcc.3/polling
chown system system /sys/devices/platform/msm_sdcc.4/polling
#Create the symlink to qcn wpa_supplicant folder for ar6000 wpa_supplicant
#symlink /data/misc/wifi/wpa_supplicant /data/system/wpa_supplicant
#Create directories for Location services
mkdir /data/vendor/location 0770 gps gps
mkdir /data/vendor/location/mq 0770 gps gps
mkdir /data/vendor/location/xtwifi 0770 gps gps
mkdir /dev/socket/location 0770 gps gps
mkdir /dev/socket/location/mq 0770 gps gps
mkdir /dev/socket/location/xtra 0770 gps gps
mkdir /dev/socket/location/dgnss 0770 gps gps
#Create directories for wifihal services
mkdir /dev/socket/wifihal 0770 wifi wifi
chmod 2770 /dev/socket/wifihal
# Create /data/time folder for time-services
mkdir /data/vendor/time/ 0700 system system
setprop vold.post_fs_data_done 1
#Create a folder for SRS to be able to create a usercfg file
#mkdir /data/data/media 0770 media media
#Create FM dir for patchdownloader
mkdir /data/vendor/fm 0770 system system
chmod 0770 /data/vendor/fm
mkdir /data/vendor/secure_element 0777 system system
# Mark the copy complete flag to not completed
write /data/vendor/radio/copy_complete 0
chown radio radio /data/vendor/radio/copy_complete
chmod 0660 /data/vendor/radio/copy_complete
# copy prebuilt qcril.db files always
copy /vendor/radio/qcril_database/qcril.db /data/vendor/radio/qcril_prebuilt.db
chown radio radio /data/vendor/radio/qcril_prebuilt.db
chmod 0660 /data/vendor/radio/qcril_prebuilt.db
copy /vendor/radio/qcril_database/qcrilNr.db /data/vendor/radio/qcrilNr_prebuilt.db
copy /vendor/etc/qcril_database/qcrilNr.db /data/vendor/radio/qcrilNr_prebuilt.db
chown radio radio /data/vendor/radio/qcrilNr_prebuilt.db
chmod 0660 /data/vendor/radio/qcrilNr_prebuilt.db
# File flags for prebuilt ril db file
write /data/vendor/radio/prebuilt_db_support 1
chown radio radio /data/vendor/radio/prebuilt_db_support
chmod 0400 /data/vendor/radio/prebuilt_db_support
write /data/vendor/radio/db_check_done 0
chown radio radio /data/vendor/radio/db_check_done
chmod 0660 /data/vendor/radio/db_check_done
# qti-logkit data
mkdir /data/vendor/qti-logkit/ 0771 system system
mkdir /data/vendor/qti-logkit/shared-privileged/ 2770 system system
mkdir /data/vendor/qti-logkit/shared-public/ 2770 system diag
mkdir /data/vendor/qti-logkit/socket-privileged/ 2770 system system
mkdir /data/vendor/qti-logkit/socket-public/ 2750 system diag
mkdir /data/vendor/qti-logkit/logdata/ 2750 system shell
#Create SWAP related dirs
mkdir /data/vendor/swap 0770 root system
chmod 2770 /data/vendor/swap
# Create vpp directory
mkdir /data/vendor/vpp 0770 media media
#Create dir for TUI
mkdir /data/vendor/tui 0700 system drmrpc
service nqnfcinfo /system/vendor/bin/nqnfcinfo
class late_start
group nfc
user system
oneshot
service iop /system/vendor/bin/iop
class main
user root
group root
disabled
socket iop seqpacket 0666 root system
service qcomsysd /system/vendor/bin/qcom-system-daemon
class main
user root
group root diag oem_2901
disabled
on property:persist.vendor.qcomsysd.enabled=1
enable qcomsysd
on property:persist.vendor.qcomsysd.enabled=0
stop qcomsysd
on property:ro.vendor.iocgrp.config=1
mkdir /dev/blkio
mount cgroup none /dev/blkio blkio
chown system system /dev/blkio
chown system system /dev/blkio/tasks
chmod 0664 /dev/blkio/tasks
mkdir /dev/blkio/bg 0755 system system
chown system system /dev/blkio/bg/tasks
chmod 0664 /dev/blkio/bg/tasks
write /dev/blkio/blkio.weight 1000
write /dev/blkio/bg/blkio.weight 100
on property:persist.sys.mba_boot_timeout=*
write /sys/module/pil_msa/parameters/pbl_mba_boot_timeout_ms ${persist.sys.mba_boot_timeout}
on property:persist.sys.modem_auth_timeout=*
write /sys/module/pil_msa/parameters/modem_auth_timeout_ms ${persist.sys.modem_auth_timeout}
on property:persist.sys.pil_proxy_timeout=*
write /sys/module/peripheral_loader/parameters/proxy_timeout_ms ${persist.sys.pil_proxy_timeout}
on property:persist.vendor.sys.rawdump_copy=1
write /sys/kernel/dload/emmc_dload 1
on property:persist.vendor.sys.rawdump_copy=0
write /sys/kernel/dload/emmc_dload 0
on property:sys.boot_completed=1
write /dev/kmsg "Boot completed "
#Enable UFS clock scaling back
write /sys/bus/platform/devices/1d84000.ufshc/clkscale_enable 1
#WDSP FW boot sysfs node used by STHAL
chown media audio /sys/kernel/wdsp0/boot
chown media audio /sys/kernel/wcd_cpe0/fw_name
#Reinit lmkd to reconfigure lmkd properties
setprop lmkd.reinit 1
# corefile limit
on property:persist.debug.trace=1
mkdir /data/core 0777 root root
write /proc/sys/kernel/core_pattern "/data/core/%E.%p.%e"
on property:vendor.media.target.version=*
setprop vendor.sys.media.target.version ${vendor.media.target.version}
on property:vendor.netflix.bsp_rev=*
setprop ro.netflix.bsp_rev ${vendor.netflix.bsp_rev}
on property:vendor.media.target_variant=*
setprop ro.media.xml_variant.codecs ${vendor.media.target_variant}
setprop ro.media.xml_variant.codecs_performance ${vendor.media.target_variant}
on property:vold.decrypt=trigger_restart_framework
start wcnss-service
service vendor.qrtr-ns /vendor/bin/qrtr-ns -f
class core
user vendor_qrtr
group vendor_qrtr
capabilities NET_BIND_SERVICE
service irsc_util /vendor/bin/irsc_util "/vendor/etc/sec_config"
class core
user root
oneshot
service qmiproxy /system/bin/qmiproxy
class main
user radio
group radio diag
disabled
# Data Migration
service vendor.move_wifi_data /system/bin/move_wifi_data.sh
class main
user wifi
group wifi
disabled
oneshot
service vendor.sensingdaemon /vendor/bin/sensingdaemon
class hal
socket wigig/sensingdaemon stream 660 system wifi
user system
group wifi
disabled
service dhcpcd_wlan0 /system/bin/dhcpcd -ABKLG
class late_start
disabled
oneshot
service dhcpcd_bond0 /system/bin/dhcpcd -ABKLG
class late_start
disabled
oneshot
service dhcpcd_p2p /system/bin/dhcpcd -ABKLG
class late_start
disabled
oneshot
service dhcpcd_wigig0 /system/bin/dhcpcd -ABKLG
class late_start
disabled
oneshot
service iprenew_wlan0 /system/bin/dhcpcd -n
class late_start
disabled
oneshot
service iprenew_bond0 /system/bin/dhcpcd -n
class late_start
disabled
oneshot
service iprenew_p2p /system/bin/dhcpcd -n
class late_start
disabled
oneshot
service iprenew_wigig0 /system/bin/dhcpcd -n
class late_start
disabled
oneshot
service ptt_socket_app /system/vendor/bin/ptt_socket_app -d
class main
user wifi
group wifi system inet net_admin
capabilities NET_ADMIN
oneshot
service ptt_ffbm /system/vendor/bin/ptt_socket_app -f -d
user root
group root
disabled
oneshot
service wifi_ftmd /system/vendor/bin/wifi_ftmd
user system
group system inet net_admin
socket wififtmd_server dgram 0660 system system
disabled
oneshot
on property:vendor.wifi.ftmd.load=true
insmod /system/lib/modules/pronto/pronto_wlan.ko con_mode=5
service cnss-daemon /system/vendor/bin/cnss-daemon -n -l
class late_start
user system
group system inet net_admin wifi
capabilities NET_ADMIN
on property:sys.shutdown.requested=*
write /sys/kernel/shutdown_wlan/shutdown 1
stop cnss-daemon
service dhcpcd_bt-pan /system/bin/dhcpcd -BKLG
class late_start
disabled
oneshot
service iprenew_bt-pan /system/bin/dhcpcd -n
class late_start
disabled
oneshot
service ssgqmigd /vendor/bin/ssgqmigd
class late_start
user radio
group radio gps system
socket ssgqmig seqpacket 0660 radio inet
service mlid /vendor/bin/mlid
class late_start
user gps
group gps
socket mlid stream 0666 gps gps
service loc_launcher /system/vendor/bin/loc_launcher
class late_start
user gps
group gps
service qcom-sh /vendor/bin/init.qcom.sh
class late_start
user root
group root system radio
oneshot
on property:ro.vendor.ril.mbn_copy_completed=1
write /data/vendor/radio/copy_complete 1
service qvop-daemon /vendor/bin/qvop-daemon
class late_start
user system
group system drmrpc
service vendor.atfwd /vendor/bin/ATFWD-daemon
class late_start
user system
group system radio
service hostapd_fst /vendor/bin/hw/hostapd -dd -g /data/vendor/wifi/hostapd/global
class main
capabilities NET_ADMIN NET_RAW
user wifi
group wifi
disabled
oneshot
service battery_monitor /system/bin/battery_monitor
user system
group system
disabled
service vendor.ril-daemon2 /vendor/bin/hw/rild -c 2
class main
user radio
disabled
group radio cache inet misc audio sdcard_r sdcard_rw diag oem_2901 log
capabilities BLOCK_SUSPEND NET_ADMIN NET_RAW
service vendor.ril-daemon3 /vendor/bin/hw/rild -c 3
class main
user radio
disabled
group radio cache inet misc audio sdcard_r sdcard_rw diag oem_2901 log
capabilities BLOCK_SUSPEND NET_ADMIN NET_RAW
service profiler_daemon /system/bin/profiler_daemon
class late_start
user root
group root
disabled
service charger /system/bin/charger
class charger
user system
group system graphics input
capabilities SYS_BOOT
seclabel u:r:charger:s0
service vendor.ssr_diag /system/vendor/bin/ssr_diag
class late_start
user system
group system
disabled
service hvdcp /system/bin/hvdcp
class core
user root
disabled
on property:persist.usb.hvdcp.detect=true
start hvdcp
on property:persist.usb.hvdcp.detect=false
stop hvdcp
service charger_monitor /system/bin/charger_monitor
user root
group root
disabled
service qbcharger /charger -m 1
disabled
oneshot
on property:sys.qbcharger.enable=true
start qbcharger
on property:sys.qbcharger.enable=false
stop qbcharger
# service diag_mdlog_start /system/vendor/bin/diag_mdlog
service diag_mdlog_start /system/bin/diag_mdlog_system -n 40 -s 500
class late_start
user shell
# group system oem_2901 sdcard_rw sdcard_r media_rw
group system diag oem_2901 sdcard_rw sdcard_r media_rw
disabled
oneshot
#service diag_mdlog_stop /system/vendor/bin/diag_mdlog -k
service diag_mdlog_stop /system/bin/diag_mdlog_system -k
class late_start
user shell
# group system oem_2901 sdcard_rw sdcard_r media_rw
group system diag oem_2901 sdcard_rw sdcard_r media_rw
disabled
oneshot
on property:persist.vendor.mdlog.enable=true
start diag_mdlog_start
on property:persist.vendor.mdlog.enable=false
start diag_mdlog_stop
service qlogd /system/xbin/qlogd
socket qlogd stream 0662 system system
class main
disabled
on property:persist.vendor.qlogd=1
start qlogd
on property:persist.vendor.qlogd=0
stop qlogd
service vm_bms /vendor/bin/vm_bms
user root
group root
disabled
service vendor.msm_irqbalance /vendor/bin/msm_irqbalance -f /system/vendor/etc/msm_irqbalance.conf
class core
user root
group root
# service for USERDEBUG
service vendor.LKCore-dbg /vendor/bin/LKCore
class late_start
oneshot
disabled
user root
group root system log diag net_raw
# service for USER
service vendor.LKCore-rel /vendor/bin/LKCore
class late_start
oneshot
disabled
user system
group system log diag
service qseeproxydaemon /system/vendor/bin/qseeproxydaemon
class late_start
user system
group system
service esepmdaemon /system/vendor/bin/esepmdaemon
class core
user system
group nfc
on charger
setprop persist.sys.usb.config mass_storage
#add poweroffhandler
service poweroffhandler /system/vendor/bin/poweroffhandler
class core
user media
group graphics audio
disabled
oneshot
service time_daemon /vendor/bin/time_daemon
class main
user system
group system
capabilities SYS_TIME
# Set vendor-ril lib path based on Meta version
on property:vendor.rild.libpath=*
setprop rild.libpath ${vendor.rild.libpath}
on property:ro.vendor.radio.noril=*
setprop ro.radio.noril ${ro.vendor.radio.noril}
service vendor.power_off_alarm /vendor/bin/power_off_alarm
class core
group system
disabled
oneshot
service vendor.hbtp /vendor/bin/hbtp_daemon
class main
user system
group system
capabilities SYS_NICE
disabled
service chre /vendor/bin/chre
class late_start
user system
group system
socket chre seqpacket 0660 root system
shutdown critical
on property:vendor.chre.enabled=0
stop chre
service bugreport /system/bin/dumpstate -d -p -B -z -o /data/user_de/0/com.android.shell/files/bugreports/bugreport
class main
disabled
oneshot
keycodes 114 115 116
#Set GPU Opengles version
on property:vendor.opengles.version=*
setprop ro.opengles.version ${vendor.opengles.version}
#Set gpu available frequencies property
on property:vendor.gpu.available_frequencies=*
setprop ro.vendor.gpu.available_frequencies ${vendor.gpu.available_frequencies}
service vendor.audio-hal /vendor/bin/hw/android.hardware.audio.service
override
class hal
user audioserver
# media gid needed for /dev/fm (radio) and for /data/misc/media (tee)
group audio camera drmrpc inet media mediadrm net_bt net_bt_admin net_bw_acct oem_2901 wakelock
capabilities BLOCK_SUSPEND
ioprio rt 4
writepid /dev/cpuset/foreground/tasks /dev/stune/foreground/tasks
socket audio_hw_socket seqpacket 0666 system system
onrestart restart audioserver
service vendor.hwcomposer-2-4 /vendor/bin/hw/android.hardware.graphics.composer@2.4-service
override
class hal animation
user system
group graphics drmrpc
capabilities SYS_NICE
onrestart restart surfaceflinger
writepid /dev/cpuset/system-background/tasks
socket pps stream 0660 system system

View File

@ -0,0 +1,38 @@
# Copyright (c) 2017-2018,2020 The Linux Foundation. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials provided with the distribution.
# * Neither the name of The Linux Foundation nor
# the names of its contributors may be used to endorse or promote
# products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
on init
write /sys/class/backlight/panel0-backlight/brightness 200
setprop sys.usb.configfs 1
on property:ro.boot.usbcontroller=*
setprop sys.usb.controller ${ro.boot.usbcontroller}
write /sys/class/udc/${ro.boot.usbcontroller}/device/../mode peripheral
on fs
wait /dev/block/platform/soc/${ro.boot.bootdevice}
symlink /dev/block/platform/soc/${ro.boot.bootdevice} /dev/block/bootdevice

219
rootdir/etc/init.target.rc Normal file
View File

@ -0,0 +1,219 @@
# Copyright (c) 2013-2018,2020, The Linux Foundation. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above
# copyright notice, this list of conditions and the following
# disclaimer in the documentation and/or other materials provided
# with the distribution.
# * Neither the name of The Linux Foundation nor the names of its
# contributors may be used to endorse or promote products derived
# from this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
# BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
# BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
# OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
# IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
#
on early-init
# configure governor settings
write /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor schedutil
write /sys/devices/system/cpu/cpu0/cpufreq/schedutil/up_rate_limit_us 500
write /sys/devices/system/cpu/cpu0/cpufreq/schedutil/down_rate_limit_us 20000
write /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq 576000
# configure governor settings for big cluster
write /sys/devices/system/cpu/cpu6/cpufreq/scaling_governor schedutil
write /sys/devices/system/cpu/cpu6/cpufreq/schedutil/up_rate_limit_us 500
write /sys/devices/system/cpu/cpu6/cpufreq/schedutil/down_rate_limit_us 20000
write /sys/devices/system/cpu/cpu6/cpufreq/scaling_min_freq 652800
on init
write /sys/module/qpnp_rtc/parameters/poweron_alarm 1
wait /dev/block/platform/soc/${ro.boot.bootdevice}
symlink /dev/block/platform/soc/${ro.boot.bootdevice} /dev/block/bootdevice
# Boot time cpuset and stune
write /dev/cpuset/top-app/cpus 0-7
write /dev/cpuset/foreground/cpus 0-7
write /dev/cpuset/background/cpus 0-5
write /dev/cpuset/system-background/cpus 0-5
write /dev/cpuset/restricted/cpus 2-5
write /dev/stune/foreground/schedtune.prefer_idle 1
write /dev/stune/foreground/schedtune.prefer_high_cap 1
write /dev/stune/foreground/schedtune.boost 100
write /dev/stune/schedtune.prefer_idle 1
write /dev/stune/schedtune.prefer_high_cap 1
write /dev/stune/schedtune.boost 100
write /dev/stune/top-app/schedtune.prefer_idle 1
write /dev/stune/top-app/schedtune.prefer_high_cap 1
write /dev/stune/top-app/schedtune.boost 100
mkdir /dev/cpuset/camera-daemon
write /dev/cpuset/camera-daemon/cpus 0-7
write /dev/cpuset/camera-daemon/mems 0
chown cameraserver cameraserver /dev/cpuset/camera-daemon
chown cameraserver cameraserver /dev/cpuset/camera-daemon/tasks
chmod 0660 /dev/cpuset/camera-daemon/tasks
on early-fs
start vold
on fs
start hwservicemanager
mount_all --early
chown root system /mnt/vendor/persist
chmod 0771 /mnt/vendor/persist
restorecon_recursive /mnt/vendor/persist
mkdir /mnt/vendor/persist/data 0700 system system
mkdir /mnt/vendor/persist/subsys 0770 root system
mkdir /mnt/vendor/persist/audio 0755 system system
mkdir /mnt/vendor/persist/haptics 0755 system system
on post-fs
write /dev/ipa 1
on late-fs
wait_for_prop hwservicemanager.ready true
exec_start wait_for_keymaster
mount_all --late
on post-fs-data
mkdir /data/vendor/fpc 0770 system system
mkdir /data/vendor/goodix 0770 system system
mkdir /data/vendor/touchpad 0775 system system
mkdir /data/vendor/hbtp 0750 system system
mkdir /persist/qti_fp 0700 system system
mkdir /data/vendor/nnhal 0700 system system
mkdir /data/vendor/mac_addr 0771 system system
on boot
chown system system /sys/class/drm/card0-DSI-1/disp_param
chmod 0664 /sys/class/drm/card0-DSI-1/disp_param
chown system system /sys/class/drm/card0-DSI-1/mipi_reg
chmod 0664 /sys/class/drm/card0-DSI-1/mipi_reg
chown system system /sys/class/drm/card0-DSI-1/panel_info
chmod 0444 /sys/class/drm/card0-DSI-1/panel_info
chown system system /sys/kernel/hbtp/display_pwr
start rmt_storage
start rfs_access
chmod 0666 sys/devices/platform/soc/890000.i2c/i2c-1/1-005a/cali
chmod 0666 sys/devices/platform/soc/890000.i2c/i2c-1/1-005a/cali_save
chmod 0666 sys/devices/platform/soc/890000.i2c/i2c-1/1-005a/f0_save
chmod 0666 sys/devices/platform/soc/890000.i2c/i2c-1/1-005a/osc_save
chmod 0666 sys/devices/platform/soc/890000.i2c/i2c-1/1-005a/osc_cali
# access permissions for fingerprint
chown system system /sys/bus/platform/devices/soc/soc:fpc1020/irq
chown system system /sys/bus/platform/devices/soc/soc:fpc1020/wakeup_enable
chown system system /sys/bus/platform/devices/soc/soc:fpc1020/modalias
chmod 0666 /dev/qseecom
chmod 0644 /dev/goodix_fp
chown system system /dev/goodix_fp
#USB controller configuration
setprop vendor.usb.rndis.func.name "gsi"
setprop vendor.usb.rmnet.func.name "gsi"
setprop vendor.usb.rmnet.inst.name "rmnet"
setprop vendor.usb.dpl.inst.name "dpl"
setprop vendor.usb.qdss.inst.name "qdss"
setprop vendor.usb.controller a600000.dwc3
#pd-mapper
service vendor.pd_mapper /vendor/bin/pd-mapper
class core
user system
group system
#Peripheral manager
service vendor.per_mgr /vendor/bin/pm-service
class core
user system
group system
ioprio rt 4
service vendor.per_proxy /vendor/bin/pm-proxy
class core
user system
group system
disabled
service vendor.thermal-engine /vendor/bin/thermal-engine -c /vendor/etc/thermal-engine-${ro.boot.hwname}.conf
class main
user root
group root
on property:init.svc.vendor.per_mgr=running
start vendor.per_proxy
on property:sys.shutdown.requested=*
stop vendor.per_proxy
on charger
mkdir /mnt/vendor/persist
chown root system /mnt/vendor/persist
chmod 0771 /mnt/vendor/persist
mkdir /mnt/vendor/persist/subsys 0770 root system
setprop sys.usb.controller a600000.dwc3
setprop sys.usb.configfs 1
chown system system /sys/class/leds/red/brightness
chmod 0666 /sys/class/leds/red/brightness
chmod 0666 /sys/class/backlight/panel0-backlight/brightness
start vendor.power_off_alarm
on property:sys.boot_completed=1
# Read only one page at a time
write /proc/sys/vm/page-cluster 0
# Swap more aggressively
write /proc/sys/vm/swappiness 100
# Set zRAM compression algorithm to LZ4
write /sys/block/zram0/comp_algorithm lz4
# Enable zRAM data deduplication feature
write /sys/block/zram0/use_dedup 1
# Mount swap partitions specified in fstab
swapon_all /vendor/etc/fstab.qcom
# Back to default VM settings
write /proc/sys/vm/dirty_expire_centisecs 3000
write /proc/sys/vm/dirty_background_ratio 10
# Setup runtime cpusets
write /dev/cpuset/top-app/cpus 0-7
write /dev/cpuset/foreground/cpus 0-5,7
write /dev/cpuset/background/cpus 4-5
write /dev/cpuset/system-background/cpus 2-5
write /dev/cpuset/restricted/cpus 2-5
# Setup runtime schedTune
write /dev/stune/foreground/schedtune.prefer_idle 1
write /dev/stune/foreground/schedtune.prefer_high_cap 0
write /dev/stune/foreground/schedtune.boost 0
write /dev/stune/schedtune.prefer_idle 0
write /dev/stune/schedtune.prefer_high_cap 0
write /dev/stune/schedtune.boost 0
write /dev/stune/top-app/schedtune.prefer_idle 1
write /dev/stune/top-app/schedtune.prefer_high_cap 0
write /dev/stune/top-app/schedtune.boost 10
# Setup runtime blkio
# value for group_idle is us
write /dev/blkio/blkio.weight 1000
write /dev/blkio/background/blkio.weight 200
write /dev/blkio/blkio.group_idle 2000
write /dev/blkio/background/blkio.group_idle 0
on property:ro.boot.multisim_config=*
setprop persist.radio.multisim.config ${ro.boot.multisim_config}

481
rootdir/etc/ueventd.qcom.rc Normal file
View File

@ -0,0 +1,481 @@
# Copyright (c) 2012-2015, 2017-2020, The Linux Foundation. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials provided with the distribution.
# * Neither the name of The Linux Foundation nor
# the names of its contributors may be used to endorse or promote
# products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
# Firmware directory Path
# Below macro will be read by uevent and path will
# be added to search path for firmware loading
firmware_directories /vendor/firmware_mnt/image/
# the DIAG device node is not world writable/readable.
/dev/diag 0660 system oem_2901
/dev/mhi_*_pipe_4 0660 system system
/dev/genlock 0666 system system
/dev/wlan 0660 wifi wifi
/dev/kgsl 0666 system system
/dev/kgsl-3d0 0666 system system
/dev/kgsl-2d0 0666 root root
/dev/kgsl-2d1 0666 root root
/dev/ion 0664 system system
/dev/membuf 0664 system system
/dev/rtc0 0660 system system
/dev/smd0 0660 system system
/dev/smd4 0660 system system
/dev/smd_cxm_qmi 0640 radio radio
/dev/smd5 0660 system system
/dev/smd6 0660 system system
/dev/smd7 0660 bluetooth bluetooth
/dev/ccid_bridge 0660 system system
/dev/ipa 0660 radio radio
/dev/wwan_ioctl 0660 radio radio
/dev/ipaNatTable 0660 radio radio
/dev/rmnet_ctrl 0660 usb usb
/dev/dpl_ctrl 0660 usb usb
/dev/ipa_odl_ctl 0660 radio radio
/dev/ipa_adpl 0660 system oem_2905
/dev/synx_device 0660 root camera
/dev/hab 0666 system system
/dev/hgsl 0666 system system
/dev/iio:device* 0664 system system
#permissions for UFS RPMB BSG device node
/dev/0:0:0:49476 0600 system system
#permissions for CSVT
/dev/smd11 0660 radio radio
#permsissions for BT/FM
/dev/smd2 0660 bluetooth bluetooth
/dev/smd3 0660 bluetooth bluetooth
/dev/btpower 0660 bluetooth system
#permissions for pta
/dev/pta 0660 system system
/dev/radio0 0640 system system
/dev/rfcomm0 0660 bluetooth bluetooth
/dev/ttyUSB0 0660 bluetooth bluetooth
/dev/smdcntl0 0640 radio radio
/dev/smdcntl1 0640 radio radio
/dev/smdcntl2 0640 radio radio
/dev/smdcntl3 0640 radio radio
/dev/smdcntl4 0640 radio radio
/dev/smdcntl5 0640 radio radio
/dev/smdcntl6 0640 radio radio
/dev/smdcntl7 0640 radio radio
/dev/smdcntl8 0640 radio radio
/dev/smdcnt_rev0 0640 radio radio
/dev/smdcnt_rev1 0640 radio radio
/dev/smdcnt_rev2 0640 radio radio
/dev/smdcnt_rev3 0640 radio radio
/dev/smdcnt_rev4 0640 radio radio
/dev/smdcnt_rev5 0640 radio radio
/dev/smdcnt_rev6 0640 radio radio
/dev/smdcnt_rev7 0640 radio radio
/dev/smdcnt_rev8 0640 radio radio
/dev/smuxctl32 0640 radio radio
/dev/sdioctl0 0640 radio radio
/dev/sdioctl1 0640 radio radio
/dev/sdioctl2 0640 radio radio
/dev/sdioctl3 0640 radio radio
/dev/sdioctl4 0640 radio radio
/dev/sdioctl5 0640 radio radio
/dev/sdioctl6 0640 radio radio
/dev/sdioctl7 0640 radio radio
/dev/sdioctl8 0640 radio radio
/dev/rmnet_mux_ctrl 0640 radio radio
/dev/hsicctl0 0640 radio radio
/dev/hsicctl1 0640 radio radio
/dev/hsicctl2 0640 radio radio
/dev/hsicctl3 0640 radio radio
/dev/hsicctl4 0640 radio radio
/dev/hsicctl5 0640 radio radio
/dev/hsicctl6 0640 radio radio
/dev/hsicctl7 0640 radio radio
/dev/hsicctl8 0640 radio radio
/dev/hsicctl9 0640 radio radio
/dev/hsicctl10 0640 radio radio
/dev/hsicctl11 0640 radio radio
/dev/hsicctl12 0640 radio radio
/dev/hsicctl13 0640 radio radio
/dev/hsicctl14 0640 radio radio
/dev/hsicctl15 0640 radio radio
/dev/hsicctl16 0640 radio radio
/dev/mhi_*_pipe_14 0640 radio radio
/dev/mhi_*_pipe_16 0640 radio radio
/dev/mhi_*_pipe_32 0640 radio radio
/dev/at_usb0 0640 radio radio
/dev/at_mdm0 0640 radio radio
/dev/video* 0660 system camera
/dev/cvp* 0660 system camera
/dev/media* 0660 system camera
/dev/v4l-subdev* 0660 system camera
/dev/qseecom 0660 system drmrpc
/dev/qce 0660 system drmrpc
/dev/smcinvoke 0660 system drmrpc
/dev/qsee_ipc_irq_spss 0660 system drmrpc
/dev/seemplog 0660 system system
/dev/pft 0660 system drmrpc
/dev/spcom 0660 system system
/dev/spss_utils 0660 system system
/dev/sp_kernel 0660 system system
/dev/sp_nvm 0660 system system
/dev/sp_ssr 0660 system system
/dev/sp_keymaster 0660 system system
/dev/sp_keymaster_ssr 0660 system system
/dev/sec_nvm_* 0660 system system
/dev/cryptoapp 0660 system system
/dev/spdaemon_ssr 0660 system system
/dev/spu_hal_ssr 0660 system system
/dev/iuicc* 0660 system system
/dev/gemini0 0660 system camera
/dev/jpeg0 0660 system camera
/dev/jpeg1 0660 system camera
/dev/jpeg2 0660 system camera
/dev/jpeg3 0660 system camera
/dev/adsprpc-smd 0664 system system
/dev/adsprpc-smd-secure 0644 system system
/dev/system_health_monitor 0644 radio system
/dev/mdss_rotator 0664 system system
#QDSS
/dev/byte-cntr 0660 system oem_2902
/dev/mhi_qdss 0660 system oem_2902
/sys/class/qdss_bridge/mhi_qdss mode 0660 system oem_2902
#qg
/dev/qg 0660 system system
/dev/qg_battery 0660 system system
#qvr
/dev/qvr_external_sensor_ioctl 0660 system system
/sys/kernel/qvr_external_sensor fd 0660 system system
/dev/bus/usb/* 0660 root usb
/dev/hidraw* 0660 root usb
# wlan
/dev/wcnss_wlan 0660 system system
/dev/wcnss_ctrl 0660 system system
/sys/devices/soc/a000000.qcom,wcnss-wlan/net/wlan0/queues/rx-* rps_cpus 0660 system system
/sys/devices/soc/a000000.qcom,wcnss-wlan/net/p2p0/queues/rx-* rps_cpus 0660 system system
/sys/devices/platform/soc/*.qcom,icnss/net/wlan*/queues/rx-* rps_cpus 0660 system system
/sys/devices/platform/soc/1c00000.qcom,pcie/pci0000:00/0000:00:00.0/0000:01:00.0/net/wlan*/queues/rx-* rps_cpus 0660 system system
/sys/devices/platform/soc/17a10040.qcom,wcn6750/net/wlan*/queues/rx-* rps_cpus 0660 system system
/dev/spidev0.0 0660 system audio
/dev/spidev0.1 0660 system system
/dev/i2c-7 0660 system audio
/dev/msm_camera/* 0660 system camera
/dev/gemini/ 0660 system camera
/dev/mercury0 0660 system camera
/dev/msm_vidc_reg 0660 system audio
/dev/msm_vidc_dec 0660 system audio
/dev/msm_vidc_dec_sec 0660 system audio
/dev/msm_vidc_enc 0660 system audio
/dev/msm_rotator 0660 system system
/dev/hw_random 0600 root root
/dev/sdsprpc-smd 0660 system system
#permissions for audio
/dev/wcd_dsp0_control 0660 system audio
/dev/wcd-dsp-glink 0660 system audio
/dev/audio_slimslave 0660 system audio
/dev/msm_qcelp 0660 system audio
/dev/msm_evrc 0660 system audio
/dev/msm_wma 0660 system audio
/dev/msm_wmapro 0660 system audio
/dev/msm_alac 0660 system audio
/dev/msm_ape 0660 system audio
/dev/msm_amrnb 0660 system audio
/dev/msm_amrwb 0660 system audio
/dev/msm_amrwbplus 0660 system audio
/dev/msm_aac 0660 system audio
/dev/msm_multi_aac 0660 system audio
/dev/msm_aac_in 0660 system audio
/dev/msm_qcelp_in 0660 system audio
/dev/msm_evrc_in 0660 system audio
/dev/msm_amrnb_in 0660 system audio
/dev/msm_amrwb_in 0660 system audio
/dev/msm_a2dp_in 0660 system audio
/dev/msm_ac3 0660 system audio
/dev/msm_audio_cal 0660 system audio
/dev/msm_hweffects 0660 system audio
/dev/msm_cad 0660 system audio
/dev/msm_fm 0660 system audio
/dev/msm_mvs 0660 system audio
/dev/msm_pcm_lp_dec 0660 system audio
/dev/msm_preproc_ctl 0660 system audio
/dev/msm_rtac 0660 system audio
/dev/msm_voicememo 0660 system audio
/dev/ttyHSL1 0660 system system
/dev/ttyHS1 0660 system system
/dev/mdm 0660 system radio
/sys/devices/virtual/smdpkt/smdcntl* open_timeout 0664 radio radio
/dev/sdio_tty_ciq_00 0660 system system
/dev/tty_sdio_00 0660 system system
/dev/ttyGS0 0660 system system
/dev/i2c-5 0660 media media
/dev/avtimer 0660 system audio
/dev/spidev2.0 0660 system audio
/dev/spidev22.0 0660 system audio
/dev/spidev10.0 0660 system audio
# DVB devices
/dev/dvb/adapter0/demux* 0440 media media
/dev/dvb/adapter0/dvr* 0660 media media
/dev/dvb/adapter0/video* 0660 media media
# Broadcast devices
/dev/tsc_mux0 0660 media media
/dev/tsc_ci0 0660 media media
# sensors
/dev/sensors 0660 system system
/sys/devices/i2c-12/12-* pollrate_ms 0664 system system
/sys/devices/f9925000.i2c/i2c-0/0-* enable 0660 input system
/sys/devices/f9925000.i2c/i2c-0/0-* poll_delay 0660 input system
/sys/devices/soc.0/78b6000.i2c/i2c-0/0-* enable 0660 input system
/sys/devices/soc.0/78b6000.i2c/i2c-0/0-* poll_delay 0660 input system
/sys/devices/soc.0/78b6000.i2c/i2c-0/0-* enable_wakeup 0660 input system
/sys/devices/soc.0/78b6000.i2c/i2c-0/0-* max_latency 0660 input system
/sys/devices/soc.0/78b6000.i2c/i2c-0/0-* flush 0660 input system
/sys/devices/soc.0/78b6000.i2c/i2c-0/0-* calibrate 0660 input system
/sys/devices/soc.0/78b5000.i2c/i2c-1/1-* enable 0660 input system
/sys/devices/soc.0/78b5000.i2c/i2c-1/1-* poll_delay 0660 input system
/sys/devices/soc.0/78b5000.i2c/i2c-1/1-* enable_wakeup 0660 input system
/sys/devices/soc.0/78b5000.i2c/i2c-1/1-* max_latency 0660 input system
/sys/devices/soc.0/78b5000.i2c/i2c-1/1-* flush 0660 input system
/sys/devices/soc.0/78b5000.i2c/i2c-1/1-* calibrate 0660 input system
/sys/devices/virtual/optical_sensors/proximity ps_adc 0660 input system
/sys/devices/virtual/optical_sensors/proximity ps_poll_delay 0660 input system
/sys/devices/virtual/optical_sensors/lightsensor ls_auto 0660 input system
/sys/devices/virtual/optical_sensors/lightsensor ls_poll_delay 0660 input system
/sys/devices/virtual/input/input* poll 0660 input system
/sys/devices/virtual/input/input* pollrate_ms 0660 input system
/sys/devices/soc/78b7000.i2c/i2c-3/3-0020/input/input* secure_touch 0440 system drmrpc
/sys/devices/soc/78b7000.i2c/i2c-3/3-0020/input/input* secure_touch_enable 0660 system drmrpc
/sys/devices/soc/78b7000.i2c/i2c-3/3-0038/input/input* secure_touch 0440 system drmrpc
/sys/devices/soc/78b7000.i2c/i2c-3/3-0038/input/input* secure_touch_enable 0660 system drmrpc
/sys/devices/soc/78b7000.i2c/i2c-3/3-004b/input/input* secure_touch 0440 system drmrpc
/sys/devices/soc/78b7000.i2c/i2c-3/3-004b/input/input* secure_touch_enable 0660 system drmrpc
/sys/devices/soc/c179000.i2c/i2c-5/5-0020/input/input* secure_touch 0440 system drmrpc
/sys/devices/soc/c179000.i2c/i2c-5/5-0020/input/input* secure_touch_enable 0660 system drmrpc
/sys/devices/platform/soc/a98000.i2c/i2c-2/2-0020/input/input* secure_touch 0440 system drmrpc
/sys/devices/platform/soc/a98000.i2c/i2c-2/2-0020/input/input* secure_touch_enable 0660 system drmrpc
/sys/devices/platform/soc/a84000.i2c/i2c-2/2-0020/input/input* secure_touch 0440 system drmrpc
/sys/devices/platform/soc/a84000.i2c/i2c-2/2-0020/input/input* secure_touch_enable 0660 system drmrpc
/sys/devices/platform/soc/soc:fpc1020* fingerdown_wait 0220 system system
# GNSS Device premissions
/dev/gnss_sirf 0660 gps gps
# laser sensor access
/sys/devices/virtual/input/input* enable_ps_sensor 0660 system input
/sys/devices/virtual/input/input* set_delay_ms 0660 system input
/sys/devices/virtual/input/input* do_flush 0660 system input
# vm_bms
/dev/vm_bms 0660 system system
/dev/battery_data 0660 system system
# wlan
/dev/wcnss_wlan 0660 system system
/dev/wcnss_ctrl 0660 system system
/sys/devices/soc/600000.qcom,pcie/pci0000:00/0000:00:00.0/0000:01:00.0/net/wlan0/queues/rx-* rps_cpus 0660 system system
/sys/devices/soc/600000.qcom,pcie/pci0000:00/0000:00:00.0/0000:01:00.0/net/p2p0/queues/rx-* rps_cpus 0660 system system
# wigig
/sys/bus/pci/drivers/wil6210* 0000:01:00.0/wil6210/fst_link_loss 0660 wifi wifi
/sys/bus/pci/drivers/wil6210* 0000:01:00.0/wil6210/thermal_throttling 0660 system system
/sys/bus/pci/drivers/wil6210* 0000:01:00.0/wil6210/snr_thresh 0660 wifi wifi
/sys/bus/pci/drivers/wil6210* 0000:01:00.0/net/wigig0/queues/rx-0/rps_cpus 0660 system system
/sys/bus/pci/drivers/wil6210* 0000:01:00.0/net/wigig0/gro_flush_timeout 0660 system system
/sys/devices/virtual/net/bond0 queues/rx-0/rps_cpus 0660 system system
#nfc permissions
/dev/nfc-nci 0660 nfc nfc
/dev/nq-nci 0660 nfc nfc
/dev/assd 0660 nfc nfc
# UIO devices
/dev/uio0 0660 system system
/dev/uio1 0660 system system
/dev/uio2 0660 system system
# SSR devices
/dev/subsys_* 0640 system system
# Ultrasound device
/dev/usf1 0660 system system
# Ramdump devices
/dev/ramdump* 0640 system system
# Fingerprint device
/dev/qbt* 0660 system system
/sys/class/fts/touch_aoi aoi_set 0660 root system
/sys/class/fts/touch_aoi power_set 0660 root system
#ImproveTouch device
/dev/hbtp_input 0660 system system
/dev/hbtp_vm 0660 system system
# Add device block for FRP
/dev/block/platform/soc/7824900.sdhci/by-name/config 0600 system system
/dev/block/platform/soc/7464900.sdhci/by-name/frp 0600 system system
/dev/block/platform/soc/624000.ufshc/by-name/frp 0600 system system
/dev/block/platform/soc/1da4000.ufshc/by-name/frp 0600 system system
/dev/block/platform/soc/c0c4000.sdhci/by-name/frp 0600 system system
/dev/block/platform/soc/1d84000.ufshc/by-name/frp 0600 system system
/dev/block/platform/soc/7c4000.sdhci/by-name/frp 0600 system system
/dev/block/platform/soc/4744000.sdhci/by-name/frp 0600 system system
/dev/block/platform/soc/4804000.ufshc/by-name/frp 0600 system system
# This is temporary while using SD card for initial bring-up
/dev/block/platform/soc/8804000.sdhci/by-name/frp 0600 system system
# Kmsg device
/dev/kmsg 0620 root system
# LED class devices
/sys/class/leds/red delay_on 0640 system system
/sys/class/leds/red delay_off 0640 system system
/sys/class/leds/red breath 0640 system system
/sys/class/leds/red trigger 0640 system system
/sys/class/leds/green delay_on 0640 system system
/sys/class/leds/green delay_off 0640 system system
/sys/class/leds/green breath 0640 system system
/sys/class/leds/green trigger 0640 system system
/sys/class/leds/blue delay_on 0640 system system
/sys/class/leds/blue delay_off 0640 system system
/sys/class/leds/blue breath 0640 system system
/sys/class/leds/blue trigger 0640 system system
# NPU device
/dev/msm_npu 0644 system system
# USB role switch
/sys/class/dual_role_usb/* data_role 0660 system system
/sys/class/dual_role_usb/* power_role 0660 system system
/sys/class/dual_role_usb/* mode 0660 system system
#Memory Offline
/sys/devices/system/memory/memory* state 0660 system system
/sys/devices/virtual/hdcp/msm_hdcp min_level_change 0664 system graphics
# sys-fs display
/sys/class/graphics/fb* hpd 0664 system graphics
/sys/class/graphics/fb* res_info 0664 system graphics
/sys/class/graphics/fb* vendor_name 0664 system graphics
/sys/class/graphics/fb* product_description 0664 system graphics
/sys/class/graphics/fb* video_mode 0664 system graphics
/sys/class/graphics/fb* format_3d 0664 system graphics
/sys/class/graphics/fb* s3d_mode 0664 system graphics
/sys/class/graphics/fb* dynamic_fps 0664 system graphics
/sys/class/graphics/fb* msm_fb_dfps_mode 0664 system graphics
/sys/class/graphics/fb* hdr_stream 0664 system graphics
/sys/class/graphics/fb* cec/enable 0664 system graphics
/sys/class/graphics/fb* cec/logical_addr 0664 system graphics
/sys/class/graphics/fb* cec/rd_msg 0664 system graphics
/sys/class/graphics/fb* pa 0664 system graphics
/sys/class/graphics/fb* cec/wr_msg 0600 system graphics
/sys/class/graphics/fb* hdcp/tp 0664 system graphics
/sys/class/graphics/fb* hdcp2p2/min_level_change 0660 system graphics
/sys/class/graphics/fb* hdmi_audio_cb 0600 audioserver audio
/sys/class/graphics/fb* lineptr_value 0664 system graphics
/sys/class/graphics/fb* msm_fb_persist_mode 0664 system graphics
/sys/class/graphics/fb0 idle_time 0664 system graphics
/sys/class/graphics/fb0 dynamic_fps 0664 system graphics
/sys/class/graphics/fb0 dyn_pu 0664 system graphics
/sys/class/graphics/fb0 modes 0664 system graphics
/sys/class/graphics/fb0 mode 0664 system graphics
/sys/class/graphics/fb0 msm_cmd_autorefresh_en 0664 system graphics
/sys/devices/platform/soc/ae00000.qcom,mdss_mdp power/control 0664 system graphics
#asm330 sensor
#common sensors files
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* buffer/enable 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* buffer/length 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* buffer/watermark 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* discharded_samples 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* current_timestamp_clock 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* hwfifo_flush 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* hwfifo_watermark 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* hwfifo_watermark_max 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* mount_matrix 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* name 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* sampling_frequency 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* sampling_frequency_available 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_timestamp_en 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_timestamp_index 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_timestamp_type 0664 system system
# standard iio accel attributes
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_accel_scale_available 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_accel_x_raw 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_accel_x_scale 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_accel_y_raw 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_accel_y_scale 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_accel_z_raw 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_accel_z_scale 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_accel_x_en 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_accel_x_index 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_accel_x_type 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_accel_y_en 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_accel_y_index 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_accel_y_type 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_accel_z_en 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_accel_z_index 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_accel_z_type 0664 system system
# standard iio gyro attributes
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_anglvel_scale_available 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_anglvel_x_raw 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_anglvel_x_scale 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_anglvel_y_raw 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_anglvel_y_scale 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_anglvel_z_raw 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_anglvel_z_scale 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_anglvel_x_en 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_anglvel_x_index 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_anglvel_x_type 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_anglvel_y_en 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_anglvel_y_index 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_anglvel_y_type 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_anglvel_z_en 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_anglvel_z_index 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* scan_elements/in_anglvel_z_type 0664 system system
# standard iio temp attributes
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_temp_offset 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_temp_raw 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_temp_scale 0664 system system
/sys/devices/platform/soc/*.i2c/i2c-*/*-*/iio:device* in_temp_scale_available 0664 system system

View File

@ -0,0 +1,2 @@
# WiFi Display
persist.vendor.setWFDInfo. u:object_r:vendor_wfd_sys_debug_prop:s0

View File

@ -0,0 +1 @@
get_prop(system_server, vendor_wfd_sys_debug_prop)

View File

@ -0,0 +1 @@
get_prop(vendor_wfd_app, vendor_wfd_sys_debug_prop)

2
sepolicy/vendor/adsprpcd.te vendored Normal file
View File

@ -0,0 +1,2 @@
r_dir_file(vendor_adsprpcd, public_adsprpcd_file)
r_dir_file(vendor_adsprpcd, vendor_sysfs_graphics)

6
sepolicy/vendor/app.te vendored Normal file
View File

@ -0,0 +1,6 @@
allow { appdomain -isolated_app } adsprpcd_file:dir r_dir_perms;
allow { appdomain -isolated_app } public_adsprpcd_file:file r_file_perms;
allow { appdomain -isolated_app } vendor_xdsp_device:chr_file r_file_perms;
get_prop({ appdomain -isolated_app }, vendor_fingerprint_prop)
get_prop({ appdomain -isolated_app }, vendor_tee_listener_prop)

49
sepolicy/vendor/batterysecret.te vendored Normal file
View File

@ -0,0 +1,49 @@
type batterysecret, domain;
type batterysecret_exec, exec_type, vendor_file_type, file_type;
init_daemon_domain(batterysecret)
r_dir_file(batterysecret, cgroup)
r_dir_file(batterysecret, mnt_vendor_file)
r_dir_file(batterysecret, vendor_sysfs_battery_supply)
r_dir_file(batterysecret, sysfs_batteryinfo)
r_dir_file(batterysecret, sysfs_type)
r_dir_file(batterysecret, vendor_sysfs_usb_supply)
r_dir_file(batterysecret, vendor_sysfs_usbpd_device)
allow batterysecret {
mnt_vendor_file
persist_subsys_file
rootfs
}:dir rw_dir_perms;
allow batterysecret {
persist_subsys_file
vendor_sysfs_battery_supply
sysfs_usb
vendor_sysfs_usb_supply
vendor_sysfs_usbpd_device
}:file w_file_perms;
allow batterysecret kmsg_device:chr_file rw_file_perms;
allow batterysecret self:netlink_kobject_uevent_socket create_socket_perms_no_ioctl;
allow batterysecret self:global_capability_class_set {
sys_tty_config
sys_boot
};
allow batterysecret self:capability {
chown
fsetid
};
allow batterysecret {
system_suspend_hwservice
hidl_manager_hwservice
}:hwservice_manager find;
binder_call(batterysecret, system_suspend_server)
wakelock_use(batterysecret)

1
sepolicy/vendor/cdsprpcd.te vendored Normal file
View File

@ -0,0 +1 @@
r_dir_file(vendor_cdsprpcd, public_adsprpcd_file)

3
sepolicy/vendor/device.te vendored Normal file
View File

@ -0,0 +1,3 @@
type fingerprint_device, dev_type;
type lirc_device, dev_type;

19
sepolicy/vendor/file.te vendored Normal file
View File

@ -0,0 +1,19 @@
type audio_socket, file_type;
type camera_persist_file, file_type, vendor_persist_type;
type fingerprint_data_file, data_file_type, core_data_file_type, file_type;
type persist_subsys_file, vendor_persist_type, file_type;
type public_adsprpcd_file, file_type;
type sysfs_msm_boot, fs_type, sysfs_type;
type sysfs_msm_subsys, sysfs_type, fs_type;
type thermal_link_device, dev_type;
type sysfs_touchpanel, fs_type, sysfs_type;
type vendor_sysfs_iio, fs_type, sysfs_type;

45
sepolicy/vendor/file_contexts vendored Normal file
View File

@ -0,0 +1,45 @@
# Audio
/dev/socket/audio_hw_socket u:object_r:audio_socket:s0
# Camera
/mnt/vendor/persist/camera(/.*)? u:object_r:camera_persist_file:s0
# Charger
/vendor/bin/batterysecret u:object_r:batterysecret_exec:s0
# Fingerprint
/vendor/bin/hw/android\.hardware\.biometrics\.fingerprint@2.3-service\.xiaomi u:object_r:hal_fingerprint_default_exec:s0
# Fingerprint - devices
/dev/goodix_fp u:object_r:fingerprint_device:s0
# Fingerprint - data
/data/vendor/goodix(/.*)? u:object_r:fingerprint_vendor_data_file:s0
/data/vendor/fpc(/.*)? u:object_r:fingerprint_vendor_data_file:s0
# Hexagon DSP-side executable needed for Halide operation
# This is labeled as public_adsprpcd_file as it needs to be read by apps
# (e.g. Google Camera App)
/mnt/vendor/dsp/fastrpc_shell_3 u:object_r:public_adsprpcd_file:s0
# IR
/dev/spidev0.1 u:object_r:lirc_device:s0
# Lights
/vendor/bin/hw/android\.hardware\.light-service\.xiaomi u:object_r:hal_light_default_exec:s0
# Persist subsystem
/mnt/vendor/persist/subsys(/.*)? u:object_r:persist_subsys_file:s0
# Power
/vendor/bin/hw/android\.hardware\.power-service\.xiaomi-libperfmgr u:object_r:hal_power_default_exec:s0
# Sys
/sys/bus/iio/devices u:object_r:vendor_sysfs_iio:s0
/sys/devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-00/c440000.qcom,spmi:qcom,pm6150@0:vadc@3100/iio:device0(/.*)? u:object_r:vendor_sysfs_iio:s0
/sys/devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-04/c440000.qcom,spmi:qcom,pm6150l@4:vadc@3100/iio:device1(/.*)? u:object_r:vendor_sysfs_iio:s0
# Thermal
/vendor/bin/hw/android\.hardware\.thermal@2\.0-service\.pixel u:object_r:hal_thermal_default_exec:s0
/vendor/bin/thermal_symlinks u:object_r:init-thermal-symlinks-sh_exec:s0
/dev/thermal(/.*)? u:object_r:thermal_link_device:s0

59
sepolicy/vendor/genfs_contexts vendored Normal file
View File

@ -0,0 +1,59 @@
# DSP
genfscon sysfs /kernel/boot_cdsp/boot u:object_r:sysfs_msm_boot:s0
# Display
genfscon sysfs /devices/platform/soc/5000000.qcom,kgsl-3d0 u:object_r:sysfs_msm_subsys:s0
genfscon sysfs /devices/platform/soc/ae00000.qcom,mdss_mdp/idle_state u:object_r:vendor_sysfs_graphics:s0
genfscon sysfs /devices/platform/soc/soc:qcom,cpu-cpu-llcc-bw u:object_r:sysfs_msm_subsys:s0
genfscon sysfs /devices/platform/soc/soc:qcom,cpu-llcc-ddr-bw u:object_r:sysfs_msm_subsys:s0
genfscon sysfs /devices/platform/soc/soc:qcom,cpu0-cpu-l3-lat u:object_r:sysfs_msm_subsys:s0
genfscon sysfs /devices/platform/soc/soc:qcom,cpu6-cpu-l3-lat u:object_r:sysfs_msm_subsys:s0
genfscon sysfs /devices/platform/soc/soc:qcom,dsi-display u:object_r:vendor_sysfs_graphics:s0
genfscon sysfs /devices/platform/soc/soc:qcom,gpubw u:object_r:sysfs_msm_subsys:s0
genfscon sysfs /devices/platform/soc/soc:qcom,gpubw/devfreq u:object_r:sysfs_msm_subsys:s0
# Health
genfscon sysfs /class/power_supply/battery/capacity u:object_r:vendor_sysfs_battery_supply:s0
genfscon sysfs /devices/platform/soc/soc:maxim_ds28e16/power_supply/batt_verify u:object_r:vendor_sysfs_battery_supply:s0
# LED
genfscon sysfs /devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-05/c440000.qcom,spmi:qcom,pm6150l@5:qcom,leds@d000/leds/white u:object_r:sysfs_leds:s0
# Touchpanel
genfscon sysfs /touchpanel u:object_r:sysfs_touchpanel:s0
# Wakeup source stats
genfscon sysfs /devices/platform/soc/18800000.qcom,icnss/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/88c000.qcom,qup_uart/tty/ttyHS0/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/88e0000.qcom,msm-eud/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/890000.i2c/i2c-1/1-005a/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/a600000.ssusb/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-00/c440000.qcom,spmi:qcom,pm6150@0:qcom,power-on@800/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-00/c440000.qcom,spmi:qcom,pm6150@0:qcom,qpnp-smb5/power_supply/battery/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-00/c440000.qcom,spmi:qcom,pm6150@0:qcom,qpnp-smb5/power_supply/dc/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-00/c440000.qcom,spmi:qcom,pm6150@0:qcom,qpnp-smb5/power_supply/main/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-00/c440000.qcom,spmi:qcom,pm6150@0:qcom,qpnp-smb5/power_supply/pc_port/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-00/c440000.qcom,spmi:qcom,pm6150@0:qcom,qpnp-smb5/power_supply/usb/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-00/c440000.qcom,spmi:qcom,pm6150@0:qcom,qpnp-smb5/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-00/c440000.qcom,spmi:qcom,pm6150@0:qcom,usb-pdphy@1700/usbpd/usbpd0/otg_default/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-00/c440000.qcom,spmi:qcom,pm6150@0:qcom,usb-pdphy@1700/usbpd/usbpd0/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-00/c440000.qcom,spmi:qcom,pm6150@0:qpnp,qg/power_supply/bms/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-04/c440000.qcom,spmi:qcom,pm6150l@4:qcom,power-on@800/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/soc:gpio_keys/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/soc:qcom,msm-audio-apr/soc:qcom,msm-audio-apr:qcom,q6core-audio/soc:qcom,msm-audio-apr:qcom,q6core-audio:bolero-cdc/rx-macro/rx_swr_ctrl/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/platform/soc/soc:qcom,msm-audio-apr/soc:qcom,msm-audio-apr:qcom,q6core-audio/soc:qcom,msm-audio-apr:qcom,q6core-audio:bolero-cdc/tx-macro/tx_swr_ctrl/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/input/input1/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/misc/msm_aac/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/misc/msm_alac/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/misc/msm_amrnb/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/misc/msm_amrwbplus/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/misc/msm_amrwb/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/misc/msm_ape/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/misc/msm_evrc/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/misc/msm_g711alaw/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/misc/msm_g711mlaw/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/misc/msm_mp3/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/misc/msm_multi_aac/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/misc/msm_qcelp/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/misc/msm_wma/power/wakeup u:object_r:sysfs_wakeup:s0
genfscon sysfs /devices/virtual/misc/msm_wmapro/power/wakeup u:object_r:sysfs_wakeup:s0

14
sepolicy/vendor/hal_audio_default.te vendored Normal file
View File

@ -0,0 +1,14 @@
# For interfacing with PowerHAL
hal_client_domain(hal_audio_default, hal_power)
# Allow hal_audio_default to read vendor_persist_audio_file
r_dir_file(hal_audio_default, vendor_persist_audio_file)
r_dir_file(hal_audio_default, sysfs)
binder_call(hal_audio_default, system_suspend_server)
set_prop(hal_audio_default, vendor_audio_prop)
allow hal_audio_default audio_socket:sock_file rw_file_perms;
allow hal_audio_default system_suspend_hwservice:hwservice_manager find;

View File

@ -0,0 +1,2 @@
# Allow hal_bluetooth_default to read files in vendor_wifi_vendor_data_file
r_dir_file(hal_bluetooth_default, vendor_wifi_vendor_data_file)

20
sepolicy/vendor/hal_camera_default.te vendored Normal file
View File

@ -0,0 +1,20 @@
# For interfacing with PowerHAL
hal_client_domain(hal_camera_default, hal_power)
# Allow hal_camera_default to read to vendor_sysfs_kgsl
r_dir_file(hal_camera_default, vendor_sysfs_kgsl)
# Allow hal_camera_default to read to mnt/vendor/persist/camera
r_dir_file(hal_camera_default, camera_persist_file)
r_dir_file(hal_camera_default, mnt_vendor_file)
r_dir_file(hal_camera_default, vendor_persist_sensors_file)
allow hal_camera_default proc_stat:file read;
set_prop(hal_camera_default, vendor_camera_prop)
allow hal_camera_default socket_device:sock_file write;
allow hal_camera_default proc_stat:file { open };
allow hal_camera_default public_adsprpcd_file:file r_file_perms;
allow hal_camera_default vendor_xdsp_device:chr_file r_file_perms;

View File

@ -0,0 +1,33 @@
typeattribute hal_fingerprint_default data_between_core_and_vendor_violators;
allow hal_fingerprint_default fingerprint_data_file:dir rw_dir_perms;
allow hal_fingerprint_default fingerprint_data_file:file create_file_perms;
allow hal_fingerprint_default {
fingerprint_device
input_device
tee_device
uhid_device
}: chr_file rw_file_perms;
allow hal_fingerprint_default self:netlink_socket create_socket_perms_no_ioctl;
allow hal_fingerprint_default {
input_device
vendor_sysfs_graphics
sysfs_msm_subsys
}: dir r_dir_perms;
allow hal_fingerprint_default {
vendor_sysfs_fingerprint
vendor_sysfs_fps_attr
vendor_sysfs_graphics
sysfs_msm_subsys
}: file rw_file_perms;
r_dir_file(hal_fingerprint_default, firmware_file)
set_prop(hal_fingerprint_default, vendor_fingerprint_prop)
allow hal_fingerprint_default vendor_sysfs_spss:dir { search };
allow hal_fingerprint_default vendor_sysfs_spss:file { open read };

2
sepolicy/vendor/hal_health_default.te vendored Normal file
View File

@ -0,0 +1,2 @@
allow hal_health_default sysfs_wakeup:dir r_dir_perms;
allow hal_health_default sysfs_wakeup:file r_file_perms;

4
sepolicy/vendor/hal_ir_default.te vendored Normal file
View File

@ -0,0 +1,4 @@
allow hal_ir_default lirc_device:{
chr_file
file
} rw_file_perms;

5
sepolicy/vendor/hal_light_default.te vendored Normal file
View File

@ -0,0 +1,5 @@
allow hal_light_default {
sysfs_leds
}:file rw_file_perms;
r_dir_file(hal_light_default, sysfs_leds)

View File

@ -0,0 +1,3 @@
r_dir_file(vendor_hal_neuralnetworks_default, public_adsprpcd_file)
get_prop(vendor_hal_neuralnetworks_default, vendor_adsprpc_prop)

3
sepolicy/vendor/hal_nfc_default.te vendored Normal file
View File

@ -0,0 +1,3 @@
# Data file accesses.
allow hal_nfc_default vendor_nfc_vendor_data_file:dir create_dir_perms;
allow hal_nfc_default vendor_nfc_vendor_data_file:file create_file_perms;

Some files were not shown because too many files have changed in this diff Show More