From 19029882f4319d76402f3862f6f1cfa32e2de46c Mon Sep 17 00:00:00 2001 From: SaschaNes Date: Sat, 9 Aug 2025 20:34:45 +0200 Subject: [PATCH] Revert "some fixups" This reverts commit 96c742fbea2eaf4b8f15e6c1ef9f638155f6bd57. --- BoardConfigCommon.mk | 6 +- audio/audio_policy_configuration.xml | 453 ++++++++++++++++++ audio/audio_policy_volumes.xml | 431 ++++++++--------- audio/default_volume_tables.xml | 1 - common.mk | 58 +-- .../FrameworksResCommon/res/values/config.xml | 3 +- 6 files changed, 671 insertions(+), 281 deletions(-) create mode 100644 audio/audio_policy_configuration.xml diff --git a/BoardConfigCommon.mk b/BoardConfigCommon.mk index fced5e7..5c9a67e 100644 --- a/BoardConfigCommon.mk +++ b/BoardConfigCommon.mk @@ -31,9 +31,9 @@ AUDIO_FEATURE_ENABLED_SVA_MULTI_STAGE := true BOARD_SUPPORTS_OPENSOURCE_STHAL := true BOARD_SUPPORTS_SOUND_TRIGGER := true BOARD_USES_ALSA_AUDIO := true -TARGET_PROVIDES_AUDIO_HAL := false -TARGET_PROVIDES_LIBAGM := false -TARGET_PROVIDES_LIBAR_PAL := false +TARGET_PROVIDES_AUDIO_HAL := true +TARGET_PROVIDES_LIBAGM := true +TARGET_PROVIDES_LIBAR_PAL := true TARGET_USES_QCOM_MM_AUDIO := true # Boot diff --git a/audio/audio_policy_configuration.xml b/audio/audio_policy_configuration.xml new file mode 100644 index 0000000..485c601 --- /dev/null +++ b/audio/audio_policy_configuration.xml @@ -0,0 +1,453 @@ + + + + + + + + + + + + + + + + + + + Earpiece + Speaker + Telephony Tx + Built-In Mic + Built-In Back Mic + FM Tuner + Telephony Rx + Echo Reference + + Speaker + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/audio/audio_policy_volumes.xml b/audio/audio_policy_volumes.xml index d19522b..32912b8 100644 --- a/audio/audio_policy_volumes.xml +++ b/audio/audio_policy_volumes.xml @@ -1,226 +1,205 @@ - - - - - - - 0,-4200 - 33,-2800 - 66,-1400 - 100,0 - - - 0,-2400 - 33,-1600 - 66,-800 - 100,0 - - - 0,-2400 - 33,-1600 - 66,-800 - 100,0 - - - - - 1,-3000 - 33,-2600 - 66,-2200 - 100,-1800 - - - - - - - - 1,-2970 - 33,-2010 - 66,-1020 - 100,0 - - - - - - - - - - - - 0,-2970 - 33,-2010 - 66,-1020 - 100,0 - - - - - - - 1,-2970 - 33,-2010 - 66,-1020 - 100,0 - - - - - - 0,-4200 - 33,-2800 - 66,-1400 - 100,0 - - - 0,-2400 - 33,-1600 - 66,-800 - 100,0 - - - 0,-4200 - 33,-2800 - 66,-1400 - 100,0 - - - - - 1,-3000 - 33,-2600 - 66,-2200 - 100,-1800 - - - - - - - 1,-3000 - 33,-2600 - 66,-2200 - 100,-1800 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + 0,-4200 + 33,-2800 + 66,-1400 + 100,0 + + + 0,-2400 + 33,-1600 + 66,-800 + 100,0 + + + 0,-2400 + 33,-1600 + 66,-800 + 100,0 + + + + + 1,-3000 + 33,-2600 + 66,-2200 + 100,-1800 + + + + + + + + 1,-2970 + 33,-2010 + 66,-1020 + 100,0 + + + + + + + + + + + + 0,-2970 + 33,-2010 + 66,-1020 + 100,0 + + + + + + + 1,-2970 + 33,-2010 + 66,-1020 + 100,0 + + + + + + 0,-4200 + 33,-2800 + 66,-1400 + 100,0 + + + 0,-2400 + 33,-1600 + 66,-800 + 100,0 + + + 0,-4200 + 33,-2800 + 66,-1400 + 100,0 + + + + + 1,-3000 + 33,-2600 + 66,-2200 + 100,-1800 + + + + + + + 1,-3000 + 33,-2600 + 66,-2200 + 100,-1800 + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/audio/default_volume_tables.xml b/audio/default_volume_tables.xml index 1a65328..207be41 100644 --- a/audio/default_volume_tables.xml +++ b/audio/default_volume_tables.xml @@ -127,4 +127,3 @@ 100,0 - diff --git a/common.mk b/common.mk index 7ec2e17..940284c 100644 --- a/common.mk +++ b/common.mk @@ -34,15 +34,10 @@ PRODUCT_PACKAGES += \ audio.bluetooth.default \ audio.r_submix.default \ audio.usbv2.default \ - audioadsprpcd \ - a2dpsink \ - libagm \ - libqtigefar \ libagmmixer \ libagm_compress_plugin \ libagm_mixer_plugin \ libagm_pcm_plugin \ - libar-pal \ libats \ libaudiochargerlistener \ libbatterylistener \ @@ -55,26 +50,20 @@ PRODUCT_PACKAGES += \ libqcomvoiceprocessing \ libvolumelistener \ sound_trigger.primary.pineapple \ - vendor.qti.hardware.pal@1.0-impl \ vendor.qti.audio-adsprpc-service.rc \ vendor.qti.hardware.AGMIPC@1.0-impl AUDIO_HAL_DIR := hardware/qcom-caf/sm8650/audio/primary-hal -AUDIO_PAL_DIR := hardware/qcom-caf/sm8650/audio/pal/ -CONFIG_HAL_SRC_DIR := hardware/qcom-caf/sm8650/audio/primary-hal/configs/pineapple -CONFIG_PAL_SRC_DIR := hardware/qcom-caf/sm8650/audio/pal/configs/pineapple +AUDIO_PAL_DIR := hardware/qcom-caf/sm8650/audio/pal + + #$(AUDIO_HAL_DIR)/configs/pineapple/audio_effects.conf:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_pineapple/audio_effects.conf \ + #$(AUDIO_HAL_DIR)/configs/pineapple/audio_effects.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_pineapple/audio_effects.xml \ PRODUCT_COPY_FILES += \ - $(AUDIO_HAL_DIR)/configs/common/audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_configuration.xml \ - $(CONFIG_HAL_SRC_DIR)/audio_effects.conf:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_pineapple/audio_effects.conf \ - $(CONFIG_HAL_SRC_DIR)/audio_effects.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_pineapple/audio_effects.xml \ - $(CONFIG_PAL_SRC_DIR)/card-defs.xml:$(TARGET_COPY_OUT_VENDOR)/etc/card-defs.xml \ - $(CONFIG_HAL_SRC_DIR)/microphone_characteristics.xml:$(TARGET_COPY_OUT_VENDOR)/etc/microphone_characteristics.xml \ - $(CONFIG_PAL_SRC_DIR)/Hapticsconfig.xml:$(TARGET_COPY_OUT_VENDOR)/etc/Hapticsconfig.xml \ - $(CONFIG_PAL_SRC_DIR)/usecaseKvManager.xml:$(TARGET_COPY_OUT_VENDOR)/etc/usecaseKvManager.xml - -PRODUCT_COPY_FILES += \ - $(LOCAL_PATH)/audio/audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/audio_policy_configuration.xml \ + $(AUDIO_HAL_DIR)/configs/pineapple/microphone_characteristics.xml:$(TARGET_COPY_OUT_VENDOR)/etc/microphone_characteristics.xml \ + $(AUDIO_PAL_DIR)/configs/pineapple/card-defs.xml:$(TARGET_COPY_OUT_VENDOR)/etc/card-defs.xml \ + $(AUDIO_PAL_DIR)/configs/pineapple/Hapticsconfig.xml:$(TARGET_COPY_OUT_VENDOR)/etc/Hapticsconfig.xml \ + $(LOCAL_PATH)/audio/audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_pineapple/audio_policy_configuration.xml \ $(LOCAL_PATH)/audio/usbv2_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/usbv2_audio_policy_configuration.xml PRODUCT_COPY_FILES += \ @@ -105,7 +94,6 @@ PRODUCT_SET_DEBUGFS_RESTRICTIONS := true # Display PRODUCT_PACKAGES += \ - AdvancedDisplay \ android.hardware.graphics.mapper@4.0-impl-qti-display \ init.qti.display_boot.rc \ init.qti.display_boot.sh \ @@ -224,16 +212,6 @@ PRODUCT_PACKAGES += \ com.android.nfc_extras \ Tag -PRODUCT_COPY_FILES += \ - frameworks/native/data/etc/android.hardware.nfc.ese.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.ese.xml \ - frameworks/native/data/etc/android.hardware.nfc.hce.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hce.xml \ - frameworks/native/data/etc/android.hardware.nfc.hcef.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hcef.xml \ - frameworks/native/data/etc/android.hardware.nfc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.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/com.android.nfc_extras.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/com.android.nfc_extras.xml \ - frameworks/native/data/etc/com.nxp.mifare.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/com.nxp.mifare.xml - # Overlays PRODUCT_ENFORCE_RRO_TARGETS := * @@ -249,13 +227,6 @@ PRODUCT_PACKAGES += \ PRODUCT_USE_DYNAMIC_PARTITIONS := true -# Power -PRODUCT_PACKAGES += \ - android.hardware.power-service-qti - -PRODUCT_COPY_FILES += \ - vendor/qcom/opensource/power/config/pineapple/powerhint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/powerhint.xml - # QTI PRODUCT_COPY_FILES += \ $(LOCAL_PATH)/configs/permissions/privapp-permissions-qti.xml:$(TARGET_COPY_OUT_SYSTEM)/etc/permissions/privapp-permissions-qti.xml \ @@ -296,7 +267,6 @@ PRODUCT_COPY_FILES += \ PRODUCT_SOONG_NAMESPACES += \ $(LOCAL_PATH) \ hardware/samsung \ - hardware/qcom-caf/sm8650/audio \ kernel/samsung/sm8650 \ kernel/samsung/sm8650-modules @@ -312,10 +282,7 @@ PRODUCT_BOOT_JARS += \ telephony-ext PRODUCT_COPY_FILES += \ - 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.euicc.xml:$(TARGET_COPY_OUT_PRODUCT)/etc/permissions/android.hardware.telephony.euicc.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.telephony.gsm.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/vendor.samsung.hardware.telephony.gsm.xml \ frameworks/native/data/etc/android.hardware.telephony.mbms.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.telephony.mbms.xml \ frameworks/native/data/etc/android.software.sip.voip.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.sip.voip.xml @@ -341,13 +308,6 @@ PRODUCT_PACKAGES += \ PRODUCT_COPY_FILES += \ frameworks/native/data/etc/android.software.verified_boot.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.verified_boot.xml -# Vibrator -PRODUCT_PACKAGES += \ - vendor.qti.hardware.vibrator.service - -PRODUCT_COPY_FILES += \ - vendor/qcom/opensource/vibrator/excluded-input-devices.xml:$(TARGET_COPY_OUT_VENDOR)/etc/excluded-input-devices.xml - # VNDK PRODUCT_PACKAGES += \ libcrypto-v33 diff --git a/overlay/FrameworksResCommon/res/values/config.xml b/overlay/FrameworksResCommon/res/values/config.xml index 6c86d3f..61931a8 100644 --- a/overlay/FrameworksResCommon/res/values/config.xml +++ b/overlay/FrameworksResCommon/res/values/config.xml @@ -39,8 +39,7 @@ the framework from using higher refresh rates, even if display modes with higher refresh rates are available from hardware composer. Only has an effect if the value is non-zero. --> - 240 - 120 + 120 true