diff options
author | Xin Li <delphij@google.com> | 2020-08-29 01:26:05 -0700 |
---|---|---|
committer | Xin Li <delphij@google.com> | 2020-08-29 01:26:05 -0700 |
commit | 1a1014488b39456d4cf414076e12bb6cfb77cb45 (patch) | |
tree | 291a5743878c0df5edfb4edd5b50c7a2e6c119e3 | |
parent | 44766b66e1c29dc4ed0a7ebe8bce349b6ec7ccfb (diff) | |
parent | b87b2a1fc9e841cc8b8f65d586abd50d3faad52e (diff) | |
download | bonito-temp_sam_168057903.tar.gz |
Merge Android R (rvc-dev-plus-aosp-without-vendor@6692709)temp_sam_168057903
Bug: 166295507
Merged-In: I62d8804c8b70e4d8ec1dd12e4e10952fa069bfaf
Change-Id: I85283f312c12ada3aff38b68cab65e6c8bd564ea
119 files changed, 2152 insertions, 1933 deletions
diff --git a/BoardConfig-common.mk b/BoardConfig-common.mk index cb4548dc..f2bad0e4 100644 --- a/BoardConfig-common.mk +++ b/BoardConfig-common.mk @@ -152,6 +152,12 @@ OVERRIDE_RS_DRIVER := libRSDriver_adreno.so # Sensors USE_SENSOR_MULTI_HAL := true TARGET_SUPPORT_DIRECT_REPORT := true +# Enable sensor Version V_2 +USE_SENSOR_HAL_VER := 2.0 + +# CHRE +CHRE_DAEMON_ENABLED := true +CHRE_DAEMON_LOAD_INTO_SENSORSPD := true # wlan BOARD_WLAN_DEVICE := qcwcn @@ -163,6 +169,9 @@ BOARD_WPA_SUPPLICANT_PRIVATE_LIB := lib_driver_cmd_$(BOARD_WLAN_DEVICE) BOARD_HOSTAPD_PRIVATE_LIB := lib_driver_cmd_$(BOARD_WLAN_DEVICE) WIFI_HIDL_FEATURE_AWARE := true WIFI_HIDL_FEATURE_DUAL_INTERFACE:= true +WIFI_FEATURE_WIFI_EXT_HAL := true +WIFI_FEATURE_IMU_DETECTION := false +WIFI_HIDL_UNIFIED_SUPPLICANT_SERVICE_RC_ENTRY := true # Audio BOARD_USES_ALSA_AUDIO := true diff --git a/CleanSpec.mk b/CleanSpec.mk index 6d71bc6f..09d682fa 100644 --- a/CleanSpec.mk +++ b/CleanSpec.mk @@ -100,7 +100,7 @@ $(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/etc/init/android.hardware.gr $(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/lib64/hw/android.hardware.graphics.composer@2.1-impl.so) # Remove StrongBox RC -$(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/etc/init/android.hardware.keymaster@4.0-service.citadel.rc) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/etc/init/android.hardware.keymaster@4.1-service.citadel.rc) # Migrate to versioned VNDK directory $(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/lib/vndk-sp) @@ -177,3 +177,25 @@ $(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/etc/vintf/manifest/android.h # Remove obsolete android.hardware.boot@1.0-impl-wrapper.recovery.so $(call add-clean-step, rm -rf $(PRODUCT_OUT)/recovery/root/system/lib64/hw/android.hardware.boot@1.0-impl-wrapper.recovery.so) + +# Vibrator HAL 1.2 renamed from 'bonito' to 'drv2624' +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/etc/init/android.hardware.vibrator@1.2-service.bonito.rc) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/bin/hw/android.hardware.vibrator@1.2-service.bonito) + +# Vibrator HAL upgraded from 1-2 to 1-3 +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/etc/init/android.hardware.vibrator@1.2-service.drv2624.rc) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/bin/hw/android.hardware.vibrator@1.2-service.drv2624) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/etc/vintf/manifest/android.hardware.vibrator@1.2-service.drv2624.xml) + +# Move android.hidl.base@1.0.so to system_ext +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/lib/android.hidl.base@1.0.so) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/lib64/android.hidl.base@1.0.so) + +# Removing GSI keys from the ramdisk. +# Those keys will be embedded into VTS instead, to verify the GSI image in used. +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/recovery/root/first_stage_ramdisk/avb/q-gsi.avbpubkey) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/recovery/root/first_stage_ramdisk/avb/r-gsi.avbpubkey) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/recovery/root/first_stage_ramdisk/avb/s-gsi.avbpubkey) + +# Use stable aidl power HAL +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/etc/init/android.hardware.power@1.3-service.pixel-libperfmgr.rc) diff --git a/WCNSS_qcom_cfg.ini b/WCNSS_qcom_cfg.ini index c4335484..3618370c 100644 --- a/WCNSS_qcom_cfg.ini +++ b/WCNSS_qcom_cfg.ini @@ -690,10 +690,6 @@ oce_enable_rssi_assoc_reject=0 # Enable/Disable rtt sta mac randomization enable_rtt_mac_randomization=1 -oce_sta_enable=0 -oce_sap_enable=0 -oce_enable_rssi_assoc_reject=0 - #Enable/Disable Secondary Retry Rate feature subset gEnableSecondaryRate=0x17 @@ -704,6 +700,9 @@ gInterfaceChangeWait=1000 #Timer value is in seconds gAutoBmpsTimerValue=90 +#Enable/Disable 802.11ai FILS support +g_is_fils_enabled=0 + END # Note: Configuration parser would not read anything past the END marker diff --git a/audio_platform_info_intcodec_b4.xml b/audio_platform_info_intcodec_b4.xml index 8750bbc5..fb71145d 100644 --- a/audio_platform_info_intcodec_b4.xml +++ b/audio_platform_info_intcodec_b4.xml @@ -72,6 +72,7 @@ <device name="SND_DEVICE_IN_CAMCORDER_SELFIE_PORTRAIT" acdb_id="61"/> <device name="SND_DEVICE_OUT_VOICE_HEARING_AID" acdb_id="10"/> <device name="SND_DEVICE_IN_VOICE_HEARING_AID" acdb_id="19"/> + <device name="SND_DEVICE_IN_VOICE_REC_DMIC_STEREO" acdb_id="144"/> <!-- TTY --> <device name="SND_DEVICE_OUT_VOICE_TTY_HCO_HANDSET" acdb_id="14"/> @@ -79,6 +80,15 @@ <device name="SND_DEVICE_IN_VOICE_TTY_VCO_HANDSET_MIC" acdb_id="19"/> <device name="SND_DEVICE_IN_VOICE_TTY_VCO_SPEAKER_MIC" acdb_id="19"/> </acdb_ids> + + <audio_input_source_delay> + <audio_source_delay name="AUDIO_SOURCE_CAMCORDER" delay="20"/> + </audio_input_source_delay> + + <audio_output_usecase_delay> + <audio_usecase_delay name="USECASE_AUDIO_PLAYBACK_DEEP_BUFFER" delay="20"/> + </audio_output_usecase_delay> + <bit_width_configs> <device name="SND_DEVICE_OUT_SPEAKER" bit_width="24"/> </bit_width_configs> @@ -114,7 +124,7 @@ <usecase name="USECASE_AUDIO_HFP_SCO_WB" type="in" id="12" /> </pcm_ids> <config_params> - <param key="input_mic_max_count" value="3"/> + <param key="input_mic_max_count" value="2"/> <param key="snd_card_name" value="sdm670-intcodec-b4-snd-card"/> <param key="operator_info" value="tmus;310260"/> <param key="operator_info" value="tmus;310490"/> @@ -246,164 +256,90 @@ 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" /> + sensitivity="-37.0" max_spl="132.5" min_spl="28.5" orientation="0.0 -1.0 0.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_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_CAMCORDER_LANDSCAPE"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED 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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/> </snd_dev> <snd_dev in_snd_device="SND_DEVICE_IN_CAMCORDER_INVERT_LANDSCAPE"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED 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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/> </snd_dev> <snd_dev in_snd_device="SND_DEVICE_IN_CAMCORDER_PORTRAIT"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED 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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/> </snd_dev> <snd_dev in_snd_device="SND_DEVICE_IN_CAMCORDER_SELFIE_LANDSCAPE"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED 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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/> </snd_dev> <snd_dev in_snd_device="SND_DEVICE_IN_CAMCORDER_SELFIE_INVERT_LANDSCAPE"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED 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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/> </snd_dev> <snd_dev in_snd_device="SND_DEVICE_IN_CAMCORDER_SELFIE_PORTRAIT"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED 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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/> </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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_DIRECT"/> </snd_dev> - <snd_dev in_snd_device="SND_DEVICE_IN_HANDSET_DMIC_NS"> + <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"/> - <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"> + <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"/> - <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"> + <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"/> - <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"> + <snd_dev in_snd_device="SND_DEVICE_IN_VOICE_REC_DMIC_STEREO"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + 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_PROCESSED"/> - <mic_info mic_device_id="builtin_mic_3" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_DIRECT"/> </snd_dev> - <snd_dev in_snd_device="SND_DEVICE_IN_SPEAKER_DMIC_NS"> + <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"/> + 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_PROCESSED"/> - <mic_info mic_device_id="builtin_mic_3" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> </snd_dev> - <snd_dev in_snd_device="SND_DEVICE_IN_SPEAKER_MIC"> + <snd_dev in_snd_device="SND_DEVICE_IN_THREE_MIC"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/> <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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED 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" @@ -419,23 +355,7 @@ <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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_DIRECT AUDIO_MICROPHONE_CHANNEL_MAPPING_DIRECT"/> </snd_dev> </input_snd_device_mic_mapping> </input_snd_device> diff --git a/audio_platform_info_intcodec_b4dev.xml b/audio_platform_info_intcodec_b4dev.xml index 00592a86..614eeab3 100644 --- a/audio_platform_info_intcodec_b4dev.xml +++ b/audio_platform_info_intcodec_b4dev.xml @@ -48,6 +48,15 @@ <device name="SND_DEVICE_OUT_VOICE_TTY_HCO_SPEAKER" acdb_id="14"/> <device name="SND_DEVICE_IN_VOICE_TTY_VCO_SPEAKER_MIC" acdb_id="19"/> </acdb_ids> + + <audio_input_source_delay> + <audio_source_delay name="AUDIO_SOURCE_CAMCORDER" delay="20"/> + </audio_input_source_delay> + + <audio_output_usecase_delay> + <audio_usecase_delay name="USECASE_AUDIO_PLAYBACK_DEEP_BUFFER" delay="20"/> + </audio_output_usecase_delay> + <bit_width_configs> <device name="SND_DEVICE_OUT_SPEAKER" bit_width="24"/> </bit_width_configs> @@ -83,7 +92,7 @@ <usecase name="USECASE_AUDIO_HFP_SCO_WB" type="in" id="12" /> </pcm_ids> <config_params> - <param key="input_mic_max_count" value="3"/> + <param key="input_mic_max_count" value="2"/> <param key="snd_card_name" value="sdm670-intcodec-b4dev-snd-card"/> </config_params> diff --git a/audio_platform_info_intcodec_s4.xml b/audio_platform_info_intcodec_s4.xml index 6a68fd3d..695d6436 100644 --- a/audio_platform_info_intcodec_s4.xml +++ b/audio_platform_info_intcodec_s4.xml @@ -72,6 +72,7 @@ <device name="SND_DEVICE_IN_CAMCORDER_SELFIE_PORTRAIT" acdb_id="61"/> <device name="SND_DEVICE_OUT_VOICE_HEARING_AID" acdb_id="10"/> <device name="SND_DEVICE_IN_VOICE_HEARING_AID" acdb_id="19"/> + <device name="SND_DEVICE_IN_VOICE_REC_DMIC_STEREO" acdb_id="144"/> <!-- TTY --> <device name="SND_DEVICE_OUT_VOICE_TTY_HCO_HANDSET" acdb_id="14"/> @@ -79,6 +80,15 @@ <device name="SND_DEVICE_IN_VOICE_TTY_VCO_HANDSET_MIC" acdb_id="19"/> <device name="SND_DEVICE_IN_VOICE_TTY_VCO_SPEAKER_MIC" acdb_id="19"/> </acdb_ids> + + <audio_input_source_delay> + <audio_source_delay name="AUDIO_SOURCE_CAMCORDER" delay="20"/> + </audio_input_source_delay> + + <audio_output_usecase_delay> + <audio_usecase_delay name="USECASE_AUDIO_PLAYBACK_DEEP_BUFFER" delay="20"/> + </audio_output_usecase_delay> + <bit_width_configs> <device name="SND_DEVICE_OUT_SPEAKER" bit_width="24"/> </bit_width_configs> @@ -114,7 +124,7 @@ <usecase name="USECASE_AUDIO_HFP_SCO_WB" type="in" id="12" /> </pcm_ids> <config_params> - <param key="input_mic_max_count" value="3"/> + <param key="input_mic_max_count" value="2"/> <param key="snd_card_name" value="sdm670-intcodec-s4-snd-card"/> <param key="operator_info" value="tmus;310260"/> <param key="operator_info" value="tmus;310490"/> @@ -246,164 +256,89 @@ 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" /> + sensitivity="-37.0" max_spl="132.5" min_spl="28.5" orientation="0.0 -1.0 0.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_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_CAMCORDER_LANDSCAPE"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED 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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/> </snd_dev> <snd_dev in_snd_device="SND_DEVICE_IN_CAMCORDER_INVERT_LANDSCAPE"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED 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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/> </snd_dev> <snd_dev in_snd_device="SND_DEVICE_IN_CAMCORDER_PORTRAIT"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED 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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/> </snd_dev> <snd_dev in_snd_device="SND_DEVICE_IN_CAMCORDER_SELFIE_LANDSCAPE"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED 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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/> </snd_dev> <snd_dev in_snd_device="SND_DEVICE_IN_CAMCORDER_SELFIE_INVERT_LANDSCAPE"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED 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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/> </snd_dev> <snd_dev in_snd_device="SND_DEVICE_IN_CAMCORDER_SELFIE_PORTRAIT"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED 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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/> </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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_DIRECT"/> </snd_dev> - <snd_dev in_snd_device="SND_DEVICE_IN_HANDSET_DMIC_NS"> + <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"/> - <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"> + <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"/> - <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"> + <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"/> - <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"> + <snd_dev in_snd_device="SND_DEVICE_IN_VOICE_REC_DMIC_STEREO"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + 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_PROCESSED"/> - <mic_info mic_device_id="builtin_mic_3" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_DIRECT"/> </snd_dev> - <snd_dev in_snd_device="SND_DEVICE_IN_SPEAKER_DMIC_NS"> + <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"/> + 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_PROCESSED"/> - <mic_info mic_device_id="builtin_mic_3" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> </snd_dev> - <snd_dev in_snd_device="SND_DEVICE_IN_SPEAKER_MIC"> + <snd_dev in_snd_device="SND_DEVICE_IN_THREE_MIC"> <mic_info mic_device_id="builtin_mic_1" - channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED"/> <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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_PROCESSED 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" @@ -419,23 +354,7 @@ <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"/> + channel_mapping="AUDIO_MICROPHONE_CHANNEL_MAPPING_UNUSED AUDIO_MICROPHONE_CHANNEL_MAPPING_DIRECT AUDIO_MICROPHONE_CHANNEL_MAPPING_DIRECT"/> </snd_dev> </input_snd_device_mic_mapping> </input_snd_device> diff --git a/audio_platform_info_intcodec_s4dev.xml b/audio_platform_info_intcodec_s4dev.xml index dfb189d9..e84a87f1 100644 --- a/audio_platform_info_intcodec_s4dev.xml +++ b/audio_platform_info_intcodec_s4dev.xml @@ -48,6 +48,15 @@ <device name="SND_DEVICE_OUT_VOICE_TTY_HCO_SPEAKER" acdb_id="14"/> <device name="SND_DEVICE_IN_VOICE_TTY_VCO_SPEAKER_MIC" acdb_id="19"/> </acdb_ids> + + <audio_input_source_delay> + <audio_source_delay name="AUDIO_SOURCE_CAMCORDER" delay="20"/> + </audio_input_source_delay> + + <audio_output_usecase_delay> + <audio_usecase_delay name="USECASE_AUDIO_PLAYBACK_DEEP_BUFFER" delay="20"/> + </audio_output_usecase_delay> + <bit_width_configs> <device name="SND_DEVICE_OUT_SPEAKER" bit_width="24"/> </bit_width_configs> @@ -83,7 +92,7 @@ <usecase name="USECASE_AUDIO_HFP_SCO_WB" type="in" id="12" /> </pcm_ids> <config_params> - <param key="input_mic_max_count" value="3"/> + <param key="input_mic_max_count" value="2"/> <param key="snd_card_name" value="sdm670-intcodec-s4dev-snd-card"/> </config_params> diff --git a/audio_policy_configuration.xml b/audio_policy_configuration.xml index be772388..f65dfb1b 100644 --- a/audio_policy_configuration.xml +++ b/audio_policy_configuration.xml @@ -82,12 +82,12 @@ <mixPort name="primary input" role="sink" maxActiveCount="0"> <profile name="" format="AUDIO_FORMAT_PCM_8_24_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"/> + channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO,AUDIO_CHANNEL_IN_FRONT_BACK,AUDIO_CHANNEL_INDEX_MASK_2"/> </mixPort> <mixPort name="fast input" role="sink" flags="AUDIO_INPUT_FLAG_FAST"> <profile name="" format="AUDIO_FORMAT_PCM_8_24_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"/> + channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO,AUDIO_CHANNEL_IN_FRONT_BACK,AUDIO_CHANNEL_INDEX_MASK_2"/> </mixPort> <mixPort name="hifi_input" role="sink" /> <mixPort name="voice_rx" role="sink"> @@ -97,7 +97,7 @@ <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"/> + channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO,AUDIO_CHANNEL_IN_FRONT_BACK,AUDIO_CHANNEL_INDEX_MASK_2"/> </mixPort> <mixPort name="voip_tx" role="sink" flags="AUDIO_INPUT_FLAG_VOIP_TX"> diff --git a/audio_policy_volumes.xml b/audio_policy_volumes.xml index 635f7214..f1193174 100644 --- a/audio_policy_volumes.xml +++ b/audio_policy_volumes.xml @@ -44,7 +44,7 @@ volume index from 0 to 100. <volume stream="AUDIO_STREAM_VOICE_CALL" deviceCategory="DEVICE_CATEGORY_EXT_MEDIA" ref="DEFAULT_MEDIA_VOLUME_CURVE"/> <volume stream="AUDIO_STREAM_VOICE_CALL" deviceCategory="DEVICE_CATEGORY_HEARING_AID" - ref="DEFAULT_HEARING_AID_VOLUME_CURVE"/> + ref="DEFAULT_NON_MUTABLE_HEARING_AID_VOLUME_CURVE"/> <volume stream="AUDIO_STREAM_SYSTEM" deviceCategory="DEVICE_CATEGORY_HEADSET"> <point>1,-3000</point> <point>33,-2600</point> diff --git a/bonito/overlay/frameworks/base/core/res/res/values/config.xml b/bonito/overlay/frameworks/base/core/res/res/values/config.xml index 0c28a5a6..bba32867 100755 --- a/bonito/overlay/frameworks/base/core/res/res/values/config.xml +++ b/bonito/overlay/frameworks/base/core/res/res/values/config.xml @@ -134,22 +134,21 @@ backlight values --> <bool name="config_displayBrightnessBucketsInDoze">true</bool> - <!-- Default screen brightness setting. - Must be in the range specified by minimum and maximum. --> - <integer name="config_screenBrightnessSettingDefault">98</integer> - - <!-- Default screen brightness for VR setting. Default value: 0x1F => 127. --> - <integer name="config_screenBrightnessForVrSettingDefault">127</integer> + <!-- 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> - <integer name="config_screenBrightnessForVrSettingMinimum">127</integer> + <!-- Maximum screen brightness allowed by the power manager. + The user is forbidden from setting the brightness above this level. + This value is a fraction between 3.5% and 100%. --> + <item name="config_screenBrightnessSettingMaximumFloat" format="float" type="dimen">1.0</item> - <!-- Minimum screen brightness setting allowed by the power manager. - The user is forbidden from setting the brightness below this level. --> - <integer name="config_screenBrightnessSettingMinimum">1</integer> - - <!-- Maximum screen brightness setting allowed by the power manager. - The user is forbidden from setting the brightness above this level. --> - <integer name="config_screenBrightnessSettingMaximum">255</integer> + <!-- Default screen brightness setting. + Must be in the range specified by minimum and maximum. + This value is a fraction between 3.5% and 100%. + Equivalent to 98/255 (default for this device) --> + <item name="config_screenBrightnessSettingDefaultFloat" format="float" type="dimen">0.38188976378</item> <!-- An array describing the screen's backlight values corresponding to the brightness values in the config_screenBrightnessNits array. diff --git a/bonito/overlay/frameworks/base/core/res/res/xml/power_profile.xml b/bonito/overlay/frameworks/base/core/res/res/xml/power_profile.xml index 7c078cd6..6a3a0be3 100644 --- a/bonito/overlay/frameworks/base/core/res/res/xml/power_profile.xml +++ b/bonito/overlay/frameworks/base/core/res/res/xml/power_profile.xml @@ -67,36 +67,37 @@ <value>1747200</value> <!-- 1747 MHz CPU speed --> <value>1843200</value> <!-- 1843 MHz CPU speed --> <value>1996800</value> <!-- 1996 MHz CPU speed --> - <value>2016000</value> <!-- 2016 MHz CPU speed --> </array> <!-- Additional power used by a CPU core from cluster 0 when running at different speeds, excluding cluster and active cost --> + <!-- 6 cores + 6 cpueater & 100 % usage --> <array name="cpu.core_power.cluster0"> - <value>91.48</value> <!-- 300 MHz CPU speed --> - <value>109.3</value> <!-- 576 MHz CPU speed --> - <value>121.12</value> <!-- 748 MHz CPU speed --> - <value>139.74</value> <!-- 998 MHz CPU speed --> - <value>150.07</value> <!-- 1209 MHz CPU speed --> - <value>170.91</value> <!-- 1324 MHz CPU speed --> - <value>190.12</value> <!-- 1516 MHz CPU speed --> - <value>214.74</value> <!-- 1708 MHz CPU speed --> + <value>42.52</value> <!-- 300 MHz CPU speed --> + <value>62.24</value> <!-- 576 MHz CPU speed --> + <value>71.48</value> <!-- 748 MHz CPU speed --> + <value>95.1</value> <!-- 998 MHz CPU speed --> + <value>110.86</value> <!-- 1209 MHz CPU speed --> + <value>125.09</value> <!-- 1324 MHz CPU speed --> + <value>145.31</value> <!-- 1516 MHz CPU speed --> + <value>181.24</value> <!-- 1708 MHz CPU speed --> </array> <!-- Additional power used by a CPU core from cluster 1 when running at different speeds, excluding cluster and active cost --> + <!-- 2 cores + 6 cpueater & 100 % usage --> <array name="cpu.core_power.cluster1"> - <value>48.12</value> <!-- 300 MHz CPU speed --> - <value>55.12</value> <!-- 652 MHz CPU speed --> - <value>58</value> <!-- 825 MHz CPU speed --> - <value>63.35</value> <!-- 979 MHz CPU speed --> - <value>69.06</value> <!-- 1132 MHz CPU speed --> - <value>77.77</value> <!-- 1363 MHz CPU speed --> - <value>86.15</value> <!-- 1536 MHz CPU speed --> - <value>97.41</value> <!-- 1747 MHz CPU speed --> - <value>129.14</value> <!-- 1843 MHz CPU speed --> - <value>139.61</value> <!-- 1996 MHz CPU speed --> - <value>153.09</value> <!-- 2016 MHz CPU speed --> + <value>31.4</value> <!-- 300 MHz CPU speed --> + <value>38.5</value> <!-- 652 MHz CPU speed --> + <value>41.97</value> <!-- 825 MHz CPU speed --> + <value>46.25</value> <!-- 979 MHz CPU speed --> + <value>51.09</value> <!-- 1132 MHz CPU speed --> + <value>63.9</value> <!-- 1363 MHz CPU speed --> + <value>74.5</value> <!-- 1536 MHz CPU speed --> + <value>86.23</value> <!-- 1747 MHz CPU speed --> + <value>117.69</value> <!-- 1843 MHz CPU speed --> + <value>135.31</value> <!-- 1996 MHz CPU speed --> + </array> <!-- Additional power used when screen is ambient mode --> <item name="ambient.on">24</item> diff --git a/bonito/overlay_packages/SettingsOverlayG020A/Android.bp b/bonito/overlay_packages/SettingsOverlayG020A/Android.bp new file mode 100644 index 00000000..0905e767 --- /dev/null +++ b/bonito/overlay_packages/SettingsOverlayG020A/Android.bp @@ -0,0 +1,4 @@ +runtime_resource_overlay { + name: "SettingsOverlayG020A", + product_specific: true, +}
\ No newline at end of file diff --git a/bonito/overlay_packages/SettingsOverlayG020A/AndroidManifest.xml b/bonito/overlay_packages/SettingsOverlayG020A/AndroidManifest.xml new file mode 100644 index 00000000..9a258652 --- /dev/null +++ b/bonito/overlay_packages/SettingsOverlayG020A/AndroidManifest.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.android.settings.overlay.g020a"> + <application android:hasCode="false" /> + <overlay android:targetPackage="com.android.settings" + android:requiredSystemPropertyName="ro.boot.hardware.sku" + android:requiredSystemPropertyValue="G020A" + android:isStatic="true" /> +</manifest>
\ No newline at end of file diff --git a/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020a.png b/bonito/overlay_packages/SettingsOverlayG020A/res/drawable/regulatory_info.png Binary files differindex 0d5a1b56..0d5a1b56 100644 --- a/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020a.png +++ b/bonito/overlay_packages/SettingsOverlayG020A/res/drawable/regulatory_info.png diff --git a/bonito/overlay_packages/SettingsOverlayG020B/Android.bp b/bonito/overlay_packages/SettingsOverlayG020B/Android.bp new file mode 100644 index 00000000..139ee739 --- /dev/null +++ b/bonito/overlay_packages/SettingsOverlayG020B/Android.bp @@ -0,0 +1,4 @@ +runtime_resource_overlay { + name: "SettingsOverlayG020B", + product_specific: true, +}
\ No newline at end of file diff --git a/bonito/overlay_packages/SettingsOverlayG020B/AndroidManifest.xml b/bonito/overlay_packages/SettingsOverlayG020B/AndroidManifest.xml new file mode 100644 index 00000000..ca675df6 --- /dev/null +++ b/bonito/overlay_packages/SettingsOverlayG020B/AndroidManifest.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.android.settings.overlay.g020b"> + <application android:hasCode="false" /> + <overlay android:targetPackage="com.android.settings" + android:requiredSystemPropertyName="ro.boot.hardware.sku" + android:requiredSystemPropertyValue="G020B" + android:isStatic="true" /> +</manifest>
\ No newline at end of file diff --git a/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020b.png b/bonito/overlay_packages/SettingsOverlayG020B/res/drawable/regulatory_info.png Binary files differindex 7b4847a1..7b4847a1 100644 --- a/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020b.png +++ b/bonito/overlay_packages/SettingsOverlayG020B/res/drawable/regulatory_info.png diff --git a/bonito/overlay_packages/SettingsOverlayG020C/Android.bp b/bonito/overlay_packages/SettingsOverlayG020C/Android.bp new file mode 100644 index 00000000..b2b33b1c --- /dev/null +++ b/bonito/overlay_packages/SettingsOverlayG020C/Android.bp @@ -0,0 +1,4 @@ +runtime_resource_overlay { + name: "SettingsOverlayG020C", + product_specific: true, +}
\ No newline at end of file diff --git a/bonito/overlay_packages/SettingsOverlayG020C/AndroidManifest.xml b/bonito/overlay_packages/SettingsOverlayG020C/AndroidManifest.xml new file mode 100644 index 00000000..e753163f --- /dev/null +++ b/bonito/overlay_packages/SettingsOverlayG020C/AndroidManifest.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.android.settings.overlay.g020c"> + <application android:hasCode="false" /> + <overlay android:targetPackage="com.android.settings" + android:requiredSystemPropertyName="ro.boot.hardware.sku" + android:requiredSystemPropertyValue="G020C" + android:isStatic="true" /> +</manifest>
\ No newline at end of file diff --git a/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020c.png b/bonito/overlay_packages/SettingsOverlayG020C/res/drawable/regulatory_info.png Binary files differindex c3820ca7..c3820ca7 100644 --- a/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020c.png +++ b/bonito/overlay_packages/SettingsOverlayG020C/res/drawable/regulatory_info.png diff --git a/bonito/overlay_packages/SettingsOverlayG020D/Android.bp b/bonito/overlay_packages/SettingsOverlayG020D/Android.bp new file mode 100644 index 00000000..033e3aa3 --- /dev/null +++ b/bonito/overlay_packages/SettingsOverlayG020D/Android.bp @@ -0,0 +1,4 @@ +runtime_resource_overlay { + name: "SettingsOverlayG020D", + product_specific: true, +}
\ No newline at end of file diff --git a/bonito/overlay_packages/SettingsOverlayG020D/AndroidManifest.xml b/bonito/overlay_packages/SettingsOverlayG020D/AndroidManifest.xml new file mode 100644 index 00000000..055ae402 --- /dev/null +++ b/bonito/overlay_packages/SettingsOverlayG020D/AndroidManifest.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.android.settings.overlay.g020d"> + <application android:hasCode="false" /> + <overlay android:targetPackage="com.android.settings" + android:requiredSystemPropertyName="ro.boot.hardware.sku" + android:requiredSystemPropertyValue="G020D" + android:isStatic="true" /> +</manifest>
\ No newline at end of file diff --git a/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020d.png b/bonito/overlay_packages/SettingsOverlayG020D/res/drawable/regulatory_info.png Binary files differindex e9ecf8ef..e9ecf8ef 100644 --- a/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020d.png +++ b/bonito/overlay_packages/SettingsOverlayG020D/res/drawable/regulatory_info.png diff --git a/component-overrides.xml b/component-overrides.xml new file mode 100644 index 00000000..bb3419d8 --- /dev/null +++ b/component-overrides.xml @@ -0,0 +1,20 @@ +<?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=".sap.SapService" enabled="true" /> + </component-override> +</config>
\ No newline at end of file diff --git a/default-permissions.xml b/default-permissions.xml index 733b2723..1fcf7eee 100644 --- a/default-permissions.xml +++ b/default-permissions.xml @@ -79,17 +79,6 @@ </exception> <exception - package="com.google.android.apps.restore" - sha256-cert-digest="56:BE:13:2B:78:06:56:FE:24:44:CD:34:32:6E:B5:D7:AA:C9:1D:20:96:AB:F0:FE:67:3A:99:27:06:22:EC:87"> - <!-- External storage --> - <permission name="android.permission.READ_EXTERNAL_STORAGE" fixed="false"/> - <permission name="android.permission.WRITE_EXTERNAL_STORAGE" fixed="false"/> - <!-- Contacts --> - <permission name="android.permission.READ_CONTACTS" fixed="false"/> - <permission name="android.permission.WRITE_CONTACTS" fixed="false"/> - </exception> - - <exception package="com.verizon.mips.services"> <!-- Call --> <permission name="android.permission.PROCESS_OUTGOING_CALLS" fixed="false"/> diff --git a/device-bonito.mk b/device-bonito.mk index f3d69a0a..b1aaeeb1 100644 --- a/device-bonito.mk +++ b/device-bonito.mk @@ -20,6 +20,17 @@ include device/google/bonito/device-common.mk DEVICE_PACKAGE_OVERLAYS += device/google/bonito/bonito/overlay +# SKU specific RROs +PRODUCT_PACKAGES += \ + SettingsOverlayG020A \ + SettingsOverlayG020B \ + SettingsOverlayG020C \ + SettingsOverlayG020D \ + +# Setup wizard overlay packages for ActiveEdge +PRODUCT_PACKAGES += \ + PixelSetupWizardOverlayActiveEdge \ + PRODUCT_COPY_FILES += \ device/google/bonito/nfc/libnfc-nxp.bonito.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-nxp.conf \ device/google/bonito/nfc/libnfc-nxp.bonito.uicc.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-nxp-G020A.conf \ @@ -29,12 +40,14 @@ PRODUCT_COPY_FILES += \ # Vibrator HAL PRODUCT_PRODUCT_PROPERTIES +=\ + ro.vibrator.hal.config.dynamic=1 \ ro.vibrator.hal.click.duration=8 \ ro.vibrator.hal.tick.duration=5 \ ro.vibrator.hal.heavyclick.duration=12 \ ro.vibrator.hal.short.voltage=120 \ ro.vibrator.hal.long.voltage=90 \ - ro.vibrator.hal.long.frequency.shift=10 + ro.vibrator.hal.long.frequency.shift=10 \ + ro.vibrator.hal.double_click.duration=182 # DRV2624 Haptics Waveform PRODUCT_COPY_FILES += \ diff --git a/device-common.mk b/device-common.mk index 80406bd4..f16c2abd 100644 --- a/device-common.mk +++ b/device-common.mk @@ -74,15 +74,8 @@ PRODUCT_PROPERTY_OVERRIDES += aaudio.hw_burst_min_usec=2000 # Set lmkd options PRODUCT_PRODUCT_PROPERTIES += \ - ro.lmk.low=1001 \ - ro.lmk.medium=800 \ - ro.lmk.critical=0 \ - ro.lmk.critical_upgrade=false \ - ro.lmk.upgrade_pressure=100 \ - ro.lmk.downgrade_pressure=100 \ - ro.lmk.kill_heaviest_task=true \ - ro.lmk.kill_timeout_ms=100 \ - ro.lmk.use_minfree_levels=true \ + ro.config.low_ram = false \ + ro.lmk.log_stats = true \ # A2DP offload enabled for compilation AUDIO_FEATURE_ENABLED_A2DP_OFFLOAD := true diff --git a/device-sargo.mk b/device-sargo.mk index 8021f404..28de7e90 100644 --- a/device-sargo.mk +++ b/device-sargo.mk @@ -20,6 +20,21 @@ include device/google/bonito/device-common.mk DEVICE_PACKAGE_OVERLAYS += device/google/bonito/sargo/overlay +# SKU specific RROs +PRODUCT_PACKAGES += \ + SettingsOverlayG020E \ + SettingsOverlayG020E_VN \ + SettingsOverlayG020F \ + SettingsOverlayG020F_VN \ + SettingsOverlayG020G \ + SettingsOverlayG020G_VN \ + SettingsOverlayG020H \ + SettingsOverlayG020H_VN \ + +# Setup wizard overlay packages for ActiveEdge +PRODUCT_PACKAGES += \ + PixelSetupWizardOverlayActiveEdge \ + PRODUCT_COPY_FILES += \ device/google/bonito/nfc/libnfc-nxp.sargo.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-nxp.conf \ device/google/bonito/nfc/libnfc-nxp.sargo.uicc.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-nxp-G020E.conf \ @@ -31,12 +46,15 @@ PRODUCT_PRODUCT_PROPERTIES += ro.com.google.ime.height_ratio=1.2 # Vibrator HAL PRODUCT_PRODUCT_PROPERTIES +=\ + ro.vibrator.hal.config.dynamic=1 \ ro.vibrator.hal.click.duration=8 \ ro.vibrator.hal.tick.duration=5 \ ro.vibrator.hal.heavyclick.duration=12 \ ro.vibrator.hal.short.voltage=110 \ ro.vibrator.hal.long.voltage=80 \ - ro.vibrator.hal.long.frequency.shift=10 + ro.vibrator.hal.long.frequency.shift=10 \ + ro.vibrator.hal.double_click.duration=182 + # DRV2624 Haptics Waveform PRODUCT_COPY_FILES += \ @@ -19,6 +19,7 @@ TARGET_CHIPSET := sdm710 PRODUCT_SOONG_NAMESPACES += \ device/google/bonito \ hardware/google/av \ + hardware/google/camera \ hardware/google/interfaces \ hardware/google/pixel \ hardware/qcom/sdm845 \ @@ -29,6 +30,8 @@ PRODUCT_SOONG_NAMESPACES += \ PRODUCT_PROPERTY_OVERRIDES += \ keyguard.no_require_sim=true +PRODUCT_PROPERTY_OVERRIDES += ro.crypto.volume.filenames_mode=aes-256-cts + # enable cal by default on accel sensor PRODUCT_PRODUCT_PROPERTIES += \ persist.debug.sensors.accel_cal=1 @@ -40,6 +43,7 @@ PRODUCT_PRODUCT_PROPERTIES += \ PRODUCT_COPY_FILES += \ device/google/bonito/default-permissions.xml:$(TARGET_COPY_OUT_VENDOR)/etc/default-permissions/default-permissions.xml \ + device/google/bonito/component-overrides.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sysconfig/component-overrides.xml \ frameworks/native/data/etc/handheld_core_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/handheld_core_hardware.xml \ frameworks/native/data/etc/android.software.verified_boot.xml:$(TARGET_COPY_OUT_PRODUCT)/etc/permissions/android.software.verified_boot.xml @@ -54,15 +58,16 @@ PRODUCT_PROPERTY_OVERRIDES += \ PRODUCT_PACKAGES += \ messaging +ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) +PRODUCT_PACKAGES += chre_test_client +endif + LOCAL_PATH := device/google/bonito TARGET_PRODUCT_PROP := $(LOCAL_PATH)/product.prop $(call inherit-product, $(LOCAL_PATH)/utils.mk) -# Installs gsi keys into ramdisk, to boot a GSI with verified boot. -$(call inherit-product, $(SRC_TARGET_DIR)/product/gsi_keys.mk) - # Installs gsi keys into ramdisk, to boot a developer GSI with verified boot. $(call inherit-product, $(SRC_TARGET_DIR)/product/developer_gsi_keys.mk) @@ -136,6 +141,10 @@ PRODUCT_PACKAGES += \ update_engine \ update_verifier +# Resume on Reboot support +PRODUCT_PACKAGES += \ + android.hardware.rebootescrow-service.citadel + # Use Sdcardfs PRODUCT_PRODUCT_PROPERTIES += \ ro.sys.sdcardfs=1 @@ -166,7 +175,8 @@ AB_OTA_POSTINSTALL_CONFIG += \ PRODUCT_PACKAGES += \ update_engine_sideload \ sg_write_buffer \ - f2fs_io + f2fs_io \ + check_f2fs # The following modules are included in debuggable builds only. PRODUCT_PACKAGES_DEBUG += \ @@ -184,6 +194,7 @@ PRODUCT_COPY_FILES += \ 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.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.reboot_escrow.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.reboot_escrow.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.assist.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.assist.xml \ frameworks/native/data/etc/android.hardware.sensor.compass.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.compass.xml \ @@ -194,6 +205,7 @@ PRODUCT_COPY_FILES += \ 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.sensor.hifi_sensors.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.hifi_sensors.xml \ + frameworks/native/data/etc/android.hardware.context_hub.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.context_hub.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.telephony.gsm.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.telephony.gsm.xml \ frameworks/native/data/etc/android.hardware.telephony.cdma.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.telephony.cdma.xml \ @@ -215,15 +227,12 @@ PRODUCT_COPY_FILES += \ frameworks/native/data/etc/android.hardware.vulkan.level-1.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.level.xml \ frameworks/native/data/etc/android.hardware.vulkan.compute-0.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.compute.xml \ frameworks/native/data/etc/android.hardware.vulkan.version-1_1.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.version.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 \ frameworks/native/data/etc/android.hardware.telephony.carrierlock.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.telephony.carrierlock.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.strongbox_keystore.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.strongbox_keystore.xml \ frameworks/native/data/etc/android.software.ipsec_tunnels.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.ipsec_tunnels.xml \ -# power HAL -PRODUCT_PACKAGES += \ - android.hardware.power@1.3-service.pixel-libperfmgr - # powerstats HAL PRODUCT_PACKAGES += \ android.hardware.power.stats@1.0-service.pixel @@ -247,6 +256,7 @@ PRODUCT_PROPERTY_OVERRIDES += \ persist.audio.out_mmap_delay_micros=150 \ ro.config.vc_call_vol_steps=7 \ ro.config.media_vol_steps=25 \ + vendor.audio.offload.gapless.enabled=true \ # MaxxAudio effect and add rotation monitor PRODUCT_PROPERTY_OVERRIDES += \ @@ -388,10 +398,6 @@ PRODUCT_PROPERTY_OVERRIDES += \ PRODUCT_PROPERTY_OVERRIDES += \ ro.vendor.bt.bdaddr_path=/proc/device-tree/chosen/cdt/cdb2/bt_addr -# Enable Perfetto traced -PRODUCT_PRODUCT_PROPERTIES += \ - persist.traced.enable=1 - # Bluetooth WiPower PRODUCT_PROPERTY_OVERRIDES += \ ro.vendor.bluetooth.emb_wp_mode=false \ @@ -401,8 +407,8 @@ PRODUCT_PROPERTY_OVERRIDES += \ PRODUCT_PACKAGES += \ android.hardware.drm@1.0-impl \ android.hardware.drm@1.0-service \ - android.hardware.drm@1.2-service.clearkey \ - android.hardware.drm@1.2-service.widevine + android.hardware.drm@1.3-service.clearkey \ + android.hardware.drm@1.3-service.widevine # NFC and Secure Element packages PRODUCT_PACKAGES += \ @@ -448,6 +454,10 @@ PRODUCT_PACKAGES += \ PRODUCT_PROPERTY_OVERRIDES += \ debug.media.codec2=2 \ +# Disable OMX +PRODUCT_PROPERTY_OVERRIDES += \ + vendor.media.omx=0 \ + # Create input surface on the framework side PRODUCT_PROPERTY_OVERRIDES += \ debug.stagefright.c2inputsurface=-1 \ @@ -464,17 +474,21 @@ PRODUCT_PACKAGES += \ android.hardware.camera.provider@2.4-service_64 \ camera.device@3.2-impl \ camera.sdm710 \ - libgooglecamerahal \ - libgoogle_camera_hal_tests \ libqomx_core \ libmmjpeg_interface \ libmmcamera_interface \ libcameradepthcalibrator +# Google Camera HAL test libraries in debug builds +PRODUCT_PACKAGES_DEBUG += \ + libgoogle_camera_hal_proprietary_tests \ + libgoogle_camera_hal_tests.vendor + PRODUCT_PACKAGES += \ sensors.$(PRODUCT_HARDWARE) \ - android.hardware.sensors@1.0-impl \ - android.hardware.sensors@1.0-service + android.hardware.sensors@2.0-impl \ + android.hardware.sensors@2.0-service \ + android.hardware.sensors@2.0-service.rc PRODUCT_COPY_FILES += \ $(LOCAL_PATH)/sensors/hals.conf:vendor/etc/sensors/hals.conf @@ -489,8 +503,7 @@ PRODUCT_PACKAGES += \ # Context hub HAL PRODUCT_PACKAGES += \ - android.hardware.contexthub@1.0-impl.generic \ - android.hardware.contexthub@1.0-service + android.hardware.contexthub@1.1-service.generic # Boot control HAL PRODUCT_PACKAGES += \ @@ -498,14 +511,6 @@ PRODUCT_PACKAGES += \ android.hardware.boot@1.0-impl.recovery \ android.hardware.boot@1.0-service \ -# Vibrator HAL -PRODUCT_PACKAGES += \ - android.hardware.vibrator@1.2-service.bonito \ - -# Thermal HAL -PRODUCT_PACKAGES += \ - android.hardware.thermal@2.0-service.pixel - PRODUCT_COPY_FILES += \ $(LOCAL_PATH)/thermal_info_config_$(PRODUCT_HARDWARE).json:$(TARGET_COPY_OUT_VENDOR)/etc/thermal_info_config.json @@ -540,15 +545,12 @@ endif PRODUCT_PACKAGES += \ android.hardware.wifi@1.0-service \ wificond \ - libwpa_client + libwpa_client \ + WifiOverlay LIB_NL := libnl_2 PRODUCT_PACKAGES += $(LIB_NL) -# Factory OTA -PRODUCT_PACKAGES += \ - FactoryOta - # Audio effects PRODUCT_PACKAGES += \ libvolumelistener \ @@ -567,9 +569,8 @@ PRODUCT_PACKAGES += \ audio.bluetooth.default PRODUCT_PACKAGES += \ - android.hardware.audio@5.0-impl:32 \ - android.hardware.audio.effect@5.0-impl:32 \ - android.hardware.broadcastradio@1.0-impl \ + android.hardware.audio@6.0-impl:32 \ + android.hardware.audio.effect@6.0-impl:32 \ android.hardware.soundtrigger@2.2-impl \ android.hardware.bluetooth.audio@2.0-impl \ android.hardware.audio@2.0-service @@ -622,13 +623,6 @@ PRODUCT_COPY_FILES += \ $(LOCAL_PATH)/media_profiles_V1_0.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_profiles_V1_0.xml \ $(LOCAL_PATH)/media_codecs_omx.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_omx.xml -# configures both aac and xaac decoders -PRODUCT_COPY_FILES += \ - device/google/bonito/media_codecs_google_audio.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_audio.xml \ -# and ensure that the xaac decoder is built -PRODUCT_PACKAGES += \ - libstagefright_soft_xaacdec.vendor - PRODUCT_PROPERTY_OVERRIDES += \ audio.snd_card.open.retries=50 @@ -653,6 +647,13 @@ endif PRODUCT_PROPERTY_OVERRIDES += \ persist.vendor.sys.ssr.restart_level=modem,slpi,adsp +ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) +# Sensor debug flag +PRODUCT_PROPERTY_OVERRIDES += \ + persist.vendor.debug.ash.logger=0 \ + persist.vendor.debug.ash.logger.time=0 +endif + # setup dalvik vm configs $(call inherit-product, frameworks/native/build/phone-xhdpi-4096-dalvik-heap.mk) @@ -664,15 +665,19 @@ PRODUCT_COPY_FILES += \ PRODUCT_PACKAGES += \ charger_res_images -# b/36703476 -# Set default log size on userdebug/eng build to 1M ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) -PRODUCT_PROPERTY_OVERRIDES += ro.logd.size=1M +# b/36703476: Set default log size to 1M +PRODUCT_PROPERTY_OVERRIDES += \ + ro.logd.size=1M +# b/114766334: persist all logs by default rotating on 30 files of 1MiB +PRODUCT_PROPERTY_OVERRIDES += \ + logd.logpersistd=logcatd \ + logd.logpersistd.size=30 endif # Dumpstate HAL PRODUCT_PACKAGES += \ - android.hardware.dumpstate@1.0-service.bonito + android.hardware.dumpstate@1.1-service.bonito # Citadel PRODUCT_PACKAGES += \ @@ -681,7 +686,8 @@ PRODUCT_PACKAGES += \ android.hardware.authsecret@1.0-service.citadel \ android.hardware.oemlock@1.0-service.citadel \ android.hardware.weaver@1.0-service.citadel \ - android.hardware.keymaster@4.0-service.citadel \ + android.hardware.keymaster@4.1-service.citadel \ + android.hardware.identity@1.0-service.citadel \ wait_for_strongbox # Citadel debug stuff @@ -699,11 +705,6 @@ PRODUCT_PACKAGES += \ PRODUCT_PROPERTY_OVERRIDES += \ dalvik.vm.heapgrowthlimit=256m -# TODO(b/139369543): remove android.hidl.base@1.0 in next release (Q+1) -PRODUCT_PACKAGES += \ - android.hidl.base@1.0 \ - android.hidl.base@1.0.vendor - PRODUCT_PACKAGES += \ ipacm \ IPACM_cfg.xml @@ -712,6 +713,9 @@ PRODUCT_PACKAGES += \ PRODUCT_PROPERTY_OVERRIDES += \ ro.telephony.default_cdma_sub=0 +# Set network mode to Global by default and no DSDS/DSDA +PRODUCT_PROPERTY_OVERRIDES += ro.telephony.default_network=10 + # Set display color mode to Automatic by default PRODUCT_PROPERTY_OVERRIDES += \ persist.sys.sf.color_saturation=1.0 \ @@ -721,20 +725,12 @@ PRODUCT_PROPERTY_OVERRIDES += \ PRODUCT_COPY_FILES += \ device/google/bonito/permissions/com.google.hardware.camera.easel_2018.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/com.google.hardware.camera.easel_2018.xml -# ConfirmationUI HAL -PRODUCT_PACKAGES += \ - android.hardware.confirmationui@1.0-service-bonito - # Fingerprint PRODUCT_PACKAGES += \ android.hardware.biometrics.fingerprint@2.1-service.fpc PRODUCT_COPY_FILES += \ $(LOCAL_PATH)/init.fingerprint.sh:$(TARGET_COPY_OUT_VENDOR)/bin/init.fingerprint.sh \ -# Reliability reporting -PRODUCT_PACKAGES += \ - pixelstats-vendor - PRODUCT_COPY_FILES += \ frameworks/native/data/etc/android.hardware.fingerprint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.fingerprint.xml @@ -802,7 +798,8 @@ PRODUCT_COPY_FILES += \ # Keymaster configuration PRODUCT_COPY_FILES += \ - 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.device_id_attestation.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.device_id_attestation.xml \ + frameworks/native/data/etc/android.hardware.device_unique_attestation.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.device_unique_attestation.xml # Enable modem logging PRODUCT_PROPERTY_OVERRIDES += \ @@ -812,10 +809,13 @@ PRODUCT_PROPERTY_OVERRIDES += \ # Enable modem logging for debug ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) PRODUCT_PROPERTY_OVERRIDES += \ - persist.vendor.sys.modem.diag.mdlog=true \ - persist.vendor.sys.modem.diag.mdlog_br_num=5 + persist.vendor.sys.modem.diag.mdlog=true else +PRODUCT_PROPERTY_OVERRIDES += \ + persist.vendor.sys.modem.diag.mdlog=false endif +PRODUCT_PROPERTY_OVERRIDES += \ + persist.vendor.sys.modem.diag.mdlog_br_num=5 # Enable tcpdump_logger on userdebug and eng ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) @@ -876,4 +876,21 @@ PRODUCT_PRODUCT_PROPERTIES += \ # Increment the SVN for any official public releases PRODUCT_PROPERTY_OVERRIDES += \ - ro.vendor.build.svn=26 + ro.vendor.build.svn=29 + +# Vendor verbose logging default property +ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) +PRODUCT_PROPERTY_OVERRIDES += \ + persist.vendor.verbose_logging_enabled=true +else +PRODUCT_PROPERTY_OVERRIDES += \ + persist.vendor.verbose_logging_enabled=false +endif + +include hardware/google/pixel/vibrator/drv2624/device.mk +include hardware/google/pixel/pixelstats/device.mk +include hardware/google/pixel/mm/device_legacy.mk +include hardware/google/pixel/thermal/device.mk + +# power HAL +-include hardware/google/pixel/power-libperfmgr/aidl/device.mk diff --git a/device_framework_matrix.xml b/device_framework_matrix.xml index 036a645a..5d143a1f 100644 --- a/device_framework_matrix.xml +++ b/device_framework_matrix.xml @@ -55,7 +55,7 @@ </hal> <hal format="hidl" optional="true"> <name>vendor.google.radioext</name> - <version>1.1</version> + <version>1.2</version> <interface> <name>IRadioExt</name> <instance>default</instance> @@ -172,7 +172,7 @@ <hal format="hidl" optional="true"> <name>vendor.google.wifi_ext</name> <transport>hwbinder</transport> - <version>1.0</version> + <version>1.1</version> <interface> <name>IWifiExt</name> <instance>default</instance> diff --git a/dumpstate/Android.mk b/dumpstate/Android.mk index 09814771..76c889b3 100644 --- a/dumpstate/Android.mk +++ b/dumpstate/Android.mk @@ -16,8 +16,8 @@ LOCAL_PATH:= $(call my-dir) include $(CLEAR_VARS) -LOCAL_MODULE := android.hardware.dumpstate@1.0-service.bonito -LOCAL_INIT_RC := android.hardware.dumpstate@1.0-service.bonito.rc +LOCAL_MODULE := android.hardware.dumpstate@1.1-service.bonito +LOCAL_INIT_RC := android.hardware.dumpstate@1.1-service.bonito.rc LOCAL_MODULE_RELATIVE_PATH := hw LOCAL_SRC_FILES := \ @@ -26,12 +26,11 @@ LOCAL_SRC_FILES := \ LOCAL_SHARED_LIBRARIES := \ android.hardware.dumpstate@1.0 \ + android.hardware.dumpstate@1.1 \ libbase \ libcutils \ libdumpstateutil \ libhidlbase \ - libhidltransport \ - libhwbinder \ liblog \ libutils diff --git a/dumpstate/DumpstateDevice.cpp b/dumpstate/DumpstateDevice.cpp index 1e901378..5dff0e7e 100755 --- a/dumpstate/DumpstateDevice.cpp +++ b/dumpstate/DumpstateDevice.cpp @@ -21,6 +21,7 @@ #include <android-base/properties.h> #include <android-base/unique_fd.h> #include <cutils/properties.h> +#include <hidl/HidlSupport.h> #include <log/log.h> #include <pthread.h> #include <string.h> @@ -32,6 +33,7 @@ #define MODEM_LOG_PREFIX_PROPERTY "ro.radio.log_prefix" #define MODEM_LOG_LOC_PROPERTY "ro.radio.log_loc" +#define MODEM_LOGGING_SWITCH "persist.radio.smlog_switch" #define DIAG_MDLOG_PERSIST_PROPERTY "persist.vendor.sys.modem.diag.mdlog" #define DIAG_MDLOG_PROPERTY "vendor.sys.modem.diag.mdlog" @@ -46,6 +48,8 @@ #define MODEM_EFS_DUMP_PROPERTY "vendor.sys.modem.diag.efsdump" +#define VENDOR_VERBOSE_LOGGING_ENABLED_PROPERTY "persist.vendor.verbose_logging_enabled" + using android::os::dumpstate::CommandOptions; using android::os::dumpstate::DumpFileToFd; using android::os::dumpstate::PropertiesHelper; @@ -54,7 +58,7 @@ using android::os::dumpstate::RunCommandToFd; namespace android { namespace hardware { namespace dumpstate { -namespace V1_0 { +namespace V1_1 { namespace implementation { #define DIAG_LOG_PREFIX "diag_log_" @@ -134,14 +138,44 @@ static void *dumpModemThread(void *data) RunCommandToFd(STDOUT_FILENO, "MKDIR MODEM LOG", {"/vendor/bin/mkdir", "-p", modemLogAllDir.c_str()}, CommandOptions::WithTimeout(2).Build()); + const std::string diagLogDir = "/data/vendor/radio/diag_logs/logs"; + const std::string diagPoweronLogPath = "/data/vendor/radio/diag_logs/logs/diag_poweron_log.qmdl"; + + bool diagLogEnabled = android::base::GetBoolProperty(DIAG_MDLOG_PERSIST_PROPERTY, false); + + if (diagLogEnabled) { + bool diagLogStarted = android::base::GetBoolProperty( DIAG_MDLOG_STATUS_PROPERTY, false); + + if (diagLogStarted) { + android::base::SetProperty(DIAG_MDLOG_PROPERTY, "false"); + ALOGD("Stopping diag_mdlog...\n"); + if (android::base::WaitForProperty(DIAG_MDLOG_STATUS_PROPERTY, "false", std::chrono::seconds(10))) { + ALOGD("diag_mdlog exited"); + } else { + ALOGE("Waited mdlog timeout after 10 second"); + } + } else { + ALOGD("diag_mdlog is not running"); + } + + dumpLogs(STDOUT_FILENO, diagLogDir, modemLogAllDir, android::base::GetIntProperty(DIAG_MDLOG_NUMBER_BUGREPORT, 100), DIAG_LOG_PREFIX); + + if (diagLogStarted) { + ALOGD("Restarting diag_mdlog..."); + android::base::SetProperty(DIAG_MDLOG_PROPERTY, "true"); + } + } + RunCommandToFd(STDOUT_FILENO, "CP MODEM POWERON LOG", {"/vendor/bin/cp", diagPoweronLogPath.c_str(), modemLogAllDir.c_str()}, CommandOptions::WithTimeout(2).Build()); + if (!PropertiesHelper::IsUserBuild()) { android::base::SetProperty(MODEM_EFS_DUMP_PROPERTY, "true"); - const std::string diagLogDir = "/data/vendor/radio/diag_logs/logs"; const std::string tcpdumpLogDir = "/data/vendor/tcpdump_logger/logs"; const std::string extendedLogDir = "/data/vendor/radio/extended_logs"; const std::vector <std::string> rilAndNetmgrLogs { + "/data/vendor/radio/haldebug_ril0", + "/data/vendor/radio/haldebug_ril1", "/data/vendor/radio/ril_log0", "/data/vendor/radio/ril_log0_old", "/data/vendor/radio/ril_log1", @@ -152,42 +186,17 @@ static void *dumpModemThread(void *data) "/data/vendor/radio/imsdatadaemon_log_old", "/data/vendor/netmgr/netmgr_log", "/data/vendor/netmgr/netmgr_log_old", + "/data/vendor/radio/omadm_logs.txt", "/data/vendor/radio/power_anomaly_data.txt", "/data/vendor/radio/diag_logs/diag_trace.txt", "/data/vendor/radio/diag_logs/diag_trace_old.txt", - "/data/vendor/radio/diag_logs/logs/diag_poweron_log.qmdl", "/data/vendor/radio/metrics_data", "/data/vendor/ssrlog/ssr_log.txt", "/data/vendor/ssrlog/ssr_log_old.txt", "/data/vendor/rfs/mpss/modem_efs" }; - bool diagLogEnabled = android::base::GetBoolProperty(DIAG_MDLOG_PERSIST_PROPERTY, false); bool tcpdumpEnabled = android::base::GetBoolProperty(TCPDUMP_PERSIST_PROPERTY, false); - - if (diagLogEnabled) { - bool diagLogStarted = android::base::GetBoolProperty(DIAG_MDLOG_STATUS_PROPERTY, false); - - if (diagLogStarted) { - android::base::SetProperty(DIAG_MDLOG_PROPERTY, "false"); - ALOGD("Stopping diag_mdlog...\n"); - if (android::base::WaitForProperty(DIAG_MDLOG_STATUS_PROPERTY, "false", std::chrono::seconds(10))) { - ALOGD("diag_mdlog exited"); - } else { - ALOGE("Waited mdlog timeout after 10 second"); - } - } else { - ALOGD("diag_mdlog is not running"); - } - - dumpLogs(STDOUT_FILENO, diagLogDir, modemLogAllDir, android::base::GetIntProperty(DIAG_MDLOG_NUMBER_BUGREPORT, 100), DIAG_LOG_PREFIX); - - if (diagLogStarted) { - ALOGD("Restarting diag_mdlog..."); - android::base::SetProperty(DIAG_MDLOG_PROPERTY, "true"); - } - } - if (tcpdumpEnabled) { dumpLogs(STDOUT_FILENO, tcpdumpLogDir, modemLogAllDir, android::base::GetIntProperty(TCPDUMP_NUMBER_BUGREPORT, 5), TCPDUMP_LOG_PREFIX); } @@ -275,9 +284,24 @@ static void DumpTouch(int fd) { } } +static void DumpSensorLog(int fd) { + const std::string logPath = "/data/vendor/sensors/log/sensor_log.txt"; + const std::string lastlogPath = "/data/vendor/sensors/log/sensor_lastlog.txt"; + + if (!access(logPath.c_str(), R_OK)) { + DumpFileToFd(fd, "sensor log", logPath); + } + if (!access(lastlogPath.c_str(), R_OK)) { + DumpFileToFd(fd, "sensor lastlog", lastlogPath); + } +} + static void DumpF2FS(int fd) { DumpFileToFd(fd, "F2FS", "/sys/kernel/debug/f2fs/status"); - DumpFileToFd(fd, "F2FS - fragmentation", "/proc/fs/f2fs/dm-6/segment_info"); + RunCommandToFd(fd, "F2FS - fragmentation", {"/vendor/bin/sh", "-c", + "for d in $(ls /proc/fs/f2fs/); do " + "echo $d: /dev/block/mapper/`ls -l /dev/block/mapper | grep $d | awk '{print $8,$9,$10}'`; " + "cat /proc/fs/f2fs/$d/segment_info; done"}); } static void DumpPower(int fd) { @@ -316,26 +340,57 @@ static void DumpeMMC(int fd) { // Methods from ::android::hardware::dumpstate::V1_0::IDumpstateDevice follow. Return<void> DumpstateDevice::dumpstateBoard(const hidl_handle& handle) { + // Ignore return value, just return an empty status. + dumpstateBoard_1_1(handle, DumpstateMode::DEFAULT, 30 * 1000 /* timeoutMillis */); + return Void(); +} + +// Methods from ::android::hardware::dumpstate::V1_1::IDumpstateDevice follow. +Return<DumpstateStatus> DumpstateDevice::dumpstateBoard_1_1(const hidl_handle& handle, + const DumpstateMode mode, + const uint64_t timeoutMillis) { + // Unused arguments. + (void) timeoutMillis; + if (handle == nullptr || handle->numFds < 1) { ALOGE("no FDs\n"); - return Void(); + return DumpstateStatus::ILLEGAL_ARGUMENT; } int fd = handle->data[0]; if (fd < 0) { ALOGE("invalid FD: %d\n", handle->data[0]); - return Void(); + return DumpstateStatus::ILLEGAL_ARGUMENT; + } + + bool isModeValid = false; + for (const auto dumpstateMode : hidl_enum_range<DumpstateMode>()) { + if (mode == dumpstateMode) { + isModeValid = true; + break; + } + } + if (!isModeValid) { + ALOGE("Invalid mode: %d\n", mode); + return DumpstateStatus::ILLEGAL_ARGUMENT; + } else if (mode == DumpstateMode::WEAR) { + // We aren't a Wear device. + ALOGE("Unsupported mode: %d\n", mode); + return DumpstateStatus::UNSUPPORTED_MODE; } RunCommandToFd(fd, "Notify modem", {"/vendor/bin/modem_svc", "-s"}, CommandOptions::WithTimeout(1).Build()); pthread_t modemThreadHandle = 0; - if (handle->numFds < 2) { - ALOGE("no FD for modem\n"); - } else { - int fdModem = handle->data[1]; - if (pthread_create(&modemThreadHandle, NULL, dumpModemThread, (void *)((long)fdModem)) != 0) { - ALOGE("could not create thread for dumpModem\n"); + if (getVerboseLoggingEnabled()) { + ALOGD("Verbose logging is enabled.\n"); + if (handle->numFds < 2) { + ALOGE("no FD for modem\n"); + } else { + int fdModem = handle->data[1]; + if (pthread_create(&modemThreadHandle, NULL, dumpModemThread, (void *)((long)fdModem)) != 0) { + ALOGE("could not create thread for dumpModem\n"); + } } } @@ -351,11 +406,16 @@ Return<void> DumpstateDevice::dumpstateBoard(const hidl_handle& handle) { DumpF2FS(fd); DumpeMMC(fd); + DumpSensorLog(fd); + DumpFileToFd(fd, "INTERRUPTS", "/proc/interrupts"); DumpPower(fd); DumpFileToFd(fd, "LL-Stats", "/d/wlan0/ll_stats"); + DumpFileToFd(fd, "WLAN Connect Info", "/d/wlan0/connect_info"); + DumpFileToFd(fd, "WLAN Offload Info", "/d/wlan0/offload_info"); + DumpFileToFd(fd, "WLAN Roaming Stats", "/d/wlan0/roam_stats"); DumpFileToFd(fd, "ICNSS Stats", "/d/icnss/stats"); DumpFileToFd(fd, "SMD Log", "/d/ipc_logging/smd/log"); RunCommandToFd(fd, "ION HEAPS", {"/vendor/bin/sh", "-c", "for d in $(ls -d /d/ion/*); do for f in $(ls $d); do echo --- $d/$f; cat $d/$f; done; done"}); @@ -401,6 +461,9 @@ Return<void> DumpstateDevice::dumpstateBoard(const hidl_handle& handle) { RunCommandToFd(fd, "Citadel STATS", {"/vendor/bin/hw/citadel_updater", "--stats"}); RunCommandToFd(fd, "Citadel BOARDID", {"/vendor/bin/hw/citadel_updater", "--board_id"}); + // Dump various events in WiFi data path + DumpFileToFd(fd, "WLAN DP Trace", "/d/wlan/dpt_stats/dump_set_dpt_logs"); + // Keep this at the end as very long on not for humans DumpFileToFd(fd, "WLAN FW Log Symbol Table", "/vendor/firmware/Data.msc"); @@ -408,11 +471,20 @@ Return<void> DumpstateDevice::dumpstateBoard(const hidl_handle& handle) { pthread_join(modemThreadHandle, NULL); } + return DumpstateStatus::OK; +} + +Return<void> DumpstateDevice::setVerboseLoggingEnabled(const bool enable) { + android::base::SetProperty(VENDOR_VERBOSE_LOGGING_ENABLED_PROPERTY, enable ? "true" : "false"); return Void(); } +Return<bool> DumpstateDevice::getVerboseLoggingEnabled() { + return android::base::GetBoolProperty(VENDOR_VERBOSE_LOGGING_ENABLED_PROPERTY, false); +} + } // namespace implementation -} // namespace V1_0 +} // namespace V1_1 } // namespace dumpstate } // namespace hardware } // namespace android diff --git a/dumpstate/DumpstateDevice.h b/dumpstate/DumpstateDevice.h index 3aeadeaf..c7119cb8 100644 --- a/dumpstate/DumpstateDevice.h +++ b/dumpstate/DumpstateDevice.h @@ -13,10 +13,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -#ifndef ANDROID_HARDWARE_DUMPSTATE_V1_0_DUMPSTATEDEVICE_H -#define ANDROID_HARDWARE_DUMPSTATE_V1_0_DUMPSTATEDEVICE_H +#ifndef ANDROID_HARDWARE_DUMPSTATE_V1_1_DUMPSTATEDEVICE_H +#define ANDROID_HARDWARE_DUMPSTATE_V1_1_DUMPSTATEDEVICE_H -#include <android/hardware/dumpstate/1.0/IDumpstateDevice.h> +#include <android/hardware/dumpstate/1.1/IDumpstateDevice.h> #include <hidl/MQDescriptor.h> #include <hidl/Status.h> #include <string> @@ -24,10 +24,12 @@ namespace android { namespace hardware { namespace dumpstate { -namespace V1_0 { +namespace V1_1 { namespace implementation { -using ::android::hardware::dumpstate::V1_0::IDumpstateDevice; +using ::android::hardware::dumpstate::V1_1::DumpstateMode; +using ::android::hardware::dumpstate::V1_1::DumpstateStatus; +using ::android::hardware::dumpstate::V1_1::IDumpstateDevice; using ::android::hardware::hidl_array; using ::android::hardware::hidl_handle; using ::android::hardware::hidl_string; @@ -39,12 +41,19 @@ using ::android::sp; struct DumpstateDevice : public IDumpstateDevice { // Methods from ::android::hardware::dumpstate::V1_0::IDumpstateDevice follow. Return<void> dumpstateBoard(const hidl_handle& h) override; + + // Methods from ::android::hardware::dumpstate::V1_1::IDumpstateDevice follow. + Return<DumpstateStatus> dumpstateBoard_1_1(const hidl_handle& h, + const DumpstateMode mode, + const uint64_t timeoutMillis) override; + Return<void> setVerboseLoggingEnabled(const bool enable) override; + Return<bool> getVerboseLoggingEnabled() override; }; } // namespace implementation -} // namespace V1_0 +} // namespace V1_1 } // namespace dumpstate } // namespace hardware } // namespace android -#endif // ANDROID_HARDWARE_DUMPSTATE_V1_0_DUMPSTATEDEVICE_H +#endif // ANDROID_HARDWARE_DUMPSTATE_V1_1_DUMPSTATEDEVICE_H diff --git a/dumpstate/android.hardware.dumpstate@1.0-service.bonito.rc b/dumpstate/android.hardware.dumpstate@1.1-service.bonito.rc index 5f40217c..653d6cff 100644 --- a/dumpstate/android.hardware.dumpstate@1.0-service.bonito.rc +++ b/dumpstate/android.hardware.dumpstate@1.1-service.bonito.rc @@ -1,8 +1,9 @@ -service vendor.dumpstate-1-0 /vendor/bin/hw/android.hardware.dumpstate@1.0-service.bonito +service vendor.dumpstate-1-1 /vendor/bin/hw/android.hardware.dumpstate@1.1-service.bonito class hal user system group system vendor_rfs interface android.hardware.dumpstate@1.0::IDumpstateDevice default + interface android.hardware.dumpstate@1.1::IDumpstateDevice default on boot chmod 0444 /sys/kernel/debug/tzdbg/qsee_log diff --git a/dumpstate/service.cpp b/dumpstate/service.cpp index 14b402f9..907401fc 100644 --- a/dumpstate/service.cpp +++ b/dumpstate/service.cpp @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -#define LOG_TAG "android.hardware.dumpstate@1.0-service.bonito" +#define LOG_TAG "android.hardware.dumpstate@1.1-service.bonito" #include <hidl/HidlSupport.h> #include <hidl/HidlTransportSupport.h> @@ -21,8 +21,8 @@ #include "DumpstateDevice.h" using ::android::hardware::configureRpcThreadpool; -using ::android::hardware::dumpstate::V1_0::IDumpstateDevice; -using ::android::hardware::dumpstate::V1_0::implementation::DumpstateDevice; +using ::android::hardware::dumpstate::V1_1::IDumpstateDevice; +using ::android::hardware::dumpstate::V1_1::implementation::DumpstateDevice; using ::android::hardware::joinRpcThreadpool; using ::android::sp; diff --git a/fstab.hardware b/fstab.hardware index 8346e918..3d41165d 100644 --- a/fstab.hardware +++ b/fstab.hardware @@ -18,5 +18,5 @@ product /product # and fails if it does not find it. /dev/block/bootdevice/by-name/misc /misc emmc defaults defaults /devices/platform/soc/a600000.ssusb/a600000.dwc3/xhci-hcd.*.auto* /storage/usbotg vfat nosuid,nodev wait,voldmanaged=usbotg:auto -/dev/block/zram0 none swap defaults zramsize=2147483648,max_comp_streams=8,zram_loopback_path=/data/per_boot/zram_swap,zram_loopback_size=512M +/dev/block/zram0 none swap defaults zramsize=2147483648,max_comp_streams=8,zram_backingdev_size=512M /dev/block/platform/soc/7c4000.sdhci/by-name/persist /mnt/vendor/persist ext4 nosuid,nodev,noatime,barrier=1 wait,first_stage_mount diff --git a/gpt-utils/gpt-utils.h b/gpt-utils/gpt-utils.h index 0051d2bd..3a93ab34 100644 --- a/gpt-utils/gpt-utils.h +++ b/gpt-utils/gpt-utils.h @@ -72,7 +72,7 @@ extern "C" { #define AB_PARTITION_ATTR_SLOT_ACTIVE (0x1<<2) #define AB_PARTITION_ATTR_BOOT_SUCCESSFUL (0x1<<6) #define AB_PARTITION_ATTR_UNBOOTABLE (0x1<<7) -#define AB_SLOT_ACTIVE_VAL 0x1F +#define AB_SLOT_ACTIVE_VAL 0xF #define AB_SLOT_INACTIVE_VAL 0x0 #define AB_SLOT_ACTIVE 1 #define AB_SLOT_INACTIVE 0 diff --git a/health/Android.bp b/health/Android.bp index b06227ba..9eb609fa 100644 --- a/health/Android.bp +++ b/health/Android.bp @@ -43,8 +43,6 @@ cc_binary { "libbase", "libcutils", "libhidlbase", - "libhidltransport", - "libhwbinder", "libpixelhealth", "libutils", "android.hardware.health@2.0", diff --git a/health/HealthService.cpp b/health/HealthService.cpp index 37c1c248..ffe96bb5 100644 --- a/health/HealthService.cpp +++ b/health/HealthService.cpp @@ -14,28 +14,30 @@ * limitations under the License. */ #define LOG_TAG "android.hardware.health@2.0-service.bonito" -#include <android-base/logging.h> - #include <android-base/file.h> +#include <android-base/logging.h> #include <android-base/parseint.h> #include <android-base/strings.h> #include <health2/Health.h> #include <health2/service.h> #include <healthd/healthd.h> #include <hidl/HidlTransportSupport.h> +#include <pixelhealth/BatteryDefender.h> #include <pixelhealth/BatteryMetricsLogger.h> +#include <pixelhealth/BatteryThermalControl.h> #include <pixelhealth/CycleCountBackupRestore.h> #include <pixelhealth/DeviceHealth.h> #include <pixelhealth/LowBatteryShutdownMetrics.h> -#include "BatteryRechargingControl.h" -#include "BatteryInfoUpdate.h" -#include "LearnedCapacityBackupRestore.h" #include <fstream> #include <iomanip> #include <string> #include <vector> +#include "BatteryInfoUpdate.h" +#include "BatteryRechargingControl.h" +#include "LearnedCapacityBackupRestore.h" + namespace { using android::hardware::health::V2_0::DiskStats; @@ -44,7 +46,9 @@ using android::hardware::health::V2_0::StorageInfo; using ::device::google::bonito::health::BatteryRechargingControl; using ::device::google::bonito::health::BatteryInfoUpdate; using ::device::google::bonito::health::LearnedCapacityBackupRestore; +using hardware::google::pixel::health::BatteryDefender; using hardware::google::pixel::health::BatteryMetricsLogger; +using hardware::google::pixel::health::BatteryThermalControl; using hardware::google::pixel::health::CycleCountBackupRestore; using hardware::google::pixel::health::DeviceHealth; using hardware::google::pixel::health::LowBatteryShutdownMetrics; @@ -55,12 +59,14 @@ constexpr char kBatteryOCV[] {FG_DIR "/bms/voltage_ocv"}; constexpr char kVoltageAvg[] {FG_DIR "/battery/voltage_now"}; constexpr char kCycleCountsBins[] {FG_DIR "/bms/device/cycle_counts_bins"}; +static BatteryDefender battDefender; static BatteryRechargingControl battRechargingControl; static BatteryInfoUpdate battInfoUpdate; +static BatteryThermalControl battThermalControl("sys/devices/virtual/thermal/tz-by-name/soc/mode"); static BatteryMetricsLogger battMetricsLogger(kBatteryResistance, kBatteryOCV); static LowBatteryShutdownMetrics shutdownMetrics(kVoltageAvg); static CycleCountBackupRestore ccBackupRestoreBMS( - 8, kCycleCountsBins, "/persist/battery/qcom_cycle_counts_bins"); + 8, kCycleCountsBins, "/mnt/vendor/persist/battery/qcom_cycle_counts_bins"); static DeviceHealth deviceHealth; static LearnedCapacityBackupRestore lcBackupRestore; @@ -106,16 +112,19 @@ void fill_emmc_storage_attribute(StorageAttribute* attr) { void healthd_board_init(struct healthd_config*) { ccBackupRestoreBMS.Restore(); lcBackupRestore.Restore(); + battDefender.update(); } int healthd_board_battery_update(struct android::BatteryProperties *props) { battRechargingControl.updateBatteryProperties(props); deviceHealth.update(props); + battThermalControl.updateThermalState(props); battInfoUpdate.update(props); battMetricsLogger.logBatteryProperties(props); shutdownMetrics.logShutdownVoltage(props); ccBackupRestoreBMS.Backup(props->batteryLevel); lcBackupRestore.Backup(); + battDefender.update(); return 0; } diff --git a/health/LearnedCapacityBackupRestore.cpp b/health/LearnedCapacityBackupRestore.cpp index cfea5c04..1f307070 100644 --- a/health/LearnedCapacityBackupRestore.cpp +++ b/health/LearnedCapacityBackupRestore.cpp @@ -23,7 +23,7 @@ namespace health { static constexpr char kChgFullDesignFile[] = "sys/class/power_supply/bms/charge_full_design"; static constexpr char kChgFullFile[] = "sys/class/power_supply/bms/charge_full"; -static constexpr char kSysCFPersistFile[] = "/persist/battery/qcom_charge_full"; +static constexpr char kSysCFPersistFile[] = "/mnt/vendor/persist/battery/qcom_charge_full"; static constexpr int kBuffSize = 256; LearnedCapacityBackupRestore::LearnedCapacityBackupRestore() {} diff --git a/hidl/Android.bp b/hidl/Android.bp deleted file mode 100644 index 1389d1cf..00000000 --- a/hidl/Android.bp +++ /dev/null @@ -1,44 +0,0 @@ -// Copyright (C) 2020 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. - -// TODO(b/139369543): remove android.hidl.base@1.0 -cc_prebuilt_library_shared { - name: "android.hidl.base@1.0", - arch: { - arm: { - srcs: ["android.hidl.base@1.0.so-32"], - }, - arm64: { - srcs: ["android.hidl.base@1.0.so-64"], - }, - }, - shared_libs: [ - "libhidlbase", - "liblog", - "libutils", - "libcutils", - "libc++", - "libdl", - "libc", - "libm", - ], - compile_multilib: "both", - vendor_available: true, - strip: { - none: true, - }, - // This module has broken dependencies, libhidltransport and libhwbinder have - // hidden visibility, but this is phasing out anyway so just bypass the check. - check_elf_files: false, -} diff --git a/hidl/android.hidl.base@1.0.so-32 b/hidl/android.hidl.base@1.0.so-32 Binary files differdeleted file mode 100755 index b8c51c8a..00000000 --- a/hidl/android.hidl.base@1.0.so-32 +++ /dev/null diff --git a/hidl/android.hidl.base@1.0.so-64 b/hidl/android.hidl.base@1.0.so-64 Binary files differdeleted file mode 100755 index a3c76e7b..00000000 --- a/hidl/android.hidl.base@1.0.so-64 +++ /dev/null diff --git a/init.hardware.diag.rc.user b/init.hardware.diag.rc.user index c24f851c..6b98ad46 100644 --- a/init.hardware.diag.rc.user +++ b/init.hardware.diag.rc.user @@ -14,6 +14,37 @@ # limitations under the License. # -on property:ro.boot.mode=normal - rm /dev/diag - rm /dev/diagtest +on init + chmod 666 /dev/diag + +on post-fs-data + mkdir /data/vendor/radio 0777 radio radio + mkdir /data/vendor/radio/diag_logs 0777 system system + rm /data/vendor/radio/diag_logs/logs/diag_poweron_log.qmdl + +service diag_mdlog_start /vendor/bin/diag_mdlog + class late_start + user shell + group system diag media_rw + disabled + oneshot + +service diag_mdlog_stop /vendor/bin/diag_mdlog -k + class late_start + user shell + group system diag media_rw + disabled + oneshot + +on property:persist.vendor.sys.modem.diag.mdlog=* + rm /data/vendor/radio/diag_logs/diag_mdlog_pid + setprop vendor.sys.modem.diag.mdlog ${persist.vendor.sys.modem.diag.mdlog} + +on property:vendor.sys.modem.diag.mdlog=true + start diag_mdlog_start + +on property:vendor.sys.modem.diag.mdlog=false + start diag_mdlog_stop + +on property:persist.vendor.verbose_logging_enabled=* + setprop persist.vendor.sys.modem.diag.mdlog ${persist.vendor.verbose_logging_enabled} diff --git a/init.hardware.diag.rc.userdebug b/init.hardware.diag.rc.userdebug index 308535e5..78d67cb2 100644 --- a/init.hardware.diag.rc.userdebug +++ b/init.hardware.diag.rc.userdebug @@ -46,7 +46,7 @@ on boot && property:persist.vendor.sys.modem.diag.mdlog=* rm /data/vendor/radio/diag_logs/diag_mdlog_pid setprop vendor.sys.modem.diag.mdlog ${persist.vendor.sys.modem.diag.mdlog} -on property:vendor.sys.modem.diag.mdlog=true +on property:vendor.sys.modem.diag.mdlog=true && property:persist.vendor.verbose_logging_enabled=true start diag_mdlog_start on property:vendor.sys.modem.diag.mdlog=false diff --git a/init.hardware.rc b/init.hardware.rc index 3f1867fc..0c7d0ad1 100644 --- a/init.hardware.rc +++ b/init.hardware.rc @@ -79,7 +79,7 @@ on init && property:vendor.skip.init=0 # start Citadel keymaster (StrongBox) early start vendor.citadeld - start vendor.keymaster-4-0-citadel + start vendor.keymaster-4-1-citadel # Disable powersaving write /sys/module/lpm_levels/parameters/sleep_disabled 1 @@ -142,12 +142,16 @@ on init && property:vendor.skip.init=0 # Property used by vintf for sku specific manifests setprop ro.boot.product.hardware.sku ${ro.boot.hardware.sku} + # Battery Defender + chown system system /sys/devices/platform/soc/soc:google,charger/charge_stop_level + chown system system /sys/devices/platform/soc/soc:google,charger/charge_start_level + on late-init - setprop vendor.thermal.config thermal_info_config.json chown system system /sys/devices/virtual/thermal/tz-by-name/mb-therm-monitor/trip_point_0_temp chown system system /sys/devices/virtual/thermal/tz-by-name/mb-therm-monitor/trip_point_0_hyst chown system system /sys/devices/virtual/thermal/tz-by-name/usbc-therm-monitor/trip_point_0_temp chown system system /sys/devices/virtual/thermal/tz-by-name/usbc-therm-monitor/trip_point_0_hyst + chown system system /sys/devices/virtual/thermal/tz-by-name/soc/mode on fs mount_all /vendor/etc/fstab.${ro.boot.hardware.platform} --early @@ -183,6 +187,7 @@ on late-fs start devstart_sh # Start services for bootanim + start vendor.power-hal-1-3 start surfaceflinger start bootanim start vendor.hwcomposer-2-2 @@ -233,6 +238,10 @@ on post-fs-data # Setup folder for modem fdr mkdir /data/vendor/modem_fdr 0700 root system + # Resume-on-Reboot after we have the data dir and keymaster + mkdir /data/vendor/rebootescrow 0770 hsm hsm + start vendor.rebootescrow-citadel + # keep that at the end of on post-fs-data # Set indication (checked by vold) that we have finished this action setprop vold.post_fs_data_done 1 @@ -304,6 +313,8 @@ on zygote-start mkdir /data/vendor/sensors 0770 chown system system /data/vendor/sensors + mkdir /data/vendor/sensors/log 0770 + chown system system /data/vendor/sensors/log chmod 770 /mnt/vendor/persist/audio chmod 660 /mnt/vendor/persist/audio/audio.cal @@ -386,7 +397,6 @@ on early-boot chown system system /sys/class/leds/green/rgb_start chown system system /sys/class/leds/blue/rgb_start chown system system /sys/class/backlight/panel0-backlight/brightness - chown system system /sys/class/backlight/panel0-backlight/vr_mode # Permission for Wireless charger chown system system /sys/devices/platform/soc/a88000.i2c/i2c-0/0-0061/rxdata @@ -439,6 +449,9 @@ on boot # WLAN debug access chown system system /d/icnss/stats + # Default enable uicc_se + setprop persist.vendor.radio.uicc_se_enabled true + service init-radio-sh /vendor/bin/init.radio.sh class late_start user radio @@ -534,27 +547,6 @@ on property:sys.boot_completed=1 # Enable PowerHAL hint processing setprop vendor.powerhal.init 1 - # Create pixel-trace. - # At this moment, only mm_event is available. If others want to put more, - # it should get hard review from pixel-perf-team. - - mkdir /sys/kernel/debug/tracing/instances/pixel-trace 600 - write /sys/kernel/debug/tracing/instances/pixel-trace/buffer_size_kb 64 - write /sys/kernel/debug/tracing/instances/pixel-trace/events/mm_event/enable 1 - -# turns off tracing right before bugreporting to keep more traces -on property:init.svc.dumpstatez=running - write /d/tracing/instances/pixel-trace/tracing_on 0 - -on property:init.svc.dumpstatez=stopped - write /d/tracing/instances/pixel-trace/tracing_on 1 - -on property:init.svc.bugreport=running - write /d/tracing/instances/pixel-trace/tracing_on 0 - -on property:init.svc.bugreport=stopped - write /d/tracing/instances/pixel-trace/tracing_on 1 - on property:init.svc.vendor.per_mgr=running start vendor.per_proxy @@ -566,11 +558,6 @@ service vendor.qseecomd /vendor/bin/qseecomd user root group root -service time_daemon /vendor/bin/time_daemon - class core - user root - group root - service ss_ramdump /vendor/bin/subsystem_ramdump class main user root @@ -588,14 +575,6 @@ on property:persist.vendor.sys.ssr.enable_ramdumps=1 on property:persist.vendor.sys.ssr.enable_ramdumps=0 write /sys/module/subsystem_restart/parameters/enable_ramdumps 0 -service sensors.qti /vendor/bin/sensors.qti - class core - user system - group system - # Grants the ability for this daemon to bind IPC router ports so it can - # register QMI services - capabilities NET_BIND_SERVICE - service adsprpcd /vendor/bin/adsprpcd rootpd class main user system @@ -638,21 +617,6 @@ service modem_svc /vendor/bin/modem_svc -q group system capabilities NET_BIND_SERVICE -service wpa_supplicant /vendor/bin/hw/wpa_supplicant \ - -O/data/vendor/wifi/wpa/sockets -puse_p2p_group_interface=1 -dd \ - -g@android:wpa_wlan0 - # we will start as root and wpa_supplicant will switch to user wifi - # after setting up the capabilities required for WEXT - # user wifi - # group wifi inet keystore - interface android.hardware.wifi.supplicant@1.0::ISupplicant default - interface android.hardware.wifi.supplicant@1.1::ISupplicant default - interface android.hardware.wifi.supplicant@1.2::ISupplicant default - class main - socket wpa_wlan0 dgram 660 wifi wifi - disabled - oneshot - service cnss-daemon /vendor/bin/cnss-daemon -n -l class late_start user system @@ -724,20 +688,12 @@ service pd_mapper /vendor/bin/pd-mapper class core # bugreport is triggered by holding down volume down, volume up and power -service bugreport /system/bin/dumpstate -d -p -B -z \ - -o /data/user_de/0/com.android.shell/files/bugreports/bugreport +service bugreport /system/bin/dumpstate -d -p -z class main disabled oneshot keycodes 114 115 116 -service vendor.chre /vendor/bin/chre - class late_start - user system - group system - socket chre seqpacket 0660 root system - shutdown critical - service devstart_sh /vendor/bin/init.qcom.devstart.sh class main user root @@ -810,12 +766,6 @@ on property:sys.retaildemo.enabled=1 setprop persist.vendor.charge.stop.level 35 setprop persist.vendor.charge.start.level 30 -on property:persist.vendor.charge.stop.level=* - write /sys/devices/platform/soc/soc:google,charger/charge_stop_level ${persist.vendor.charge.stop.level} - -on property:persist.vendor.charge.start.level=* - write /sys/devices/platform/soc/soc:google,charger/charge_start_level ${persist.vendor.charge.start.level} - # For Japan radio builds, always enforce camera shutter sound # Since this property is read by the audio server in system service, # it should be written by the system init. @@ -829,10 +779,21 @@ on property:vendor.all.modules.ready=1 chown system system /sys/devices/platform/soc/a84000.i2c/i2c-2/2-0020/input/input2/suspend # DSDS feature +# Restart 1st qcrild after SIM config changed +on property:vendor.radio.sim_num.switch=1to2 && property:persist.radio.multisim.config=dsds + restart vendor.qcrild + +on property:vendor.radio.sim_num.switch=2to1 && property:persist.radio.multisim.config= + restart vendor.qcrild + # Enable 2nd qcrild when the property set to dsds on property:persist.radio.multisim.config=dsds start vendor.qcrild2 +# Stop 2nd qcrild when the property set to empty string +on property:persist.radio.multisim.config= + stop vendor.qcrild2 + on property:sys.boot_completed=1 && property:ro.boot.mode=firstboot start init-firstboot-sh diff --git a/init.qcom.devstart.sh b/init.qcom.devstart.sh index 4d5c4f93..9f67a0b3 100644 --- a/init.qcom.devstart.sh +++ b/init.qcom.devstart.sh @@ -8,4 +8,4 @@ setprop vendor.qcom.devup 1 version=`grep -ao "OEM_IMAGE_VERSION_STRING[ -~]*" \ /vendor/firmware/adsp.b04 | \ sed -e s/OEM_IMAGE_VERSION_STRING=ADSP.version.// -e s/\(.*\).//` -setprop sys.adsp.firmware.version "$version" +setprop vendor.sys.adsp.firmware.version "$version" diff --git a/manifest.xml b/manifest.xml index 8000b1d3..af6def66 100644 --- a/manifest.xml +++ b/manifest.xml @@ -2,7 +2,7 @@ <hal format="hidl"> <name>android.hardware.audio</name> <transport>hwbinder</transport> - <version>5.0</version> + <version>6.0</version> <interface> <name>IDevicesFactory</name> <instance>default</instance> @@ -11,7 +11,7 @@ <hal format="hidl"> <name>android.hardware.audio.effect</name> <transport>hwbinder</transport> - <version>5.0</version> + <version>6.0</version> <interface> <name>IEffectsFactory</name> <instance>default</instance> @@ -29,7 +29,7 @@ <hal format="hidl"> <name>android.hardware.biometrics.fingerprint</name> <transport>hwbinder</transport> - <version>2.1</version> + <version>2.2</version> <interface> <name>IBiometricsFingerprint</name> <instance>default</instance> @@ -90,15 +90,6 @@ </interface> </hal> <hal format="hidl"> - <name>android.hardware.contexthub</name> - <transport>hwbinder</transport> - <version>1.0</version> - <interface> - <name>IContexthub</name> - <instance>default</instance> - </interface> - </hal> - <hal format="hidl"> <name>android.hardware.drm</name> <transport>hwbinder</transport> <version>1.0</version> @@ -112,13 +103,11 @@ </interface> <fqname>@1.2::ICryptoFactory/clearkey</fqname> <fqname>@1.2::IDrmFactory/clearkey</fqname> - <fqname>@1.2::ICryptoFactory/widevine</fqname> - <fqname>@1.2::IDrmFactory/widevine</fqname> </hal> <hal format="hidl"> <name>android.hardware.dumpstate</name> <transport>hwbinder</transport> - <version>1.0</version> + <version>1.1</version> <interface> <name>IDumpstateDevice</name> <instance>default</instance> @@ -181,12 +170,8 @@ <hal format="hidl"> <name>android.hardware.keymaster</name> <transport>hwbinder</transport> - <version>4.0</version> - <interface> - <name>IKeymasterDevice</name> - <instance>default</instance> - <instance>strongbox</instance> - </interface> + <fqname>@4.0::IKeymasterDevice/default</fqname> + <fqname>@4.1::IKeymasterDevice/strongbox</fqname> </hal> <hal format="hidl"> <name>android.hardware.light</name> @@ -232,9 +217,9 @@ <name>android.hardware.neuralnetworks</name> <transport>hwbinder</transport> <fqname>@1.0::IDevice/paintbox</fqname> - <fqname>@1.2::IDevice/qti-default</fqname> - <fqname>@1.2::IDevice/qti-dsp</fqname> - <fqname>@1.2::IDevice/qti-gpu</fqname> + <fqname>@1.3::IDevice/qti-default</fqname> + <fqname>@1.3::IDevice/qti-dsp</fqname> + <fqname>@1.3::IDevice/qti-gpu</fqname> </hal> <hal format="hidl"> <name>android.hardware.nfc</name> @@ -275,7 +260,7 @@ <hal format="hidl"> <name>vendor.google.radioext</name> <transport>hwbinder</transport> - <version>1.1</version> + <version>1.2</version> <interface> <name>IRadioExt</name> <instance>default</instance> @@ -309,7 +294,7 @@ <hal format="hidl"> <name>android.hardware.sensors</name> <transport>hwbinder</transport> - <version>1.0</version> + <version>2.0</version> <interface> <name>ISensors</name> <instance>default</instance> @@ -343,33 +328,6 @@ </interface> </hal> <hal format="hidl"> - <name>android.hardware.usb</name> - <transport>hwbinder</transport> - <version>1.1</version> - <interface> - <name>IUsb</name> - <instance>default</instance> - </interface> - </hal> - <hal format="hidl"> - <name>android.hardware.usb.gadget</name> - <transport>hwbinder</transport> - <version>1.0</version> - <interface> - <name>IUsbGadget</name> - <instance>default</instance> - </interface> - </hal> - <hal format="hidl"> - <name>android.hardware.vibrator</name> - <transport>hwbinder</transport> - <version>1.2</version> - <interface> - <name>IVibrator</name> - <instance>default</instance> - </interface> - </hal> - <hal format="hidl"> <name>android.hardware.weaver</name> <transport>hwbinder</transport> <version>1.0</version> @@ -379,33 +337,6 @@ </interface> </hal> <hal format="hidl"> - <name>android.hardware.wifi</name> - <transport>hwbinder</transport> - <version>1.3</version> - <interface> - <name>IWifi</name> - <instance>default</instance> - </interface> - </hal> - <hal format="hidl"> - <name>android.hardware.wifi.hostapd</name> - <transport>hwbinder</transport> - <version>1.1</version> - <interface> - <name>IHostapd</name> - <instance>default</instance> - </interface> - </hal> - <hal format="hidl"> - <name>android.hardware.wifi.supplicant</name> - <transport>hwbinder</transport> - <version>1.2</version> - <interface> - <name>ISupplicant</name> - <instance>default</instance> - </interface> - </hal> - <hal format="hidl"> <name>vendor.qti.hardware.radio.ims</name> <transport>hwbinder</transport> <version>1.2</version> diff --git a/media_codecs_google_audio.xml b/media_codecs_google_audio.xml deleted file mode 100644 index 7e586fe5..00000000 --- a/media_codecs_google_audio.xml +++ /dev/null @@ -1,103 +0,0 @@ -<?xml version="1.0" encoding="utf-8" ?> -<!-- Copyright (C) 2014 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.mp3.decoder" type="audio/mpeg"> - <Limit name="channel-count" max="2" /> - <Limit name="sample-rate" ranges="8000,11025,12000,16000,22050,24000,32000,44100,48000" /> - <Limit name="bitrate" range="8000-320000" /> - </MediaCodec> - <MediaCodec name="OMX.google.amrnb.decoder" type="audio/3gpp"> - <Limit name="channel-count" max="1" /> - <Limit name="sample-rate" ranges="8000" /> - <Limit name="bitrate" range="4750-12200" /> - </MediaCodec> - <MediaCodec name="OMX.google.amrwb.decoder" type="audio/amr-wb"> - <Limit name="channel-count" max="1" /> - <Limit name="sample-rate" ranges="16000" /> - <Limit name="bitrate" range="6600-23850" /> - </MediaCodec> - <MediaCodec name="OMX.google.aac.decoder" type="audio/mp4a-latm"> - <Limit name="channel-count" max="8" /> - <Limit name="sample-rate" ranges="7350,8000,11025,12000,16000,22050,24000,32000,44100,48000" /> - <Limit name="bitrate" range="8000-960000" /> - </MediaCodec> - <MediaCodec name="OMX.google.xaac.decoder" type="audio/mp4a-latm"> - <Limit name="channel-count" max="8" /> - <Limit name="sample-rate" ranges="7350,8000,11025,12000,16000,22050,24000,32000,44100,48000" /> - <Limit name="bitrate" range="8000-960000" /> - </MediaCodec> - <MediaCodec name="OMX.google.g711.alaw.decoder" type="audio/g711-alaw"> - <Limit name="channel-count" max="1" /> - <Limit name="sample-rate" ranges="8000-48000" /> - <Limit name="bitrate" range="64000" /> - </MediaCodec> - <MediaCodec name="OMX.google.g711.mlaw.decoder" type="audio/g711-mlaw"> - <Limit name="channel-count" max="1" /> - <Limit name="sample-rate" ranges="8000-48000" /> - <Limit name="bitrate" range="64000" /> - </MediaCodec> - <MediaCodec name="OMX.google.vorbis.decoder" type="audio/vorbis"> - <Limit name="channel-count" max="8" /> - <Limit name="sample-rate" ranges="8000-96000" /> - <Limit name="bitrate" range="32000-500000" /> - </MediaCodec> - <MediaCodec name="OMX.google.opus.decoder" type="audio/opus"> - <Limit name="channel-count" max="8" /> - <Limit name="sample-rate" ranges="48000" /> - <Limit name="bitrate" range="6000-510000" /> - </MediaCodec> - <MediaCodec name="OMX.google.raw.decoder" type="audio/raw"> - <Limit name="channel-count" max="8" /> - <Limit name="sample-rate" ranges="8000-96000" /> - <Limit name="bitrate" range="1-10000000" /> - </MediaCodec> - <MediaCodec name="OMX.google.flac.decoder" type="audio/flac"> - <Limit name="channel-count" max="8" /> - <Limit name="sample-rate" ranges="1-655350" /> - <Limit name="bitrate" range="1-21000000" /> - </MediaCodec> - </Decoders> - <Encoders> - <MediaCodec name="OMX.google.aac.encoder" type="audio/mp4a-latm"> - <Limit name="channel-count" max="6" /> - <Limit name="sample-rate" ranges="8000,11025,12000,16000,22050,24000,32000,44100,48000" /> - <!-- also may support 64000, 88200 and 96000 Hz --> - <Limit name="bitrate" range="8000-960000" /> - </MediaCodec> - <MediaCodec name="OMX.google.amrnb.encoder" type="audio/3gpp"> - <Limit name="channel-count" max="1" /> - <Limit name="sample-rate" ranges="8000" /> - <Limit name="bitrate" range="4750-12200" /> - <Feature name="bitrate-modes" value="CBR" /> - </MediaCodec> - <MediaCodec name="OMX.google.amrwb.encoder" type="audio/amr-wb"> - <Limit name="channel-count" max="1" /> - <Limit name="sample-rate" ranges="16000" /> - <Limit name="bitrate" range="6600-23850" /> - <Feature name="bitrate-modes" value="CBR" /> - </MediaCodec> - <MediaCodec name="OMX.google.flac.encoder" type="audio/flac"> - <Limit name="channel-count" max="2" /> - <Limit name="sample-rate" ranges="1-655350" /> - <Limit name="bitrate" range="1-21000000" /> - <Limit name="complexity" range="0-8" default="5" /> - <Feature name="bitrate-modes" value="CQ" /> - </MediaCodec> - </Encoders> -</Included> diff --git a/media_codecs_performance.xml b/media_codecs_performance.xml index b24bd19e..a50da1a1 100644 --- a/media_codecs_performance.xml +++ b/media_codecs_performance.xml @@ -79,7 +79,8 @@ </Encoders> <Decoders> <MediaCodec name="c2.android.h263.decoder" type="video/3gpp" update="true"> - <Limit name="measured-frame-rate-176x144" range="587-587" /> <!-- N=132 v98%=1.5 --> + <Limit name="measured-frame-rate-176x144" range="736-736" /> <!-- N=104 v98%=1.2 --> + <Limit name="measured-frame-rate-352x288" range="573-573" /> <!-- N=104 v98%=1.1 --> </MediaCodec> <MediaCodec name="OMX.qcom.video.decoder.avc" type="video/avc" update="true"> <Limit name="measured-frame-rate-320x240" range="488-493" /> <!-- N=132 v98%=1.5 --> diff --git a/mixer_paths_intcodec_b4.xml b/mixer_paths_intcodec_b4.xml index c7bcc25b..ce4c3ae4 100644 --- a/mixer_paths_intcodec_b4.xml +++ b/mixer_paths_intcodec_b4.xml @@ -1858,6 +1858,8 @@ <path name="voice-rec-dmic-ef"> <path name="dmic-endfire" /> + <ctl name="ADC1 Capture Volume" value="53"/> + <ctl name="ADC2 Capture Volume" value="53"/> </path> <path name="voice-rec-dmic-ef-fluence"> @@ -2072,11 +2074,11 @@ </path> <path name="mmap-playback"> - <ctl name="SEC_MI2S_RX Audio Mixer MultiMedia16" value="1" /> + <ctl name="SEC_TDM_RX_0 Audio Mixer MultiMedia16" value="1" /> </path> <path name="mmap-playback handset"> - <ctl name="SEC_MI2S_RX Audio Mixer MultiMedia16" value="1" /> + <ctl name="SEC_TDM_RX_0 Audio Mixer MultiMedia16" value="1" /> </path> <path name="mmap-playback speaker"> diff --git a/mixer_paths_intcodec_s4.xml b/mixer_paths_intcodec_s4.xml index c7bcc25b..ce4c3ae4 100644 --- a/mixer_paths_intcodec_s4.xml +++ b/mixer_paths_intcodec_s4.xml @@ -1858,6 +1858,8 @@ <path name="voice-rec-dmic-ef"> <path name="dmic-endfire" /> + <ctl name="ADC1 Capture Volume" value="53"/> + <ctl name="ADC2 Capture Volume" value="53"/> </path> <path name="voice-rec-dmic-ef-fluence"> @@ -2072,11 +2074,11 @@ </path> <path name="mmap-playback"> - <ctl name="SEC_MI2S_RX Audio Mixer MultiMedia16" value="1" /> + <ctl name="SEC_TDM_RX_0 Audio Mixer MultiMedia16" value="1" /> </path> <path name="mmap-playback handset"> - <ctl name="SEC_MI2S_RX Audio Mixer MultiMedia16" value="1" /> + <ctl name="SEC_TDM_RX_0 Audio Mixer MultiMedia16" value="1" /> </path> <path name="mmap-playback speaker"> diff --git a/overlay/frameworks/base/core/res/res/values/config.xml b/overlay/frameworks/base/core/res/res/values/config.xml index 9e9f716c..741dcc1b 100644 --- a/overlay/frameworks/base/core/res/res/values/config.xml +++ b/overlay/frameworks/base/core/res/res/values/config.xml @@ -120,6 +120,13 @@ </string-array> <!-- List of regexpressions describing the interface (if any) that represent tetherable + Wifi P2P interfaces. If the device doesn't want to support tethering over Wifi P2p this + should be empty. An example would be "p2p-p2p.*" --> + <string-array translatable="false" name="config_tether_wifi_p2p_regexs"> + <item>"p2p-p2p\\d-.*"</item> + </string-array> + + <!-- List of regexpressions describing the interface (if any) that represent tetherable bluetooth interfaces. If the device doesn't want to support tethering over bluetooth this should be empty. --> <string-array translatable="false" name="config_tether_bluetooth_regexs"> @@ -182,20 +189,6 @@ <item>"9,1"</item> </string-array> - <!-- Boolean indicating whether the wifi chipset has dual frequency band support --> - <bool translatable="false" name="config_wifi_dual_band_support">true</bool> - - <!-- Boolean indicating whether the wifi chipset requires the softap band be --> - <!-- converted from 5GHz to ANY due to hardware restrictions --> - <bool translatable="false" name="config_wifi_convert_apband_5ghz_to_any">true</bool> - - <!-- Boolean indicating whether 802.11r Fast BSS Transition is enabled on this platform --> - <bool translatable="false" name="config_wifi_fast_bss_transition_enabled">true</bool> - - <!-- Boolean indicating whether the wifi chipset has background scan support --> - <bool translatable="false" name="config_wifi_background_scan_support">true</bool> - - <!-- Vibrator pattern for feedback about a long screen/key press --> <integer-array name="config_longPressVibePattern"> <item>8</item> @@ -204,16 +197,6 @@ <!-- Make things go fast --> <bool name="config_ui_enableFadingMarquee">false</bool> - <!-- Wifi driver supports batched scan --> - <bool translatable="false" name="config_wifi_batched_scan_supported">true</bool> - - <!-- Boolean indicating whether or not to revert to default country code when cellular - radio is unable to find any MCC information to infer wifi country code from --> - <bool translatable="false" name="config_wifi_revert_country_code_on_cellular_loss">true</bool> - - <!-- Boolean indicating whether or not wifi should turn off when emergency call is made --> - <bool translatable="false" name="config_wifi_turn_off_during_emergency_call">true</bool> - <!-- Enable doze mode ComponentName of a dream to show whenever the system would otherwise have gone to sleep. --> <string translatable="false" name="config_dozeComponent">com.android.systemui/com.android.systemui.doze.DozeService</string> @@ -269,25 +252,6 @@ <item>lte:524288,1048576,8388608,262144,524288,4194304</item> </string-array> - <!-- 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,2097152,8388608,262144,524288,4194304</string> - - <!-- Idle Receive current for wifi radio. 0 by default--> - <integer translatable="false" name="config_wifi_idle_receive_cur_ma">1</integer> - - <!-- Rx current for wifi radio. 0 by default--> - <integer translatable="false" name="config_wifi_active_rx_cur_ma">100</integer> - - <!-- Tx current for wifi radio. 0 by default--> - <integer translatable="false" name="config_wifi_tx_cur_ma">250</integer> - - <!-- Operating volatage for wifi radio. 0 by default--> - <integer translatable="false" name="config_wifi_operating_voltage_mv">3800</integer> - - <!-- Config SoftAP 2G channel list --> - <string translatable="false" name="config_wifi_framework_sap_2G_channel_list">6</string> - <!-- 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 --> @@ -314,13 +278,13 @@ <item>"/system/framework/framework.jar"</item> <item>"/system/framework/oat/arm64/services.odex"</item> <item>"/system/framework/services.jar"</item> - <item>"/system/framework/arm64/boot.oat"</item> - <item>"/system/framework/arm64/boot-core-libart.oat"</item> - <item>"/apex/com.android.runtime/javalib/core-oj.jar"</item> - <item>"/apex/com.android.runtime/javalib/core-libart.jar"</item> + <item>"/apex/com.android.art/javalib/arm64/boot.oat"</item> + <item>"/apex/com.android.art/javalib/arm64/boot-core-libart.oat"</item> + <item>"/apex/com.android.art/javalib/core-oj.jar"</item> + <item>"/apex/com.android.art/javalib/core-libart.jar"</item> <item>"/apex/com.android.media/javalib/updatable-media.jar"</item> - <item>"/product/priv-app/SystemUIGoogle/SystemUIGoogle.apk"</item> - <item>"/product/priv-app/SystemUIGoogle/oat/arm64/SystemUIGoogle.odex"</item> + <item>"/system_ext/priv-app/SystemUIGoogle/SystemUIGoogle.apk"</item> + <item>"/system_ext/priv-app/SystemUIGoogle/oat/arm64/SystemUIGoogle.odex"</item> <item>"/system/lib64/libsurfaceflinger.so"</item> </string-array> @@ -366,20 +330,6 @@ <!-- Whether the new Auto Selection Network UI should be shown --> <bool name="config_enableNewAutoSelectNetworkUI">true</bool> - <!-- Enable ACS (auto channel selection) for Wifi hotspot (SAP) --> - <bool translatable="false" name="config_wifi_softap_acs_supported">true</bool> - - <!-- Enable 802.11ac for Wifi hotspot (SAP) --> - <bool translatable="false" name="config_wifi_softap_ieee80211ac_supported">true</bool> - - <!-- Integer thresholds, do not connect to APs with RSSI lower than these values --> - <integer translatable="false" name="config_wifi_framework_wifi_score_entry_rssi_threshold_5GHz">-77</integer> - <integer translatable="false" name="config_wifi_framework_wifi_score_entry_rssi_threshold_24GHz">-80</integer> - <!-- Integer thresholds for low network score, should be somewhat less than the entry threshholds --> - <integer translatable="false" name="config_wifi_framework_wifi_score_bad_rssi_threshold_5GHz">-80</integer> - <integer translatable="false" name="config_wifi_framework_wifi_score_bad_rssi_threshold_24GHz">-83</integer> - - <!-- The default intensity level for haptic feedback. See Settings.System.HAPTIC_FEEDBACK_INTENSITY more details on the constant values and meanings. --> @@ -398,12 +348,6 @@ <item>com.felicanetworks.mfc</item> <item>com.felicanetworks.mfm</item> </string-array> - - <!-- True if the firmware supports Wi-Fi link probing --> - <bool name="config_wifi_link_probing_supported">true</bool> - - <!-- True if the firmware supports connected MAC randomization --> - <bool name="config_wifi_connected_mac_randomization_supported">true</bool> <!-- Enable Zram writeback feature to allow unused pages in zram be written to flash. --> <bool name="config_zramWriteback">true</bool> diff --git a/overlay/frameworks/base/packages/SettingsProvider/res/values/defaults.xml b/overlay/frameworks/base/packages/SettingsProvider/res/values/defaults.xml deleted file mode 100644 index 378e34be..00000000 --- a/overlay/frameworks/base/packages/SettingsProvider/res/values/defaults.xml +++ /dev/null @@ -1,24 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/** - * Copyright (c) 2018, 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. - */ ---> -<resources> - <!-- Default for Settings.System.VIBRATE_WHEN_RINGING --> - <bool name="def_vibrate_when_ringing">true</bool> - <!-- Default for Settings.Global.APPLY_RAMPING_RINGER --> - <bool name="def_apply_ramping_ringer">false</bool> -</resources> diff --git a/overlay/frameworks/base/packages/SystemUI/res/values/config.xml b/overlay/frameworks/base/packages/SystemUI/res/values/config.xml index fb7e8cbf..7e9d21d0 100644 --- a/overlay/frameworks/base/packages/SystemUI/res/values/config.xml +++ b/overlay/frameworks/base/packages/SystemUI/res/values/config.xml @@ -31,6 +31,13 @@ always-on display) --> <string name="doze_brightness_sensor_type" translatable="false">com.google.sensor.binned_brightness</string> + <!-- Override value to use for proximity sensor. --> + <string name="proximity_sensor_type" translatable="false">com.google.sensor.binned_brightness</string> + + <!-- If using proximity_sensor_type, specifies a threshold value to distinguish near and + far break points.--> + <item name="proximity_sensor_threshold" translatable="false" format="float" type="dimen">1</item> + <!-- Doze: can we assume the pickup sensor includes a proximity check? --> <bool name="doze_pickup_performs_proximity_check">true</bool> diff --git a/overlay/packages/apps/Bluetooth/res/values/config.xml b/overlay/packages/apps/Bluetooth/res/values/config.xml deleted file mode 100644 index e4031055..00000000 --- a/overlay/packages/apps/Bluetooth/res/values/config.xml +++ /dev/null @@ -1,33 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -Copyright (c) 2017, 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. ---> -<resources> - <bool name="profile_supported_sap">true</bool> - <bool name="profile_supported_hearing_aid">true</bool> -</resources> diff --git a/overlay/packages/apps/Nfc/res/values/config.xml b/overlay/packages/apps/Nfc/res/values/config.xml index 9d194ddf..d919b7f5 100644 --- a/overlay/packages/apps/Nfc/res/values/config.xml +++ b/overlay/packages/apps/Nfc/res/values/config.xml @@ -14,6 +14,10 @@ limitations under the License. --> <resources> + <bool name="enable_antenna_blocked_alert">true</bool> + <integer name="max_antenna_blocked_failure_count">10</integer> + <integer name="unknown_tag_polling_delay">2000</integer> + <string name="antenna_blocked_alert_link" translatable="false">https://support.google.com/pixelphone?p=nfc_tag_notification</string> <string-array name="config_skuSupportsSecureNfc" translatable="false"> <item>G020D</item> <item>G020H</item> diff --git a/pixelstats/Android.bp b/pixelstats/Android.bp index bb658390..dadea9d6 100644 --- a/pixelstats/Android.bp +++ b/pixelstats/Android.bp @@ -24,7 +24,6 @@ cc_binary { "libbinder", "libcutils", "libhidlbase", - "libhidltransport", "liblog", "libutils", "libpixelstats", diff --git a/pixelstats/pixelstats-vendor.bonito.rc b/pixelstats/pixelstats-vendor.bonito.rc index 9410090c..22254bbb 100644 --- a/pixelstats/pixelstats-vendor.bonito.rc +++ b/pixelstats/pixelstats-vendor.bonito.rc @@ -1,4 +1,4 @@ service vendor.pixelstats_vendor /vendor/bin/pixelstats-vendor class hal user system - group system + group system context_hub diff --git a/pixelstats/service.cpp b/pixelstats/service.cpp index 2e72f445..3a9ba894 100644 --- a/pixelstats/service.cpp +++ b/pixelstats/service.cpp @@ -41,6 +41,7 @@ const struct SysfsCollector::SysfsPaths sysfs_paths = { "c440000.qcom,spmi:qcom,pm660l@3:analog-codec@f000/codec_state", .Codec1Path = "/sys/devices/platform/soc/a88000.i2c/i2c-0/0-0057/codec_state", + .F2fsStatsPath = "/sys/fs/f2fs/", }; int main() { diff --git a/powerhint.json b/powerhint.json index d272cd1c..2a8d3455 100644 --- a/powerhint.json +++ b/powerhint.json @@ -206,9 +206,6 @@ "Name": "PowerHALMainState", "Path": "vendor.powerhal.state", "Values": [ - "CAMERA_STREAMING", - "CAMERA_STREAMING_1080P", - "CAMERA_STREAMING_4K", "SUSTAINED_PERFORMANCE", "" ], @@ -218,16 +215,7 @@ "Name": "PowerHALAudioState", "Path": "vendor.powerhal.audio", "Values": [ - "AUDIO_LOW_LATENCY", - "" - ], - "Type": "Property" - }, - { - "Name": "PowerHALRenderingState", - "Path": "vendor.powerhal.rendering", - "Values": [ - "EXPENSIVE_RENDERING", + "AUDIO_STREAMING_LOW_LATENCY", "" ], "Type": "Property" @@ -392,6 +380,12 @@ }, { "PowerHint": "CAMERA_LAUNCH", + "Node": "SchedBoost", + "Duration": 1000, + "Value": "1" + }, + { + "PowerHint": "CAMERA_LAUNCH", "Node": "CPUBigClusterMaxFreq", "Duration": 1000, "Value": "9999999" @@ -421,49 +415,31 @@ "Value": "67" }, { - "PowerHint": "CAMERA_STREAMING", - "Node": "PowerHALMainState", - "Duration": 0, - "Value": "CAMERA_STREAMING" - }, - { - "PowerHint": "CAMERA_STREAMING", + "PowerHint": "CAMERA_STREAMING_MID", "Node": "CPUBigClusterMaxFreq", "Duration": 0, "Value": "1996800" }, { - "PowerHint": "CAMERA_STREAMING_1080P", - "Node": "PowerHALMainState", - "Duration": 0, - "Value": "CAMERA_STREAMING_1080P" - }, - { - "PowerHint": "CAMERA_STREAMING_1080P", + "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "CPUBigClusterMaxFreq", "Duration": 0, "Value": "1996800" }, { - "PowerHint": "CAMERA_STREAMING_1080P", + "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "GPUMinFreq", "Duration": 0, "Value": "430000000" }, { - "PowerHint": "CAMERA_STREAMING_1080P", + "PowerHint": "CAMERA_STREAMING_HIGH", "Node": "GPUMaxFreq", "Duration": 0, "Value": "430000000" }, { - "PowerHint": "CAMERA_STREAMING_4K", - "Node": "PowerHALMainState", - "Duration": 0, - "Value": "CAMERA_STREAMING_4K" - }, - { - "PowerHint": "CAMERA_STREAMING_4K", + "PowerHint": "CAMERA_STREAMING_LOW", "Node": "CPUBigClusterMaxFreq", "Duration": 0, "Value": "1996800" @@ -499,46 +475,28 @@ "Value": "67" }, { - "PowerHint": "AUDIO_STREAMING", + "PowerHint": "AUDIO_LAUNCH", "Node": "CPUBigClusterMinFreq", "Duration": 2000, "Value": "1363200" }, { - "PowerHint": "AUDIO_STREAMING", + "PowerHint": "AUDIO_LAUNCH", "Node": "PMQoSCpuDmaLatency", "Duration": 2000, "Value": "67" }, { - "PowerHint": "AUDIO_LOW_LATENCY", + "PowerHint": "AUDIO_STREAMING_LOW_LATENCY", "Node": "PowerHALAudioState", "Duration": 0, - "Value": "AUDIO_LOW_LATENCY" + "Value": "AUDIO_STREAMING_LOW_LATENCY" }, { - "PowerHint": "AUDIO_LOW_LATENCY", + "PowerHint": "AUDIO_STREAMING_LOW_LATENCY", "Node": "PMQoSCpuDmaLatency", "Duration": 0, "Value": "67" - }, - { - "PowerHint": "EXPENSIVE_RENDERING", - "Node": "PowerHALRenderingState", - "Duration": 0, - "Value": "EXPENSIVE_RENDERING" - }, - { - "PowerHint": "EXPENSIVE_RENDERING", - "Node": "GPUMinFreq", - "Duration": 0, - "Value": "355000000" - }, - { - "PowerHint": "EXPENSIVE_RENDERING", - "Node": "GPUMaxFreq", - "Duration": 0, - "Value": "430000000" } ] } diff --git a/powerstats/Android.bp b/powerstats/Android.bp index 5c4fac6d..ad273dfb 100644 --- a/powerstats/Android.bp +++ b/powerstats/Android.bp @@ -28,7 +28,6 @@ cc_binary { "libbase", "libcutils", "libhidlbase", - "libhidltransport", "libfmq", "liblog", "libutils", diff --git a/product.prop b/product.prop index f85e9fed..cb8e4724 100644 --- a/product.prop +++ b/product.prop @@ -10,9 +10,6 @@ persist.rild.nitz_short_ons_2= persist.rild.nitz_short_ons_3= DEVICE_PROVISIONED=1 -# Set network mode to Global by default and no DSDS/DSDA -ro.telephony.default_network=10 - debug.sf.hw=1 debug.gralloc.enable_fb_ubwc=1 diff --git a/rro_overlays/WifiOverlay/Android.bp b/rro_overlays/WifiOverlay/Android.bp new file mode 100644 index 00000000..54077654 --- /dev/null +++ b/rro_overlays/WifiOverlay/Android.bp @@ -0,0 +1,7 @@ +runtime_resource_overlay { + name: "WifiOverlay", + theme: "WifiOverlay", + certificate: "platform", + sdk_version: "current", + product_specific: true +} diff --git a/rro_overlays/WifiOverlay/AndroidManifest.xml b/rro_overlays/WifiOverlay/AndroidManifest.xml new file mode 100644 index 00000000..632ac6a4 --- /dev/null +++ b/rro_overlays/WifiOverlay/AndroidManifest.xml @@ -0,0 +1,27 @@ +<?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. +--> +<!-- Pixel specific wifi overlays --> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.android.wifi.resources.pixel" + android:versionCode="1" + android:versionName="1.0"> + <application android:hasCode="false" /> + <overlay + android:targetPackage="com.android.wifi.resources" + android:targetName="WifiCustomization" + android:isStatic="true" + android:priority="0"/> +</manifest> diff --git a/rro_overlays/WifiOverlay/OWNERS b/rro_overlays/WifiOverlay/OWNERS new file mode 100644 index 00000000..efe20f15 --- /dev/null +++ b/rro_overlays/WifiOverlay/OWNERS @@ -0,0 +1,5 @@ +# People who can approve changes for submission +etancohen@google.com +kumaranand@google.com +kumachang@google.com +satk@google.com diff --git a/rro_overlays/WifiOverlay/res/values/config.xml b/rro_overlays/WifiOverlay/res/values/config.xml new file mode 100644 index 00000000..972ca8dc --- /dev/null +++ b/rro_overlays/WifiOverlay/res/values/config.xml @@ -0,0 +1,85 @@ +<?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. + */ +--> +<resources> + <!-- Boolean indicating whether the wifi chipset has 5GHz frequency band support --> + <bool translatable="false" name="config_wifi5ghzSupport">true</bool> + + <!-- Boolean indicating whether 802.11r Fast BSS Transition is enabled on this platform --> + <bool translatable="false" name="config_wifi_fast_bss_transition_enabled">true</bool> + + <!-- Boolean indicating whether the wifi chipset has background scan support --> + <bool translatable="false" name="config_wifi_background_scan_support">true</bool> + + <!-- Integer thresholds, do not connect to APs with RSSI lower than these values --> + <integer translatable="false" name="config_wifi_framework_wifi_score_entry_rssi_threshold_5GHz">-77</integer> + <integer translatable="false" name="config_wifi_framework_wifi_score_entry_rssi_threshold_24GHz">-80</integer> + <!-- Integer thresholds for low network score, should be somewhat less than the entry thresholds --> + <integer translatable="false" name="config_wifi_framework_wifi_score_bad_rssi_threshold_5GHz">-80</integer> + <integer translatable="false" name="config_wifi_framework_wifi_score_bad_rssi_threshold_24GHz">-83</integer> + + <!-- Boolean indicating whether or not to revert to default country code when cellular + radio is unable to find any MCC information to infer wifi country code from --> + <bool translatable="false" name="config_wifi_revert_country_code_on_cellular_loss">false</bool> + + <!-- Boolean indicating whether or not wifi should turn off when emergency call is made --> + <bool translatable="false" name="config_wifi_turn_off_during_emergency_call">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,2097152,8388608,262144,524288,4194304</string> + + <!-- Enable ACS (auto channel selection) for Wifi hotspot (SAP) --> + <bool translatable="false" name="config_wifi_softap_acs_supported">true</bool> + + <!-- Enable 802.11ac for Wifi hotspot (SAP) --> + <bool translatable="false" name="config_wifi_softap_ieee80211ac_supported">true</bool> + + <!-- True if the firmware supports connected MAC randomization --> + <bool name="config_wifi_connected_mac_randomization_supported">true</bool> + + <!-- True if the firmware supports p2p MAC randomization --> + <bool name="config_wifi_p2p_mac_randomization_supported">true</bool> + + <!-- True if the firmware supports ap MAC randomization --> + <bool name="config_wifi_ap_mac_randomization_supported">true</bool> + + <!-- True if the firmware supports Wi-Fi link probing --> + <bool name="config_wifi_link_probing_supported">true</bool> + + <!-- Idle Receive current for wifi radio. 0 by default--> + <integer translatable="false" name="config_wifi_idle_receive_cur_ma">1</integer> + + <!-- Rx current for wifi radio. 0 by default--> + <integer translatable="false" name="config_wifi_active_rx_cur_ma">100</integer> + + <!-- Tx current for wifi radio. 0 by default--> + <integer translatable="false" name="config_wifi_tx_cur_ma">250</integer> + + <!-- Operating volatage for wifi radio. 0 by default--> + <integer translatable="false" name="config_wifi_operating_voltage_mv">3800</integer> + + <!-- Indicates that a full bugreport should be triggered when wifi diagnostics detects an error on non-user (i.e debug) builds --> + <bool translatable="false" name="config_wifi_diagnostics_bugreport_enabled">true</bool> + + <!-- Default access point SSID used for tethering --> + <string name="wifi_tether_configure_ssid_default" translatable="false">Pixel</string> + + <!-- Integer indicating maximum hardware supported client number of soft ap --> + <integer translatable="false" name="config_wifiHardwareSoftapMaxClientCount">32</integer> +</resources> diff --git a/sargo/overlay/frameworks/base/core/res/res/values/config.xml b/sargo/overlay/frameworks/base/core/res/res/values/config.xml index f798762b..fb1fc7e0 100755 --- a/sargo/overlay/frameworks/base/core/res/res/values/config.xml +++ b/sargo/overlay/frameworks/base/core/res/res/values/config.xml @@ -134,22 +134,22 @@ backlight values --> <bool name="config_displayBrightnessBucketsInDoze">true</bool> - <!-- Default screen brightness setting. - Must be in the range specified by minimum and maximum. --> - <integer name="config_screenBrightnessSettingDefault">98</integer> - - <!-- Default screen brightness for VR setting. Default value: 0x7F => 127. --> - <integer name="config_screenBrightnessForVrSettingDefault">127</integer> - - <integer name="config_screenBrightnessForVrSettingMinimum">127</integer> - - <!-- Minimum screen brightness setting allowed by the power manager. - The user is forbidden from setting the brightness below this level. --> - <integer name="config_screenBrightnessSettingMinimum">1</integer> - - <!-- Maximum screen brightness setting allowed by the power manager. - The user is forbidden from setting the brightness above this level. --> - <integer name="config_screenBrightnessSettingMaximum">255</integer> + <!-- 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> + + <!-- Maximum screen brightness allowed by the power manager. + The user is forbidden from setting the brightness above this level. + This value is a fraction between 3.5% and 100%. --> + <item name="config_screenBrightnessSettingMaximumFloat" format="float" type="dimen">1.0</item> + + + <!-- Default screen brightness setting + Must be in the range specified by minimum and maximum. + This value is a fraction between 3.5% and 100 + Equivalent to 98/255 (default for this device) --> + <item name="config_screenBrightnessSettingDefaultFloat" format="float" type="dimen">0.38188976378</item> <!-- An array describing the screen's backlight values corresponding to the brightness values in the config_screenBrightnessNits array. diff --git a/sargo/overlay/frameworks/base/core/res/res/xml/power_profile.xml b/sargo/overlay/frameworks/base/core/res/res/xml/power_profile.xml index 9c2d3ce4..5907f02b 100644 --- a/sargo/overlay/frameworks/base/core/res/res/xml/power_profile.xml +++ b/sargo/overlay/frameworks/base/core/res/res/xml/power_profile.xml @@ -72,31 +72,32 @@ <!-- Additional power used by a CPU core from cluster 0 when running at different speeds, excluding cluster and active cost --> + <!-- 6 cores + 6 cpueater & 100 % usage --> <array name="cpu.core_power.cluster0"> - <value>91.48</value> <!-- 300 MHz CPU speed --> - <value>109.3</value> <!-- 576 MHz CPU speed --> - <value>121.12</value> <!-- 748 MHz CPU speed --> - <value>139.74</value> <!-- 998 MHz CPU speed --> - <value>150.07</value> <!-- 1209 MHz CPU speed --> - <value>170.91</value> <!-- 1324 MHz CPU speed --> - <value>190.12</value> <!-- 1516 MHz CPU speed --> - <value>214.74</value> <!-- 1708 MHz CPU speed --> + <value>42.52</value> <!-- 300 MHz CPU speed --> + <value>62.24</value> <!-- 576 MHz CPU speed --> + <value>71.48</value> <!-- 748 MHz CPU speed --> + <value>95.1</value> <!-- 998 MHz CPU speed --> + <value>110.86</value> <!-- 1209 MHz CPU speed --> + <value>125.09</value> <!-- 1324 MHz CPU speed --> + <value>145.31</value> <!-- 1516 MHz CPU speed --> + <value>181.24</value> <!-- 1708 MHz CPU speed --> </array> <!-- Additional power used by a CPU core from cluster 1 when running at different speeds, excluding cluster and active cost --> + <!-- 2 cores + 6 cpueater & 100 % usage --> <array name="cpu.core_power.cluster1"> - <value>48.12</value> <!-- 300 MHz CPU speed --> - <value>55.12</value> <!-- 652 MHz CPU speed --> - <value>58</value> <!-- 825 MHz CPU speed --> - <value>63.35</value> <!-- 979 MHz CPU speed --> - <value>69.06</value> <!-- 1132 MHz CPU speed --> - <value>77.77</value> <!-- 1363 MHz CPU speed --> - <value>86.15</value> <!-- 1536 MHz CPU speed --> - <value>97.41</value> <!-- 1747 MHz CPU speed --> - <value>129.14</value> <!-- 1843 MHz CPU speed --> - <value>139.61</value> <!-- 1996 MHz CPU speed --> - <value>153.09</value> <!-- 2016 MHz CPU speed --> + <value>31.4</value> <!-- 300 MHz CPU speed --> + <value>38.5</value> <!-- 652 MHz CPU speed --> + <value>41.97</value> <!-- 825 MHz CPU speed --> + <value>46.25</value> <!-- 979 MHz CPU speed --> + <value>51.09</value> <!-- 1132 MHz CPU speed --> + <value>63.9</value> <!-- 1363 MHz CPU speed --> + <value>74.5</value> <!-- 1536 MHz CPU speed --> + <value>86.23</value> <!-- 1747 MHz CPU speed --> + <value>117.69</value> <!-- 1843 MHz CPU speed --> + <value>135.31</value> <!-- 1996 MHz CPU speed --> </array> <!-- Additional power used when screen is ambient mode --> <item name="ambient.on">24</item> diff --git a/sargo/overlay_packages/SettingsOverlayG020E/Android.bp b/sargo/overlay_packages/SettingsOverlayG020E/Android.bp new file mode 100644 index 00000000..bd9ad019 --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020E/Android.bp @@ -0,0 +1,4 @@ +runtime_resource_overlay { + name: "SettingsOverlayG020E", + product_specific: true, +}
\ No newline at end of file diff --git a/sargo/overlay_packages/SettingsOverlayG020E/AndroidManifest.xml b/sargo/overlay_packages/SettingsOverlayG020E/AndroidManifest.xml new file mode 100644 index 00000000..a89ab3a7 --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020E/AndroidManifest.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.android.settings.overlay.g020e"> + <application android:hasCode="false" /> + <overlay android:targetPackage="com.android.settings" + android:requiredSystemPropertyName="ro.boot.hardware.sku" + android:requiredSystemPropertyValue="G020E" + android:isStatic="true" + android:priority="0" /> +</manifest>
\ No newline at end of file diff --git a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020e.png b/sargo/overlay_packages/SettingsOverlayG020E/res/drawable/regulatory.png Binary files differindex 2868014b..2868014b 100644 --- a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020e.png +++ b/sargo/overlay_packages/SettingsOverlayG020E/res/drawable/regulatory.png diff --git a/sargo/overlay_packages/SettingsOverlayG020E_VN/Android.bp b/sargo/overlay_packages/SettingsOverlayG020E_VN/Android.bp new file mode 100644 index 00000000..dc422bc7 --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020E_VN/Android.bp @@ -0,0 +1,4 @@ +runtime_resource_overlay { + name: "SettingsOverlayG020E_VN", + product_specific: true, +}
\ No newline at end of file diff --git a/sargo/overlay_packages/SettingsOverlayG020E_VN/AndroidManifest.xml b/sargo/overlay_packages/SettingsOverlayG020E_VN/AndroidManifest.xml new file mode 100644 index 00000000..8b41a7e6 --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020E_VN/AndroidManifest.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.android.settings.overlay.g020e_vn"> + <application android:hasCode="false" /> + <overlay android:targetPackage="com.android.settings" + android:requiredSystemPropertyName="ro.boot.hardware.sku,ro.boot.hardware.coo" + android:requiredSystemPropertyValue="G020E,VN" + android:isStatic="true" + android:priority="1" /> +</manifest>
\ No newline at end of file diff --git a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020e_vn.png b/sargo/overlay_packages/SettingsOverlayG020E_VN/res/drawable/regulatory_info.png Binary files differindex cb342e03..cb342e03 100644 --- a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020e_vn.png +++ b/sargo/overlay_packages/SettingsOverlayG020E_VN/res/drawable/regulatory_info.png diff --git a/sargo/overlay_packages/SettingsOverlayG020F/Android.bp b/sargo/overlay_packages/SettingsOverlayG020F/Android.bp new file mode 100644 index 00000000..22d7132f --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020F/Android.bp @@ -0,0 +1,4 @@ +runtime_resource_overlay { + name: "SettingsOverlayG020F", + product_specific: true, +}
\ No newline at end of file diff --git a/sargo/overlay_packages/SettingsOverlayG020F/AndroidManifest.xml b/sargo/overlay_packages/SettingsOverlayG020F/AndroidManifest.xml new file mode 100644 index 00000000..547184a4 --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020F/AndroidManifest.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.android.settings.overlay.g020f"> + <application android:hasCode="false" /> + <overlay android:targetPackage="com.android.settings" + android:requiredSystemPropertyName="ro.boot.hardware.sku" + android:requiredSystemPropertyValue="G020F" + android:isStatic="true" + android:priority="0" /> +</manifest>
\ No newline at end of file diff --git a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020f.png b/sargo/overlay_packages/SettingsOverlayG020F/res/drawable/regulatory_info.png Binary files differindex 4155dda2..4155dda2 100644 --- a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020f.png +++ b/sargo/overlay_packages/SettingsOverlayG020F/res/drawable/regulatory_info.png diff --git a/sargo/overlay_packages/SettingsOverlayG020F_VN/Android.bp b/sargo/overlay_packages/SettingsOverlayG020F_VN/Android.bp new file mode 100644 index 00000000..f158bc9c --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020F_VN/Android.bp @@ -0,0 +1,4 @@ +runtime_resource_overlay { + name: "SettingsOverlayG020F_VN", + product_specific: true, +}
\ No newline at end of file diff --git a/sargo/overlay_packages/SettingsOverlayG020F_VN/AndroidManifest.xml b/sargo/overlay_packages/SettingsOverlayG020F_VN/AndroidManifest.xml new file mode 100644 index 00000000..ab8bd37d --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020F_VN/AndroidManifest.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.android.settings.overlay.g020f_vn"> + <application android:hasCode="false" /> + <overlay android:targetPackage="com.android.settings" + android:requiredSystemPropertyName="ro.boot.hardware.sku,ro.boot.hardware.coo" + android:requiredSystemPropertyValue="G020F,VN" + android:isStatic="true" + android:priority="1" /> +</manifest>
\ No newline at end of file diff --git a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020f_vn.png b/sargo/overlay_packages/SettingsOverlayG020F_VN/res/drawable/regulatory_info.png Binary files differindex 537af211..537af211 100644 --- a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020f_vn.png +++ b/sargo/overlay_packages/SettingsOverlayG020F_VN/res/drawable/regulatory_info.png diff --git a/sargo/overlay_packages/SettingsOverlayG020G/Android.bp b/sargo/overlay_packages/SettingsOverlayG020G/Android.bp new file mode 100644 index 00000000..1922ccee --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020G/Android.bp @@ -0,0 +1,4 @@ +runtime_resource_overlay { + name: "SettingsOverlayG020G", + product_specific: true, +}
\ No newline at end of file diff --git a/sargo/overlay_packages/SettingsOverlayG020G/AndroidManifest.xml b/sargo/overlay_packages/SettingsOverlayG020G/AndroidManifest.xml new file mode 100644 index 00000000..878aa5d5 --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020G/AndroidManifest.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.android.settings.overlay.g020G"> + <application android:hasCode="false" /> + <overlay android:targetPackage="com.android.settings" + android:requiredSystemPropertyName="ro.boot.hardware.sku" + android:requiredSystemPropertyValue="G020G" + android:isStatic="true" + android:priority="0" /> +</manifest>
\ No newline at end of file diff --git a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020g.png b/sargo/overlay_packages/SettingsOverlayG020G/res/drawable/regulatory_info.png Binary files differindex 62168d64..62168d64 100644 --- a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020g.png +++ b/sargo/overlay_packages/SettingsOverlayG020G/res/drawable/regulatory_info.png diff --git a/sargo/overlay_packages/SettingsOverlayG020G_VN/Android.bp b/sargo/overlay_packages/SettingsOverlayG020G_VN/Android.bp new file mode 100644 index 00000000..5aea9949 --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020G_VN/Android.bp @@ -0,0 +1,4 @@ +runtime_resource_overlay { + name: "SettingsOverlayG020G_VN", + product_specific: true, +}
\ No newline at end of file diff --git a/sargo/overlay_packages/SettingsOverlayG020G_VN/AndroidManifest.xml b/sargo/overlay_packages/SettingsOverlayG020G_VN/AndroidManifest.xml new file mode 100644 index 00000000..96ba9f6a --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020G_VN/AndroidManifest.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.android.settings.overlay.g020G_vn"> + <application android:hasCode="false" /> + <overlay android:targetPackage="com.android.settings" + android:requiredSystemPropertyName="ro.boot.hardware.sku,ro.boot.hardware.coo" + android:requiredSystemPropertyValue="G020G,VN" + android:isStatic="true" + android:priority="1" /> +</manifest>
\ No newline at end of file diff --git a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020g_vn.png b/sargo/overlay_packages/SettingsOverlayG020G_VN/res/drawable/regulatory_info.png Binary files differindex 3d8a5f08..3d8a5f08 100644 --- a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020g_vn.png +++ b/sargo/overlay_packages/SettingsOverlayG020G_VN/res/drawable/regulatory_info.png diff --git a/sargo/overlay_packages/SettingsOverlayG020H/Android.bp b/sargo/overlay_packages/SettingsOverlayG020H/Android.bp new file mode 100644 index 00000000..98a401c1 --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020H/Android.bp @@ -0,0 +1,4 @@ +runtime_resource_overlay { + name: "SettingsOverlayG020H", + product_specific: true, +}
\ No newline at end of file diff --git a/sargo/overlay_packages/SettingsOverlayG020H/AndroidManifest.xml b/sargo/overlay_packages/SettingsOverlayG020H/AndroidManifest.xml new file mode 100644 index 00000000..91a7526c --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020H/AndroidManifest.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.android.settings.overlay.g020h"> + <application android:hasCode="false" /> + <overlay android:targetPackage="com.android.settings" + android:requiredSystemPropertyName="ro.boot.hardware.sku" + android:requiredSystemPropertyValue="G020H" + android:isStatic="true" + android:priority="0" /> +</manifest>
\ No newline at end of file diff --git a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020h.png b/sargo/overlay_packages/SettingsOverlayG020H/res/drawable/regulatory_info.png Binary files differindex 6c837efb..6c837efb 100644 --- a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020h.png +++ b/sargo/overlay_packages/SettingsOverlayG020H/res/drawable/regulatory_info.png diff --git a/sargo/overlay_packages/SettingsOverlayG020H_VN/Android.bp b/sargo/overlay_packages/SettingsOverlayG020H_VN/Android.bp new file mode 100644 index 00000000..1096140c --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020H_VN/Android.bp @@ -0,0 +1,4 @@ +runtime_resource_overlay { + name: "SettingsOverlayG020H_VN", + product_specific: true, +}
\ No newline at end of file diff --git a/sargo/overlay_packages/SettingsOverlayG020H_VN/AndroidManifest.xml b/sargo/overlay_packages/SettingsOverlayG020H_VN/AndroidManifest.xml new file mode 100644 index 00000000..7759c3c0 --- /dev/null +++ b/sargo/overlay_packages/SettingsOverlayG020H_VN/AndroidManifest.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.android.settings.overlay.g020h_vn"> + <application android:hasCode="false" /> + <overlay android:targetPackage="com.android.settings" + android:requiredSystemPropertyName="ro.boot.hardware.sku,ro.boot.hardware.coo" + android:requiredSystemPropertyValue="G020H,VN" + android:isStatic="true" + android:priority="1" /> +</manifest>
\ No newline at end of file diff --git a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020h_vn.png b/sargo/overlay_packages/SettingsOverlayG020H_VN/res/drawable/regulatory_info.png Binary files differindex 665771a6..665771a6 100644 --- a/sargo/overlay/packages/apps/Settings/res/drawable/regulatory_info_g020h_vn.png +++ b/sargo/overlay_packages/SettingsOverlayG020H_VN/res/drawable/regulatory_info.png diff --git a/self-extractors/extract-lists.txt b/self-extractors/extract-lists.txt index 51e24de5..4a035a97 100644 --- a/self-extractors/extract-lists.txt +++ b/self-extractors/extract-lists.txt @@ -10,30 +10,18 @@ system/app/ims/ims.apk \ system/app/QtiTelephonyService/QtiTelephonyService.apk \ system/etc/cne/andsfCne.xml \ - system/etc/permissions/cneapiclient.xml \ - system/etc/permissions/com.quicinc.cne.xml \ - system/etc/permissions/embms.xml \ - system/etc/permissions/LteDirectDiscovery.xml \ system/etc/permissions/qcrilhook.xml \ - system/etc/permissions/radioconfiginterface.xml \ - system/etc/permissions/radioconfig.xml \ system/etc/permissions/telephonyservice.xml \ system/etc/permissions/uimremoteclient.xml \ system/etc/permissions/uimremoteserver.xml \ system/etc/permissions/UimService.xml \ - system/framework/com.qualcomm.qti.uceservice-V2.0-java.jar \ system/framework/qcrilhook.jar \ system/framework/QtiTelephonyServicelibrary.jar \ system/framework/uimremoteclientlibrary.jar \ system/framework/uimremoteserverlibrary.jar \ - system/framework/vendor.qti.hardware.alarm-V1.0-java.jar \ - system/framework/vendor.qti.hardware.soter-V1.0-java.jar \ system/lib64/libadsprpc_system.so \ system/lib64/libcdsprpc_system.so \ system/lib64/libDiagService.so \ - system/lib64/libdiag_system.so \ - system/lib64/libGPQTEEC_system.so \ - system/lib64/libGPTEE_system.so \ system/lib64/libimscamera_jni.so \ system/lib64/libimsmedia_jni.so \ system/lib64/lib-imsvideocodec.so \ @@ -41,16 +29,12 @@ system/lib64/lib-imsvt.so \ system/lib64/lib-imsvtutils.so \ system/lib64/libmdsprpc_system.so \ - system/lib64/libQTEEConnector_system.so \ system/lib64/librcc.so \ system/lib64/libsdm-disp-apis.so \ system/lib64/libsdsprpc_system.so \ system/lib64/libsecureui_svcsock_system.so \ system/lib/libadsprpc_system.so \ system/lib/libcdsprpc_system.so \ - system/lib/libdiag_system.so \ - system/lib/libGPQTEEC_system.so \ - system/lib/libGPTEE_system.so \ system/lib/libimscamera_jni.so \ system/lib/libimsmedia_jni.so \ system/lib/lib-imsvideocodec.so \ @@ -58,11 +42,9 @@ system/lib/lib-imsvt.so \ system/lib/lib-imsvtutils.so \ system/lib/libmdsprpc_system.so \ - system/lib/libQTEEConnector_system.so \ system/lib/librcc.so \ system/lib/libsdm-disp-apis.so \ system/lib/libsdsprpc_system.so \ system/lib/libsecureui_svcsock_system.so \ - system/lib/rfsa/adsp/libsns_low_lat_stream_skel.so \ " ;; diff --git a/self-extractors/qcom/staging/Android.bp.txt b/self-extractors/qcom/staging/Android.bp.txt new file mode 100644 index 00000000..14c15a71 --- /dev/null +++ b/self-extractors/qcom/staging/Android.bp.txt @@ -0,0 +1,563 @@ +// Copyright (C) 2020 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. + +soong_namespace { +} + +cc_prebuilt_library_shared { + name: "libadsprpc_system", + arch: { + arm: { + srcs: ["libadsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libadsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, +} + +cc_prebuilt_library_shared { + name: "libcdsprpc_system", + arch: { + arm: { + srcs: ["libcdsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libcdsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, +} + +cc_prebuilt_library_shared { + name: "libDiagService", + arch: { + arm64: { + srcs: ["lib64/libDiagService.so"], + shared_libs: [ + "libandroid_runtime", + "libnativehelper", + "libutils", + "libcutils", + "liblog", + // "libdiag_system", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "64", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} + +cc_prebuilt_library_shared { + name: "libimscamera_jni", + arch: { + arm: { + srcs: ["libimscamera_jni.so"], + shared_libs: [ + "libnativehelper", + "libcutils", + "libutils", + "liblog", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libimscamera_jni.so"], + shared_libs: [ + "libnativehelper", + "libcutils", + "libutils", + "liblog", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, +} + +cc_prebuilt_library_shared { + name: "libimsmedia_jni", + arch: { + arm: { + srcs: ["libimsmedia_jni.so"], + shared_libs: [ + "libnativehelper", + "libcutils", + "libutils", + "libgui", + "libbinder", + "liblog", + "libandroid", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libimsmedia_jni.so"], + shared_libs: [ + "libnativehelper", + "libcutils", + "libutils", + "libgui", + "libbinder", + "liblog", + "libandroid", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, +} + +cc_prebuilt_library_shared { + name: "lib-imsvideocodec", + arch: { + arm: { + srcs: ["lib-imsvideocodec.so"], + shared_libs: [ + "lib-imsvtutils", + "lib-imsvtextutils", + "libcutils", + "libutils", + "liblog", + // "libdiag_system", + "libgui", + "libnativewindow", + "libmediandk", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/lib-imsvideocodec.so"], + shared_libs: [ + "lib-imsvtutils", + "lib-imsvtextutils", + "libcutils", + "libutils", + "liblog", + // "libdiag_system", + "libgui", + "libnativewindow", + "libmediandk", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} + +cc_prebuilt_library_shared { + name: "lib-imsvtextutils", + arch: { + arm: { + srcs: ["lib-imsvtextutils.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + // "libdiag_system", + "lib-imsvtutils", + "libGLESv2", + "libEGL", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/lib-imsvtextutils.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + // "libdiag_system", + "lib-imsvtutils", + "libGLESv2", + "libEGL", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} + +cc_prebuilt_library_shared { + name: "lib-imsvt", + arch: { + arm: { + srcs: ["lib-imsvt.so"], + shared_libs: [ + "librcc", + "lib-imsvideocodec", + "lib-imsvtutils", + "libandroid", + // "libhwbinder", + "libhidlbase", + // "libhidltransport", + // "vendor.qti.imsrtpservice@1.0", + // "libdiag_system", + "libcutils", + "libutils", + "liblog", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/lib-imsvt.so"], + shared_libs: [ + "librcc", + "lib-imsvideocodec", + "lib-imsvtutils", + "libandroid", + // "libhwbinder", + "libhidlbase", + // "libhidltransport", + // "vendor.qti.imsrtpservice@1.0", + // "libdiag_system", + "libcutils", + "libutils", + "liblog", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} + +cc_prebuilt_library_shared { + name: "lib-imsvtutils", + arch: { + arm: { + srcs: ["lib-imsvtutils.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + // "libdiag_system", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/lib-imsvtutils.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + // "libdiag_system", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} + +cc_prebuilt_library_shared { + name: "libmdsprpc_system", + arch: { + arm: { + srcs: ["libmdsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libmdsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, +} + +cc_prebuilt_library_shared { + name: "librcc", + arch: { + arm: { + srcs: ["librcc.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + // "libdiag_system", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/librcc.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + // "libdiag_system", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} + +cc_prebuilt_library_shared { + name: "libsdm-disp-apis", + arch: { + arm: { + srcs: ["libsdm-disp-apis.so"], + shared_libs: [ + "libcutils", + "libutils", + "liblog", + "libhidlbase", + // "libhidltransport", + // "vendor.display.color@1.0", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libsdm-disp-apis.so"], + shared_libs: [ + "libcutils", + "libutils", + "liblog", + "libhidlbase", + // "libhidltransport", + // "vendor.display.color@1.0", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} + +cc_prebuilt_library_shared { + name: "libsdsprpc_system", + arch: { + arm: { + srcs: ["libsdsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libsdsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, +} + +cc_prebuilt_library_shared { + name: "libsecureui_svcsock_system", + arch: { + arm: { + srcs: ["libsecureui_svcsock_system.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + "libhidlbase", + // "libhidltransport", + // "libhwbinder", + // "vendor.qti.hardware.tui_comm@1.0", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libsecureui_svcsock_system.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + "libhidlbase", + // "libhidltransport", + // "libhwbinder", + // "vendor.qti.hardware.tui_comm@1.0", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} diff --git a/self-extractors/qcom/staging/device-partial.mk b/self-extractors/qcom/staging/device-partial.mk index 4ede68f1..18d46cab 100644 --- a/self-extractors/qcom/staging/device-partial.mk +++ b/self-extractors/qcom/staging/device-partial.mk @@ -12,65 +12,40 @@ # See the License for the specific language governing permissions and # limitations under the License. +PRODUCT_SOONG_NAMESPACES += \ + vendor/qcom/bonito/proprietary + # AOSP packages required by the blobs PRODUCT_PACKAGES := \ ims \ QtiTelephonyService # blob(s) necessary for bonito hardware +PRODUCT_PACKAGES += \ + libadsprpc_system \ + libcdsprpc_system \ + libDiagService \ + libimscamera_jni \ + libimsmedia_jni \ + lib-imsvideocodec \ + lib-imsvtextutils \ + lib-imsvt \ + lib-imsvtutils \ + libmdsprpc_system \ + librcc \ + libsdm-disp-apis \ + libsdsprpc_system \ + libsecureui_svcsock_system \ + PRODUCT_COPY_FILES := \ vendor/qcom/bonito/proprietary/andsfCne.xml:system/etc/cne/andsfCne.xml:qcom \ - vendor/qcom/bonito/proprietary/cneapiclient.xml:system/etc/permissions/cneapiclient.xml:qcom \ - vendor/qcom/bonito/proprietary/com.quicinc.cne.xml:system/etc/permissions/com.quicinc.cne.xml:qcom \ - vendor/qcom/bonito/proprietary/embms.xml:system/etc/permissions/embms.xml:qcom \ - vendor/qcom/bonito/proprietary/LteDirectDiscovery.xml:system/etc/permissions/LteDirectDiscovery.xml:qcom \ vendor/qcom/bonito/proprietary/qcrilhook.xml:system/etc/permissions/qcrilhook.xml:qcom \ - vendor/qcom/bonito/proprietary/radioconfiginterface.xml:system/etc/permissions/radioconfiginterface.xml:qcom \ - vendor/qcom/bonito/proprietary/radioconfig.xml:system/etc/permissions/radioconfig.xml:qcom \ vendor/qcom/bonito/proprietary/telephonyservice.xml:system/etc/permissions/telephonyservice.xml:qcom \ vendor/qcom/bonito/proprietary/uimremoteclient.xml:system/etc/permissions/uimremoteclient.xml:qcom \ vendor/qcom/bonito/proprietary/uimremoteserver.xml:system/etc/permissions/uimremoteserver.xml:qcom \ vendor/qcom/bonito/proprietary/UimService.xml:system/etc/permissions/UimService.xml:qcom \ - vendor/qcom/bonito/proprietary/com.qualcomm.qti.uceservice-V2.0-java.jar:system/framework/com.qualcomm.qti.uceservice-V2.0-java.jar:qcom \ vendor/qcom/bonito/proprietary/qcrilhook.jar:system/framework/qcrilhook.jar:qcom \ vendor/qcom/bonito/proprietary/QtiTelephonyServicelibrary.jar:system/framework/QtiTelephonyServicelibrary.jar:qcom \ vendor/qcom/bonito/proprietary/uimremoteclientlibrary.jar:system/framework/uimremoteclientlibrary.jar:qcom \ vendor/qcom/bonito/proprietary/uimremoteserverlibrary.jar:system/framework/uimremoteserverlibrary.jar:qcom \ - vendor/qcom/bonito/proprietary/vendor.qti.hardware.alarm-V1.0-java.jar:system/framework/vendor.qti.hardware.alarm-V1.0-java.jar:qcom \ - vendor/qcom/bonito/proprietary/vendor.qti.hardware.soter-V1.0-java.jar:system/framework/vendor.qti.hardware.soter-V1.0-java.jar:qcom \ - vendor/qcom/bonito/proprietary/lib64/libadsprpc_system.so:system/lib64/libadsprpc_system.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/libcdsprpc_system.so:system/lib64/libcdsprpc_system.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/libDiagService.so:system/lib64/libDiagService.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/libdiag_system.so:system/lib64/libdiag_system.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/libGPQTEEC_system.so:system/lib64/libGPQTEEC_system.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/libGPTEE_system.so:system/lib64/libGPTEE_system.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/libimscamera_jni.so:system/lib64/libimscamera_jni.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/libimsmedia_jni.so:system/lib64/libimsmedia_jni.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/lib-imsvideocodec.so:system/lib64/lib-imsvideocodec.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/lib-imsvtextutils.so:system/lib64/lib-imsvtextutils.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/lib-imsvt.so:system/lib64/lib-imsvt.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/lib-imsvtutils.so:system/lib64/lib-imsvtutils.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/libmdsprpc_system.so:system/lib64/libmdsprpc_system.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/libQTEEConnector_system.so:system/lib64/libQTEEConnector_system.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/librcc.so:system/lib64/librcc.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/libsdm-disp-apis.so:system/lib64/libsdm-disp-apis.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/libsdsprpc_system.so:system/lib64/libsdsprpc_system.so:qcom \ - vendor/qcom/bonito/proprietary/lib64/libsecureui_svcsock_system.so:system/lib64/libsecureui_svcsock_system.so:qcom \ - vendor/qcom/bonito/proprietary/libadsprpc_system.so:system/lib/libadsprpc_system.so:qcom \ - vendor/qcom/bonito/proprietary/libcdsprpc_system.so:system/lib/libcdsprpc_system.so:qcom \ - vendor/qcom/bonito/proprietary/libdiag_system.so:system/lib/libdiag_system.so:qcom \ - vendor/qcom/bonito/proprietary/libGPQTEEC_system.so:system/lib/libGPQTEEC_system.so:qcom \ - vendor/qcom/bonito/proprietary/libGPTEE_system.so:system/lib/libGPTEE_system.so:qcom \ - vendor/qcom/bonito/proprietary/libimscamera_jni.so:system/lib/libimscamera_jni.so:qcom \ - vendor/qcom/bonito/proprietary/libimsmedia_jni.so:system/lib/libimsmedia_jni.so:qcom \ - vendor/qcom/bonito/proprietary/lib-imsvideocodec.so:system/lib/lib-imsvideocodec.so:qcom \ - vendor/qcom/bonito/proprietary/lib-imsvtextutils.so:system/lib/lib-imsvtextutils.so:qcom \ - vendor/qcom/bonito/proprietary/lib-imsvt.so:system/lib/lib-imsvt.so:qcom \ - vendor/qcom/bonito/proprietary/lib-imsvtutils.so:system/lib/lib-imsvtutils.so:qcom \ - vendor/qcom/bonito/proprietary/libmdsprpc_system.so:system/lib/libmdsprpc_system.so:qcom \ - vendor/qcom/bonito/proprietary/libQTEEConnector_system.so:system/lib/libQTEEConnector_system.so:qcom \ - vendor/qcom/bonito/proprietary/librcc.so:system/lib/librcc.so:qcom \ - vendor/qcom/bonito/proprietary/libsdm-disp-apis.so:system/lib/libsdm-disp-apis.so:qcom \ - vendor/qcom/bonito/proprietary/libsdsprpc_system.so:system/lib/libsdsprpc_system.so:qcom \ - vendor/qcom/bonito/proprietary/libsecureui_svcsock_system.so:system/lib/libsecureui_svcsock_system.so:qcom \ - vendor/qcom/bonito/proprietary/libsns_low_lat_stream_skel.so:system/lib/rfsa/adsp/libsns_low_lat_stream_skel.so:qcom \ + diff --git a/self-extractors_sargo/extract-lists.txt b/self-extractors_sargo/extract-lists.txt index 51e24de5..4a035a97 100644 --- a/self-extractors_sargo/extract-lists.txt +++ b/self-extractors_sargo/extract-lists.txt @@ -10,30 +10,18 @@ system/app/ims/ims.apk \ system/app/QtiTelephonyService/QtiTelephonyService.apk \ system/etc/cne/andsfCne.xml \ - system/etc/permissions/cneapiclient.xml \ - system/etc/permissions/com.quicinc.cne.xml \ - system/etc/permissions/embms.xml \ - system/etc/permissions/LteDirectDiscovery.xml \ system/etc/permissions/qcrilhook.xml \ - system/etc/permissions/radioconfiginterface.xml \ - system/etc/permissions/radioconfig.xml \ system/etc/permissions/telephonyservice.xml \ system/etc/permissions/uimremoteclient.xml \ system/etc/permissions/uimremoteserver.xml \ system/etc/permissions/UimService.xml \ - system/framework/com.qualcomm.qti.uceservice-V2.0-java.jar \ system/framework/qcrilhook.jar \ system/framework/QtiTelephonyServicelibrary.jar \ system/framework/uimremoteclientlibrary.jar \ system/framework/uimremoteserverlibrary.jar \ - system/framework/vendor.qti.hardware.alarm-V1.0-java.jar \ - system/framework/vendor.qti.hardware.soter-V1.0-java.jar \ system/lib64/libadsprpc_system.so \ system/lib64/libcdsprpc_system.so \ system/lib64/libDiagService.so \ - system/lib64/libdiag_system.so \ - system/lib64/libGPQTEEC_system.so \ - system/lib64/libGPTEE_system.so \ system/lib64/libimscamera_jni.so \ system/lib64/libimsmedia_jni.so \ system/lib64/lib-imsvideocodec.so \ @@ -41,16 +29,12 @@ system/lib64/lib-imsvt.so \ system/lib64/lib-imsvtutils.so \ system/lib64/libmdsprpc_system.so \ - system/lib64/libQTEEConnector_system.so \ system/lib64/librcc.so \ system/lib64/libsdm-disp-apis.so \ system/lib64/libsdsprpc_system.so \ system/lib64/libsecureui_svcsock_system.so \ system/lib/libadsprpc_system.so \ system/lib/libcdsprpc_system.so \ - system/lib/libdiag_system.so \ - system/lib/libGPQTEEC_system.so \ - system/lib/libGPTEE_system.so \ system/lib/libimscamera_jni.so \ system/lib/libimsmedia_jni.so \ system/lib/lib-imsvideocodec.so \ @@ -58,11 +42,9 @@ system/lib/lib-imsvt.so \ system/lib/lib-imsvtutils.so \ system/lib/libmdsprpc_system.so \ - system/lib/libQTEEConnector_system.so \ system/lib/librcc.so \ system/lib/libsdm-disp-apis.so \ system/lib/libsdsprpc_system.so \ system/lib/libsecureui_svcsock_system.so \ - system/lib/rfsa/adsp/libsns_low_lat_stream_skel.so \ " ;; diff --git a/self-extractors_sargo/qcom/staging/Android.bp.txt b/self-extractors_sargo/qcom/staging/Android.bp.txt new file mode 100644 index 00000000..14c15a71 --- /dev/null +++ b/self-extractors_sargo/qcom/staging/Android.bp.txt @@ -0,0 +1,563 @@ +// Copyright (C) 2020 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. + +soong_namespace { +} + +cc_prebuilt_library_shared { + name: "libadsprpc_system", + arch: { + arm: { + srcs: ["libadsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libadsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, +} + +cc_prebuilt_library_shared { + name: "libcdsprpc_system", + arch: { + arm: { + srcs: ["libcdsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libcdsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, +} + +cc_prebuilt_library_shared { + name: "libDiagService", + arch: { + arm64: { + srcs: ["lib64/libDiagService.so"], + shared_libs: [ + "libandroid_runtime", + "libnativehelper", + "libutils", + "libcutils", + "liblog", + // "libdiag_system", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "64", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} + +cc_prebuilt_library_shared { + name: "libimscamera_jni", + arch: { + arm: { + srcs: ["libimscamera_jni.so"], + shared_libs: [ + "libnativehelper", + "libcutils", + "libutils", + "liblog", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libimscamera_jni.so"], + shared_libs: [ + "libnativehelper", + "libcutils", + "libutils", + "liblog", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, +} + +cc_prebuilt_library_shared { + name: "libimsmedia_jni", + arch: { + arm: { + srcs: ["libimsmedia_jni.so"], + shared_libs: [ + "libnativehelper", + "libcutils", + "libutils", + "libgui", + "libbinder", + "liblog", + "libandroid", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libimsmedia_jni.so"], + shared_libs: [ + "libnativehelper", + "libcutils", + "libutils", + "libgui", + "libbinder", + "liblog", + "libandroid", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, +} + +cc_prebuilt_library_shared { + name: "lib-imsvideocodec", + arch: { + arm: { + srcs: ["lib-imsvideocodec.so"], + shared_libs: [ + "lib-imsvtutils", + "lib-imsvtextutils", + "libcutils", + "libutils", + "liblog", + // "libdiag_system", + "libgui", + "libnativewindow", + "libmediandk", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/lib-imsvideocodec.so"], + shared_libs: [ + "lib-imsvtutils", + "lib-imsvtextutils", + "libcutils", + "libutils", + "liblog", + // "libdiag_system", + "libgui", + "libnativewindow", + "libmediandk", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} + +cc_prebuilt_library_shared { + name: "lib-imsvtextutils", + arch: { + arm: { + srcs: ["lib-imsvtextutils.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + // "libdiag_system", + "lib-imsvtutils", + "libGLESv2", + "libEGL", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/lib-imsvtextutils.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + // "libdiag_system", + "lib-imsvtutils", + "libGLESv2", + "libEGL", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} + +cc_prebuilt_library_shared { + name: "lib-imsvt", + arch: { + arm: { + srcs: ["lib-imsvt.so"], + shared_libs: [ + "librcc", + "lib-imsvideocodec", + "lib-imsvtutils", + "libandroid", + // "libhwbinder", + "libhidlbase", + // "libhidltransport", + // "vendor.qti.imsrtpservice@1.0", + // "libdiag_system", + "libcutils", + "libutils", + "liblog", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/lib-imsvt.so"], + shared_libs: [ + "librcc", + "lib-imsvideocodec", + "lib-imsvtutils", + "libandroid", + // "libhwbinder", + "libhidlbase", + // "libhidltransport", + // "vendor.qti.imsrtpservice@1.0", + // "libdiag_system", + "libcutils", + "libutils", + "liblog", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} + +cc_prebuilt_library_shared { + name: "lib-imsvtutils", + arch: { + arm: { + srcs: ["lib-imsvtutils.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + // "libdiag_system", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/lib-imsvtutils.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + // "libdiag_system", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} + +cc_prebuilt_library_shared { + name: "libmdsprpc_system", + arch: { + arm: { + srcs: ["libmdsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libmdsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, +} + +cc_prebuilt_library_shared { + name: "librcc", + arch: { + arm: { + srcs: ["librcc.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + // "libdiag_system", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/librcc.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + // "libdiag_system", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} + +cc_prebuilt_library_shared { + name: "libsdm-disp-apis", + arch: { + arm: { + srcs: ["libsdm-disp-apis.so"], + shared_libs: [ + "libcutils", + "libutils", + "liblog", + "libhidlbase", + // "libhidltransport", + // "vendor.display.color@1.0", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libsdm-disp-apis.so"], + shared_libs: [ + "libcutils", + "libutils", + "liblog", + "libhidlbase", + // "libhidltransport", + // "vendor.display.color@1.0", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} + +cc_prebuilt_library_shared { + name: "libsdsprpc_system", + arch: { + arm: { + srcs: ["libsdsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libsdsprpc_system.so"], + shared_libs: [ + "liblog", + "libcutils", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, +} + +cc_prebuilt_library_shared { + name: "libsecureui_svcsock_system", + arch: { + arm: { + srcs: ["libsecureui_svcsock_system.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + "libhidlbase", + // "libhidltransport", + // "libhwbinder", + // "vendor.qti.hardware.tui_comm@1.0", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + arm64: { + srcs: ["lib64/libsecureui_svcsock_system.so"], + shared_libs: [ + "libutils", + "libcutils", + "liblog", + "libhidlbase", + // "libhidltransport", + // "libhwbinder", + // "vendor.qti.hardware.tui_comm@1.0", + "libc++", + "libc", + "libm", + "libdl", + ], + }, + }, + compile_multilib: "both", + owner: "qcom", + strip: { + none: true, + }, + check_elf_files: false, +} diff --git a/self-extractors_sargo/qcom/staging/device-partial.mk b/self-extractors_sargo/qcom/staging/device-partial.mk index 9fdefd8a..a52aca8c 100644 --- a/self-extractors_sargo/qcom/staging/device-partial.mk +++ b/self-extractors_sargo/qcom/staging/device-partial.mk @@ -12,65 +12,40 @@ # See the License for the specific language governing permissions and # limitations under the License. +PRODUCT_SOONG_NAMESPACES += \ + vendor/qcom/sargo/proprietary + # AOSP packages required by the blobs PRODUCT_PACKAGES := \ ims \ QtiTelephonyService # blob(s) necessary for sargo hardware +PRODUCT_PACKAGES += \ + libadsprpc_system \ + libcdsprpc_system \ + libDiagService \ + libimscamera_jni \ + libimsmedia_jni \ + lib-imsvideocodec \ + lib-imsvtextutils \ + lib-imsvt \ + lib-imsvtutils \ + libmdsprpc_system \ + librcc \ + libsdm-disp-apis \ + libsdsprpc_system \ + libsecureui_svcsock_system \ + PRODUCT_COPY_FILES := \ vendor/qcom/sargo/proprietary/andsfCne.xml:system/etc/cne/andsfCne.xml:qcom \ - vendor/qcom/sargo/proprietary/cneapiclient.xml:system/etc/permissions/cneapiclient.xml:qcom \ - vendor/qcom/sargo/proprietary/com.quicinc.cne.xml:system/etc/permissions/com.quicinc.cne.xml:qcom \ - vendor/qcom/sargo/proprietary/embms.xml:system/etc/permissions/embms.xml:qcom \ - vendor/qcom/sargo/proprietary/LteDirectDiscovery.xml:system/etc/permissions/LteDirectDiscovery.xml:qcom \ vendor/qcom/sargo/proprietary/qcrilhook.xml:system/etc/permissions/qcrilhook.xml:qcom \ - vendor/qcom/sargo/proprietary/radioconfiginterface.xml:system/etc/permissions/radioconfiginterface.xml:qcom \ - vendor/qcom/sargo/proprietary/radioconfig.xml:system/etc/permissions/radioconfig.xml:qcom \ vendor/qcom/sargo/proprietary/telephonyservice.xml:system/etc/permissions/telephonyservice.xml:qcom \ vendor/qcom/sargo/proprietary/uimremoteclient.xml:system/etc/permissions/uimremoteclient.xml:qcom \ vendor/qcom/sargo/proprietary/uimremoteserver.xml:system/etc/permissions/uimremoteserver.xml:qcom \ vendor/qcom/sargo/proprietary/UimService.xml:system/etc/permissions/UimService.xml:qcom \ - vendor/qcom/sargo/proprietary/com.qualcomm.qti.uceservice-V2.0-java.jar:system/framework/com.qualcomm.qti.uceservice-V2.0-java.jar:qcom \ vendor/qcom/sargo/proprietary/qcrilhook.jar:system/framework/qcrilhook.jar:qcom \ vendor/qcom/sargo/proprietary/QtiTelephonyServicelibrary.jar:system/framework/QtiTelephonyServicelibrary.jar:qcom \ vendor/qcom/sargo/proprietary/uimremoteclientlibrary.jar:system/framework/uimremoteclientlibrary.jar:qcom \ vendor/qcom/sargo/proprietary/uimremoteserverlibrary.jar:system/framework/uimremoteserverlibrary.jar:qcom \ - vendor/qcom/sargo/proprietary/vendor.qti.hardware.alarm-V1.0-java.jar:system/framework/vendor.qti.hardware.alarm-V1.0-java.jar:qcom \ - vendor/qcom/sargo/proprietary/vendor.qti.hardware.soter-V1.0-java.jar:system/framework/vendor.qti.hardware.soter-V1.0-java.jar:qcom \ - vendor/qcom/sargo/proprietary/lib64/libadsprpc_system.so:system/lib64/libadsprpc_system.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/libcdsprpc_system.so:system/lib64/libcdsprpc_system.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/libDiagService.so:system/lib64/libDiagService.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/libdiag_system.so:system/lib64/libdiag_system.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/libGPQTEEC_system.so:system/lib64/libGPQTEEC_system.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/libGPTEE_system.so:system/lib64/libGPTEE_system.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/libimscamera_jni.so:system/lib64/libimscamera_jni.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/libimsmedia_jni.so:system/lib64/libimsmedia_jni.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/lib-imsvideocodec.so:system/lib64/lib-imsvideocodec.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/lib-imsvtextutils.so:system/lib64/lib-imsvtextutils.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/lib-imsvt.so:system/lib64/lib-imsvt.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/lib-imsvtutils.so:system/lib64/lib-imsvtutils.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/libmdsprpc_system.so:system/lib64/libmdsprpc_system.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/libQTEEConnector_system.so:system/lib64/libQTEEConnector_system.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/librcc.so:system/lib64/librcc.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/libsdm-disp-apis.so:system/lib64/libsdm-disp-apis.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/libsdsprpc_system.so:system/lib64/libsdsprpc_system.so:qcom \ - vendor/qcom/sargo/proprietary/lib64/libsecureui_svcsock_system.so:system/lib64/libsecureui_svcsock_system.so:qcom \ - vendor/qcom/sargo/proprietary/libadsprpc_system.so:system/lib/libadsprpc_system.so:qcom \ - vendor/qcom/sargo/proprietary/libcdsprpc_system.so:system/lib/libcdsprpc_system.so:qcom \ - vendor/qcom/sargo/proprietary/libdiag_system.so:system/lib/libdiag_system.so:qcom \ - vendor/qcom/sargo/proprietary/libGPQTEEC_system.so:system/lib/libGPQTEEC_system.so:qcom \ - vendor/qcom/sargo/proprietary/libGPTEE_system.so:system/lib/libGPTEE_system.so:qcom \ - vendor/qcom/sargo/proprietary/libimscamera_jni.so:system/lib/libimscamera_jni.so:qcom \ - vendor/qcom/sargo/proprietary/libimsmedia_jni.so:system/lib/libimsmedia_jni.so:qcom \ - vendor/qcom/sargo/proprietary/lib-imsvideocodec.so:system/lib/lib-imsvideocodec.so:qcom \ - vendor/qcom/sargo/proprietary/lib-imsvtextutils.so:system/lib/lib-imsvtextutils.so:qcom \ - vendor/qcom/sargo/proprietary/lib-imsvt.so:system/lib/lib-imsvt.so:qcom \ - vendor/qcom/sargo/proprietary/lib-imsvtutils.so:system/lib/lib-imsvtutils.so:qcom \ - vendor/qcom/sargo/proprietary/libmdsprpc_system.so:system/lib/libmdsprpc_system.so:qcom \ - vendor/qcom/sargo/proprietary/libQTEEConnector_system.so:system/lib/libQTEEConnector_system.so:qcom \ - vendor/qcom/sargo/proprietary/librcc.so:system/lib/librcc.so:qcom \ - vendor/qcom/sargo/proprietary/libsdm-disp-apis.so:system/lib/libsdm-disp-apis.so:qcom \ - vendor/qcom/sargo/proprietary/libsdsprpc_system.so:system/lib/libsdsprpc_system.so:qcom \ - vendor/qcom/sargo/proprietary/libsecureui_svcsock_system.so:system/lib/libsecureui_svcsock_system.so:qcom \ - vendor/qcom/sargo/proprietary/libsns_low_lat_stream_skel.so:system/lib/rfsa/adsp/libsns_low_lat_stream_skel.so:qcom \ + diff --git a/ueventd.hardware.rc b/ueventd.hardware.rc index e9289696..027d7e9b 100644 --- a/ueventd.hardware.rc +++ b/ueventd.hardware.rc @@ -121,3 +121,6 @@ firmware_directories /vendor/firmware_mnt/image/ # Storage: for factory reset protection feature /dev/block/platform/soc/7c4000.sdhci/by-name/frp 0660 system system + +# Resume-on-Reboot +/dev/access-kregistry 0660 system system diff --git a/usb/Android.bp b/usb/Android.bp index 449b0678..67b33493 100644 --- a/usb/Android.bp +++ b/usb/Android.bp @@ -16,17 +16,21 @@ cc_binary { name: "android.hardware.usb@1.1-service.bonito", relative_install_path: "hw", init_rc: ["android.hardware.usb@1.1-service.bonito.rc"], + vintf_fragments: [ + "android.hardware.usb@1.1-service.bonito.xml", + "android.hardware.usb.gadget@1.1-service.bonito.xml", + ], srcs: ["service.cpp", "Usb.cpp", "UsbGadget.cpp"], shared_libs: [ "libbase", "libhidlbase", - "libhidltransport", "liblog", "libutils", "libhardware", "android.hardware.usb@1.0", "android.hardware.usb@1.1", - "android.hardware.usb.gadget@1.0", + "android.hardware.usb.gadget@1.0", + "android.hardware.usb.gadget@1.1", "libcutils", ], proprietary: true, diff --git a/usb/UsbGadget.cpp b/usb/UsbGadget.cpp index 82916a22..58daf242 100644 --- a/usb/UsbGadget.cpp +++ b/usb/UsbGadget.cpp @@ -14,7 +14,7 @@ * limitations under the License. */ -#define LOG_TAG "android.hardware.usb.gadget@1.0-service.bonito" +#define LOG_TAG "android.hardware.usb.gadget@1.1-service.bonito" #include "UsbGadget.h" #include <dirent.h> @@ -58,7 +58,7 @@ namespace android { namespace hardware { namespace usb { namespace gadget { -namespace V1_0 { +namespace V1_1 { namespace implementation { volatile bool gadgetPullup; @@ -283,6 +283,15 @@ V1_0::Status UsbGadget::tearDownGadget() { return Status::SUCCESS; } +Return<Status> UsbGadget::reset() { + if (!WriteStringToFile("none", PULLUP_PATH)) { + ALOGI("Gadget cannot be pulled down"); + return Status::ERROR; + } + + return Status::SUCCESS; +} + static int linkFunction(const char *function, int index) { char functionPath[MAX_FILE_PATH_LENGTH]; char link[MAX_FILE_PATH_LENGTH]; @@ -527,6 +536,8 @@ V1_0::Status UsbGadget::setupFunctions( if ((functions & GadgetFunction::ADB) != 0) { ffsEnabled = true; ALOGI("setCurrentUsbFunctions Adb"); + if (!WriteStringToFile("1", DESC_USE_PATH)) + return Status::ERROR; if (inotify_add_watch(inotifyFd, "/dev/usb-ffs/adb/", IN_ALL_EVENTS) == -1) return Status::ERROR; @@ -643,7 +654,7 @@ error: return Void(); } } // namespace implementation -} // namespace V1_0 +} // namespace V1_1 } // namespace gadget } // namespace usb } // namespace hardware diff --git a/usb/UsbGadget.h b/usb/UsbGadget.h index a0aa42b1..327be9ad 100644 --- a/usb/UsbGadget.h +++ b/usb/UsbGadget.h @@ -14,29 +14,28 @@ * limitations under the License. */ -#ifndef ANDROID_HARDWARE_USB_GADGET_V1_0_USBGADGET_H -#define ANDROID_HARDWARE_USB_GADGET_V1_0_USBGADGET_H +#pragma once #include <android-base/file.h> #include <android-base/properties.h> #include <android-base/unique_fd.h> -#include <android/hardware/usb/gadget/1.0/IUsbGadget.h> +#include <android/hardware/usb/gadget/1.1/IUsbGadget.h> #include <hidl/MQDescriptor.h> #include <hidl/Status.h> -#include <string> #include <sys/epoll.h> #include <sys/eventfd.h> -#include <thread> #include <utils/Log.h> #include <chrono> #include <condition_variable> #include <mutex> +#include <string> +#include <thread> namespace android { namespace hardware { namespace usb { namespace gadget { -namespace V1_0 { +namespace V1_1 { namespace implementation { using ::android::sp; @@ -50,7 +49,9 @@ using ::android::hardware::hidl_string; using ::android::hardware::hidl_vec; using ::android::hardware::Return; using ::android::hardware::Void; -using ::std::chrono::steady_clock; +using ::android::hardware::usb::gadget::V1_0::GadgetFunction; +using ::android::hardware::usb::gadget::V1_0::Status; +using ::android::hardware::usb::gadget::V1_1::IUsbGadget; using ::std::lock_guard; using ::std::move; using ::std::mutex; @@ -58,6 +59,7 @@ using ::std::string; using ::std::thread; using ::std::unique_ptr; using ::std::vector; +using ::std::chrono::steady_clock; using namespace std::chrono; using namespace std::chrono_literals; @@ -80,24 +82,22 @@ struct UsbGadget : public IUsbGadget { bool mCurrentUsbFunctionsApplied; Return<void> setCurrentUsbFunctions(uint64_t functions, - const sp<IUsbGadgetCallback>& callback, + const sp<V1_0::IUsbGadgetCallback> &callback, uint64_t timeout) override; - Return<void> getCurrentUsbFunctions( - const sp<IUsbGadgetCallback>& callback) override; + Return<void> getCurrentUsbFunctions(const sp<V1_0::IUsbGadgetCallback> &callback) override; - private: + Return<Status> reset() override; + +private: Status tearDownGadget(); - Status setupFunctions(uint64_t functions, - const sp<IUsbGadgetCallback>& callback, + Status setupFunctions(uint64_t functions, const sp<V1_0::IUsbGadgetCallback> &callback, uint64_t timeout); }; } // namespace implementation -} // namespace V1_0 +} // namespace V1_1 } // namespace gadget } // namespace usb } // namespace hardware } // namespace android - -#endif // ANDROID_HARDWARE_USB_V1_2_USBGADGET_H diff --git a/usb/android.hardware.usb.gadget@1.1-service.bonito.xml b/usb/android.hardware.usb.gadget@1.1-service.bonito.xml new file mode 100644 index 00000000..a6f9a1f4 --- /dev/null +++ b/usb/android.hardware.usb.gadget@1.1-service.bonito.xml @@ -0,0 +1,11 @@ +<manifest version="1.0" type="device"> + <hal format="hidl"> + <name>android.hardware.usb.gadget</name> + <transport>hwbinder</transport> + <version>1.1</version> + <interface> + <name>IUsbGadget</name> + <instance>default</instance> + </interface> + </hal> +</manifest> diff --git a/usb/android.hardware.usb@1.1-service.bonito.xml b/usb/android.hardware.usb@1.1-service.bonito.xml new file mode 100644 index 00000000..5ce2ff45 --- /dev/null +++ b/usb/android.hardware.usb@1.1-service.bonito.xml @@ -0,0 +1,12 @@ +<manifest version="1.0" type="device"> + <hal format="hidl"> + <name>android.hardware.usb</name> + <transport>hwbinder</transport> + <version>1.1</version> + <interface> + <name>IUsb</name> + <instance>default</instance> + </interface> + </hal> +</manifest> + diff --git a/usb/service.cpp b/usb/service.cpp index ec9d3f06..f3e8b330 100644 --- a/usb/service.cpp +++ b/usb/service.cpp @@ -27,10 +27,10 @@ using android::hardware::configureRpcThreadpool; using android::hardware::joinRpcThreadpool; // Generated HIDL files +using android::hardware::usb::gadget::V1_1::IUsbGadget; +using android::hardware::usb::gadget::V1_1::implementation::UsbGadget; using android::hardware::usb::V1_1::IUsb; -using android::hardware::usb::gadget::V1_0::IUsbGadget; using android::hardware::usb::V1_1::implementation::Usb; -using android::hardware::usb::gadget::V1_0::implementation::UsbGadget; using android::OK; using android::status_t; diff --git a/vibrator/Android.bp b/vibrator/Android.bp deleted file mode 100644 index 2462082a..00000000 --- a/vibrator/Android.bp +++ /dev/null @@ -1,34 +0,0 @@ -// -// Copyright (C) 2017 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. -cc_binary { - name: "android.hardware.vibrator@1.2-service.bonito", - relative_install_path: "hw", - init_rc: ["android.hardware.vibrator@1.2-service.bonito.rc"], - srcs: ["service.cpp", "Vibrator.cpp"], - cflags: ["-Wall", "-Werror"], - shared_libs: [ - "libhidlbase", - "libcutils", - "libhidltransport", - "liblog", - "libhwbinder", - "libutils", - "libhardware", - "android.hardware.vibrator@1.0", - "android.hardware.vibrator@1.1", - "android.hardware.vibrator@1.2" - ], - proprietary: true, -} diff --git a/vibrator/OWNERS b/vibrator/OWNERS deleted file mode 100644 index 2ce99556..00000000 --- a/vibrator/OWNERS +++ /dev/null @@ -1,3 +0,0 @@ -eliptus@google.com -michaelwr@google.com -chasewu@google.com diff --git a/vibrator/Vibrator.cpp b/vibrator/Vibrator.cpp deleted file mode 100644 index 509d7391..00000000 --- a/vibrator/Vibrator.cpp +++ /dev/null @@ -1,231 +0,0 @@ -/* - * Copyright (C) 2017 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. - */ - -#define LOG_TAG "VibratorService" - -#include <log/log.h> - -#include <cutils/properties.h> -#include <hardware/hardware.h> -#include <hardware/vibrator.h> - -#include "Vibrator.h" - -#include <cinttypes> -#include <cmath> -#include <fstream> -#include <iostream> - -namespace android { -namespace hardware { -namespace vibrator { -namespace V1_2 { -namespace implementation { - -static constexpr int8_t MAX_RTP_INPUT = 127; -static constexpr int8_t MIN_RTP_INPUT = 0; - -static constexpr char RTP_MODE[] = "rtp"; -static constexpr char WAVEFORM_MODE[] = "waveform"; - -static constexpr uint32_t LOOP_MODE_OPEN = 1; -static constexpr uint32_t SINE_WAVE = 1; -static constexpr uint32_t SQUARE_WAVE = 0; - -// Default max voltage 2.15V -static constexpr uint32_t VOLTAGE_MAX = 107; - -// Use effect #1 in the waveform library for CLICK effect -static constexpr char WAVEFORM_CLICK_EFFECT_SEQ[] = "1 0"; -static constexpr int32_t WAVEFORM_CLICK_EFFECT_MS = 6; - -// Use effect #2 in the waveform library for TICK effect -static constexpr char WAVEFORM_TICK_EFFECT_SEQ[] = "2 0"; -static constexpr int32_t WAVEFORM_TICK_EFFECT_MS = 2; - -// Use effect #3 in the waveform library for DOUBLE_CLICK effect -static constexpr char WAVEFORM_DOUBLE_CLICK_EFFECT_SEQ[] = "3 0"; -static constexpr uint32_t WAVEFORM_DOUBLE_CLICK_EFFECT_MS = 182; - -// Use effect #4 in the waveform library for HEAVY_CLICK effect -static constexpr char WAVEFORM_HEAVY_CLICK_EFFECT_SEQ[] = "4 0"; -static constexpr uint32_t WAVEFORM_HEAVY_CLICK_EFFECT_MS = 8; - -using Status = ::android::hardware::vibrator::V1_0::Status; -using EffectStrength = ::android::hardware::vibrator::V1_0::EffectStrength; - -Vibrator::Vibrator(HwApi &&hwapi, std::uint32_t short_lra_period, std::uint32_t long_lra_period) - : mHwApi(std::move(hwapi)), mShortLraPeriod(short_lra_period), mLongLraPeriod(long_lra_period) { - mClickDuration = property_get_int32("ro.vibrator.hal.click.duration", WAVEFORM_CLICK_EFFECT_MS); - mTickDuration = property_get_int32("ro.vibrator.hal.tick.duration", WAVEFORM_TICK_EFFECT_MS); - mHeavyClickDuration = - property_get_int32("ro.vibrator.hal.heavyclick.duration", WAVEFORM_HEAVY_CLICK_EFFECT_MS); - mShortVoltageMax = property_get_int32("ro.vibrator.hal.short.voltage", VOLTAGE_MAX); - mLongVoltageMax = property_get_int32("ro.vibrator.hal.long.voltage", VOLTAGE_MAX); - - // This enables effect #1 from the waveform library to be triggered by SLPI - // while the AP is in suspend mode - mHwApi.lpTriggerEffect << 1 << std::endl; - if (!mHwApi.lpTriggerEffect) { - ALOGW("Failed to set LP trigger mode (%d): %s", errno, strerror(errno)); - } -} - -Return<Status> Vibrator::on(uint32_t timeoutMs, bool isWaveform) { - // Bonito / Sargo only support open-loop mode - mHwApi.ctrlLoop << LOOP_MODE_OPEN << std::endl; - mHwApi.duration << timeoutMs << std::endl; - if (!mHwApi.duration) { - ALOGE("Failed to set duration (%d): %s", errno, strerror(errno)); - return Status::UNKNOWN_ERROR; - } - - if (isWaveform) { - mHwApi.mode << WAVEFORM_MODE << std::endl; - mHwApi.lraWaveShape << SINE_WAVE << std::endl; - mHwApi.odClamp << mShortVoltageMax << std::endl; - mHwApi.olLraPeriod << mShortLraPeriod << std::endl; - } else { - mHwApi.mode << RTP_MODE << std::endl; - mHwApi.lraWaveShape << SQUARE_WAVE << std::endl; - mHwApi.odClamp << mLongVoltageMax << std::endl; - mHwApi.olLraPeriod << mLongLraPeriod << std::endl; - } - - mHwApi.activate << 1 << std::endl; - if (!mHwApi.activate) { - ALOGE("Failed to activate (%d): %s", errno, strerror(errno)); - return Status::UNKNOWN_ERROR; - } - - return Status::OK; -} - -// Methods from ::android::hardware::vibrator::V1_2::IVibrator follow. -Return<Status> Vibrator::on(uint32_t timeoutMs) { - return on(timeoutMs, false /* isWaveform */); -} - -Return<Status> Vibrator::off() { - mHwApi.activate << 0 << std::endl; - if (!mHwApi.activate) { - ALOGE("Failed to turn vibrator off (%d): %s", errno, strerror(errno)); - return Status::UNKNOWN_ERROR; - } - return Status::OK; -} - -Return<bool> Vibrator::supportsAmplitudeControl() { - return (mHwApi.rtpInput ? true : false); -} - -Return<Status> Vibrator::setAmplitude(uint8_t amplitude) { - if (amplitude == 0) { - return Status::BAD_VALUE; - } - - int32_t rtp_input = - std::round((amplitude - 1) / 254.0 * (MAX_RTP_INPUT - MIN_RTP_INPUT) + MIN_RTP_INPUT); - - mHwApi.rtpInput << rtp_input << std::endl; - if (!mHwApi.rtpInput) { - ALOGE("Failed to set amplitude (%d): %s", errno, strerror(errno)); - return Status::UNKNOWN_ERROR; - } - - return Status::OK; -} - -static uint8_t convertEffectStrength(EffectStrength strength) { - uint8_t scale; - - switch (strength) { - case EffectStrength::LIGHT: - scale = 2; // 50% - break; - case EffectStrength::MEDIUM: - case EffectStrength::STRONG: - scale = 0; // 100% - break; - } - - return scale; -} - -Return<void> Vibrator::perform(V1_0::Effect effect, EffectStrength strength, perform_cb _hidl_cb) { - return performWrapper(effect, strength, _hidl_cb); -} - -Return<void> Vibrator::perform_1_1(V1_1::Effect_1_1 effect, EffectStrength strength, - perform_cb _hidl_cb) { - return performWrapper(effect, strength, _hidl_cb); -} - -Return<void> Vibrator::perform_1_2(Effect effect, EffectStrength strength, perform_cb _hidl_cb) { - return performWrapper(effect, strength, _hidl_cb); -} - -template <typename T> -Return<void> Vibrator::performWrapper(T effect, EffectStrength strength, perform_cb _hidl_cb) { - auto validEffectRange = hidl_enum_range<T>(); - if (effect < *validEffectRange.begin() || effect > *std::prev(validEffectRange.end())) { - _hidl_cb(Status::UNSUPPORTED_OPERATION, 0); - return Void(); - } - auto validStrengthRange = hidl_enum_range<EffectStrength>(); - if (strength < *validStrengthRange.begin() || strength > *std::prev(validStrengthRange.end())) { - _hidl_cb(Status::UNSUPPORTED_OPERATION, 0); - return Void(); - } - return performEffect(static_cast<Effect>(effect), strength, _hidl_cb); -} - -Return<void> Vibrator::performEffect(Effect effect, EffectStrength strength, perform_cb _hidl_cb) { - Status status = Status::OK; - uint32_t timeMS; - - switch (effect) { - case Effect::CLICK: - mHwApi.sequencer << WAVEFORM_CLICK_EFFECT_SEQ << std::endl; - timeMS = mClickDuration; - break; - case Effect::DOUBLE_CLICK: - mHwApi.sequencer << WAVEFORM_DOUBLE_CLICK_EFFECT_SEQ << std::endl; - timeMS = WAVEFORM_DOUBLE_CLICK_EFFECT_MS; - break; - case Effect::TICK: - mHwApi.sequencer << WAVEFORM_TICK_EFFECT_SEQ << std::endl; - timeMS = mTickDuration; - break; - case Effect::HEAVY_CLICK: - mHwApi.sequencer << WAVEFORM_HEAVY_CLICK_EFFECT_SEQ << std::endl; - timeMS = mHeavyClickDuration; - break; - default: - _hidl_cb(Status::UNSUPPORTED_OPERATION, 0); - return Void(); - } - mHwApi.scale << convertEffectStrength(strength) << std::endl; - on(timeMS, true /* isWaveform */); - _hidl_cb(status, timeMS); - return Void(); -} - -} // namespace implementation -} // namespace V1_2 -} // namespace vibrator -} // namespace hardware -} // namespace android diff --git a/vibrator/Vibrator.h b/vibrator/Vibrator.h deleted file mode 100644 index 08635cf3..00000000 --- a/vibrator/Vibrator.h +++ /dev/null @@ -1,84 +0,0 @@ -/* - * Copyright (C) 2017 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. - */ -#ifndef ANDROID_HARDWARE_VIBRATOR_V1_2_VIBRATOR_H -#define ANDROID_HARDWARE_VIBRATOR_V1_2_VIBRATOR_H - -#include <android/hardware/vibrator/1.2/IVibrator.h> -#include <hidl/Status.h> - -#include <fstream> - -namespace android { -namespace hardware { -namespace vibrator { -namespace V1_2 { -namespace implementation { - -class Vibrator : public IVibrator { - public: - typedef struct { - std::ofstream activate; - std::ofstream ctrlLoop; - std::ofstream duration; - std::ofstream lpTriggerEffect; - std::ofstream lraWaveShape; - std::ofstream mode; - std::ofstream odClamp; - std::ofstream olLraPeriod; - std::ofstream rtpInput; - std::ofstream scale; - std::ofstream sequencer; - std::ofstream state; - } HwApi; - - public: - Vibrator(HwApi &&hwapi, std::uint32_t short_lra_period, std::uint32_t long_lra_period); - - // Methods from ::android::hardware::vibrator::V1_0::IVibrator follow. - using Status = ::android::hardware::vibrator::V1_0::Status; - Return<Status> on(uint32_t timeoutMs) override; - Return<Status> off() override; - Return<bool> supportsAmplitudeControl() override; - Return<Status> setAmplitude(uint8_t amplitude) override; - - using EffectStrength = ::android::hardware::vibrator::V1_0::EffectStrength; - Return<void> perform(V1_0::Effect effect, EffectStrength strength, - perform_cb _hidl_cb) override; - Return<void> perform_1_1(V1_1::Effect_1_1 effect, EffectStrength strength, - perform_cb _hidl_cb) override; - Return<void> perform_1_2(Effect effect, EffectStrength strength, perform_cb _hidl_cb) override; - - private: - Return<Status> on(uint32_t timeoutMs, bool isWaveform); - template <typename T> - Return<void> performWrapper(T effect, EffectStrength strength, perform_cb _hidl_cb); - Return<void> performEffect(Effect effect, EffectStrength strength, perform_cb _hidl_cb); - HwApi mHwApi; - std::uint32_t mShortLraPeriod; - std::uint32_t mLongLraPeriod; - int32_t mClickDuration; - int32_t mTickDuration; - int32_t mHeavyClickDuration; - int32_t mShortVoltageMax; - int32_t mLongVoltageMax; -}; -} // namespace implementation -} // namespace V1_2 -} // namespace vibrator -} // namespace hardware -} // namespace android - -#endif // ANDROID_HARDWARE_VIBRATOR_V1_2_VIBRATOR_H diff --git a/vibrator/android.hardware.vibrator@1.2-service.bonito.rc b/vibrator/android.hardware.vibrator@1.2-service.bonito.rc deleted file mode 100644 index b47bee88..00000000 --- a/vibrator/android.hardware.vibrator@1.2-service.bonito.rc +++ /dev/null @@ -1,4 +0,0 @@ -service vendor.vibrator-1-2 /vendor/bin/hw/android.hardware.vibrator@1.2-service.bonito - class hal - user system - group system diff --git a/vibrator/service.cpp b/vibrator/service.cpp deleted file mode 100644 index b0904206..00000000 --- a/vibrator/service.cpp +++ /dev/null @@ -1,247 +0,0 @@ -/* - * Copyright (C) 2017 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. - */ -#define LOG_TAG "android.hardware.vibrator@1.2-service.bonito" - -#include <android/hardware/vibrator/1.2/IVibrator.h> -#include <cutils/properties.h> -#include <hidl/HidlSupport.h> -#include <hidl/HidlTransportSupport.h> -#include <utils/Errors.h> -#include <utils/StrongPointer.h> - -#include "Vibrator.h" - -using android::hardware::configureRpcThreadpool; -using android::hardware::joinRpcThreadpool; -using android::hardware::vibrator::V1_2::IVibrator; -using android::hardware::vibrator::V1_2::implementation::Vibrator; -using namespace android; - -// Refer to Documentation/ABI/testing/sysfs-class-led-driver-drv2624 -// kernel documentation on the detail usages for ABIs below -static constexpr char ACTIVATE_PATH[] = "/sys/class/leds/vibrator/activate"; -static constexpr char DURATION_PATH[] = "/sys/class/leds/vibrator/duration"; -static constexpr char STATE_PATH[] = "/sys/class/leds/vibrator/state"; -static constexpr char RTP_INPUT_PATH[] = "/sys/class/leds/vibrator/device/rtp_input"; -static constexpr char MODE_PATH[] = "/sys/class/leds/vibrator/device/mode"; -static constexpr char SEQUENCER_PATH[] = "/sys/class/leds/vibrator/device/set_sequencer"; -static constexpr char SCALE_PATH[] = "/sys/class/leds/vibrator/device/scale"; -static constexpr char CTRL_LOOP_PATH[] = "/sys/class/leds/vibrator/device/ctrl_loop"; -static constexpr char LP_TRIGGER_PATH[] = "/sys/class/leds/vibrator/device/lp_trigger_effect"; -static constexpr char LRA_WAVE_SHAPE_PATH[] = "/sys/class/leds/vibrator/device/lra_wave_shape"; -static constexpr char OD_CLAMP_PATH[] = "/sys/class/leds/vibrator/device/od_clamp"; - -// File path to the calibration file -static constexpr char CALIBRATION_FILEPATH[] = "/persist/haptics/drv2624.cal"; - -// Kernel ABIs for updating the calibration data -static constexpr char AUTOCAL_CONFIG[] = "autocal"; -static constexpr char LRA_PERIOD_CONFIG[] = "lra_period"; -static constexpr char AUTOCAL_FILEPATH[] = "/sys/class/leds/vibrator/device/autocal"; -static constexpr char OL_LRA_PERIOD_FILEPATH[] = "/sys/class/leds/vibrator/device/ol_lra_period"; - -// Set a default lra period in case there is no calibration file -static constexpr uint32_t DEFAULT_LRA_PERIOD = 262; -static constexpr uint32_t DEFAULT_FREQUENCY_SHIFT = 10; - -static std::uint32_t freqPeriodFormula(std::uint32_t in) { - return 1000000000 / (24615 * in); -} - -static std::string trim(const std::string &str, const std::string &whitespace = " \t") { - const auto str_begin = str.find_first_not_of(whitespace); - if (str_begin == std::string::npos) { - return ""; - } - - const auto str_end = str.find_last_not_of(whitespace); - const auto str_range = str_end - str_begin + 1; - - return str.substr(str_begin, str_range); -} - -static bool loadCalibrationData(std::uint32_t &short_lra_period, std::uint32_t &long_lra_period) { - std::map<std::string, std::string> config_data; - - std::ofstream autocal{AUTOCAL_FILEPATH}; - if (!autocal) { - int error = errno; - ALOGE("Failed to open %s (%d): %s", AUTOCAL_FILEPATH, error, strerror(error)); - return false; - } - - std::ofstream ol_lra_period{OL_LRA_PERIOD_FILEPATH}; - if (!ol_lra_period) { - int error = errno; - ALOGE("Failed to open %s (%d): %s", OL_LRA_PERIOD_FILEPATH, error, strerror(error)); - return false; - } - - std::ifstream cal_data{CALIBRATION_FILEPATH}; - if (!cal_data) { - int error = errno; - ALOGE("Failed to open %s (%d): %s", CALIBRATION_FILEPATH, error, strerror(error)); - return false; - } - - std::string line; - - while (std::getline(cal_data, line)) { - if (line.empty() || line[0] == '#') { - continue; - } - std::istringstream is_line(line); - std::string key; - if (std::getline(is_line, key, ':')) { - std::string value; - - if (std::getline(is_line, value)) { - config_data[trim(key)] = trim(value); - } - } - } - - if (config_data.find(AUTOCAL_CONFIG) != config_data.end()) { - autocal << config_data[AUTOCAL_CONFIG] << std::endl; - } - - if (config_data.find(LRA_PERIOD_CONFIG) != config_data.end()) { - uint32_t thisFrequency; - uint32_t thisPeriod; - ol_lra_period << config_data[LRA_PERIOD_CONFIG] << std::endl; - thisPeriod = std::stoul(config_data[LRA_PERIOD_CONFIG]); - short_lra_period = thisPeriod; - // 1. Change long lra period to frequency - // 2. Get frequency': subtract the frequency shift from the frequency - // 3. Get final long lra period after put the frequency' to formula - thisFrequency = - freqPeriodFormula(thisPeriod) - - property_get_int32("ro.vibrator.hal.long.frequency.shift", DEFAULT_FREQUENCY_SHIFT); - long_lra_period = freqPeriodFormula(thisFrequency); - } - - return true; -} - -status_t registerVibratorService() { - // Calibration data: lra period 262(i.e. 155Hz) - std::uint32_t short_lra_period(DEFAULT_LRA_PERIOD); - std::uint32_t long_lra_period(DEFAULT_LRA_PERIOD); - Vibrator::HwApi hwapi; - - // ostreams below are required - hwapi.activate.open(ACTIVATE_PATH); - if (!hwapi.activate) { - int error = errno; - ALOGE("Failed to open %s (%d): %s", ACTIVATE_PATH, error, strerror(error)); - return -error; - } - - hwapi.duration.open(DURATION_PATH); - if (!hwapi.duration) { - int error = errno; - ALOGE("Failed to open %s (%d): %s", DURATION_PATH, error, strerror(error)); - return -error; - } - - hwapi.state.open(STATE_PATH); - if (!hwapi.state) { - int error = errno; - ALOGE("Failed to open %s (%d): %s", STATE_PATH, error, strerror(error)); - return -error; - } - - hwapi.state << 1 << std::endl; - if (!hwapi.state) { - int error = errno; - ALOGE("Failed to set state (%d): %s", errno, strerror(errno)); - return -error; - } - - // ostreams below are optional - hwapi.rtpInput.open(RTP_INPUT_PATH); - if (!hwapi.rtpInput) { - int error = errno; - ALOGW("Failed to open %s (%d): %s", RTP_INPUT_PATH, error, strerror(error)); - } - - hwapi.mode.open(MODE_PATH); - if (!hwapi.mode) { - int error = errno; - ALOGW("Failed to open %s (%d): %s", MODE_PATH, error, strerror(error)); - } - - hwapi.sequencer.open(SEQUENCER_PATH); - if (!hwapi.sequencer) { - int error = errno; - ALOGW("Failed to open %s (%d): %s", SEQUENCER_PATH, error, strerror(error)); - } - - hwapi.scale.open(SCALE_PATH); - if (!hwapi.scale) { - int error = errno; - ALOGW("Failed to open %s (%d): %s", SCALE_PATH, error, strerror(error)); - } - - hwapi.ctrlLoop.open(CTRL_LOOP_PATH); - if (!hwapi.ctrlLoop) { - int error = errno; - ALOGW("Failed to open %s (%d): %s", CTRL_LOOP_PATH, error, strerror(error)); - } - - hwapi.lpTriggerEffect.open(LP_TRIGGER_PATH); - if (!hwapi.lpTriggerEffect) { - int error = errno; - ALOGW("Failed to open %s (%d): %s", LP_TRIGGER_PATH, error, strerror(error)); - } - - hwapi.lraWaveShape.open(LRA_WAVE_SHAPE_PATH); - if (!hwapi.lraWaveShape) { - int error = errno; - ALOGW("Failed to open %s (%d): %s", LRA_WAVE_SHAPE_PATH, error, strerror(error)); - } - - hwapi.odClamp.open(OD_CLAMP_PATH); - if (!hwapi.odClamp) { - int error = errno; - ALOGW("Failed to open %s (%d): %s", OD_CLAMP_PATH, error, strerror(error)); - } - - hwapi.olLraPeriod.open(OL_LRA_PERIOD_FILEPATH); - if (!hwapi.olLraPeriod) { - int error = errno; - ALOGW("Failed to open %s (%d): %s", OL_LRA_PERIOD_FILEPATH, error, strerror(error)); - } - - if (!loadCalibrationData(short_lra_period, long_lra_period)) { - ALOGW("Failed load calibration data"); - } - - sp<IVibrator> vibrator = new Vibrator(std::move(hwapi), short_lra_period, long_lra_period); - - return vibrator->registerAsService(); -} - -int main() { - configureRpcThreadpool(1, true); - status_t status = registerVibratorService(); - - if (status != OK) { - return status; - } - - joinRpcThreadpool(); -} diff --git a/vr/Android.bp b/vr/Android.bp deleted file mode 100644 index 952338ee..00000000 --- a/vr/Android.bp +++ /dev/null @@ -1,30 +0,0 @@ -// -// Copyright (C) 2017 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. -cc_binary { - name: "android.hardware.vr@1.0-service.bonito", - relative_install_path: "hw", - init_rc: ["android.hardware.vr@1.0-service.bonito.rc"], - srcs: ["service.cpp", "VrDevice.cpp"], - cflags: ["-Werror", "-Wall"], - shared_libs: [ - "libbase", - "libhidlbase", - "libhidltransport", - "liblog", - "libutils", - "android.hardware.vr@1.0", - ], - proprietary: true, -} diff --git a/vr/NOTICE b/vr/NOTICE deleted file mode 100644 index 667db97b..00000000 --- a/vr/NOTICE +++ /dev/null @@ -1,10 +0,0 @@ -Copyright (C) 2017 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. - -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. diff --git a/vr/VrDevice.cpp b/vr/VrDevice.cpp deleted file mode 100644 index dc8f3d78..00000000 --- a/vr/VrDevice.cpp +++ /dev/null @@ -1,72 +0,0 @@ -/* - * Copyright (C) 2017 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. - */ - -#define LOG_TAG "VrDevice" - -#include <android-base/file.h> -#include <android-base/logging.h> -#include <android-base/properties.h> -#include <android-base/stringprintf.h> - -#include "VrDevice.h" - -namespace android { -namespace hardware { -namespace vr { -namespace V1_0 { -namespace implementation { - -VrDevice::VrDevice() : mVRmode(false) {} - -Return<void> VrDevice::init() { - // NOOP - return Void(); -} - -Return<void> VrDevice::setVrMode(bool enabled) { - std::string hwProp = android::base::GetProperty("ro.hardware", "default"); - std::string vrMode = enabled ? "-vr" : ""; - std::string thermalConf = "/vendor/etc/thermal-engine-" + hwProp + vrMode + ".conf"; - mVRmode = enabled; - - if (!android::base::SetProperty("vendor.sys.qcom.thermalcfg", thermalConf)) { - LOG(ERROR) << "Couldn't set vendor.sys.qcom.thermalcfg to " << thermalConf; - return Void(); - } - if (!android::base::SetProperty("ctl.restart", "vendor.thermal-engine")) { - LOG(ERROR) << "Couldn't set thermal_engine restart property"; - } - return Void(); -} - -Return<void> VrDevice::debug(const hidl_handle& handle, const hidl_vec<hidl_string>&) { - if (handle != nullptr && handle->numFds >= 1) { - int fd = handle->data[0]; - std::string buf(android::base::StringPrintf("VRMode: %s\n", - (mVRmode ? "true" : "false"))); - if (!android::base::WriteStringToFd(buf, fd)) { - PLOG(ERROR) << "Failed to dump state to fd"; - } - fsync(fd); - } - return Void(); -} - -} // namespace implementation -} // namespace V1_0 -} // namespace vr -} // namespace hardware -} // namespace android diff --git a/vr/VrDevice.h b/vr/VrDevice.h deleted file mode 100644 index f5f12105..00000000 --- a/vr/VrDevice.h +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Copyright (C) 2017 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. - */ -#ifndef ANDROID_HARDWARE_VR_V1_0_VR_H -#define ANDROID_HARDWARE_VR_V1_0_VR_H - -#include <android/hardware/vr/1.0/IVr.h> - -namespace android { -namespace hardware { -namespace vr { -namespace V1_0 { -namespace implementation { - -using ::android::hardware::vr::V1_0::IVr; -using ::android::hardware::Return; - -class VrDevice : public IVr { - public: - VrDevice(); - - Return<void> init() override; - Return<void> setVrMode(bool enabled) override; - Return<void> debug(const hidl_handle& handle, const hidl_vec<hidl_string>&) override; - - private: - bool mVRmode; -}; - -} // namespace implementation -} // namespace V1_0 -} // namespace vr -} // namespace hardware -} // namespace android - -#endif // ANDROID_HARDWARE_VR_V1_0_VR_H diff --git a/vr/android.hardware.vr@1.0-service.bonito.rc b/vr/android.hardware.vr@1.0-service.bonito.rc deleted file mode 100644 index c5460212..00000000 --- a/vr/android.hardware.vr@1.0-service.bonito.rc +++ /dev/null @@ -1,9 +0,0 @@ -service vendor.vr-bonito-1-0 /vendor/bin/hw/android.hardware.vr@1.0-service.bonito - class hal - user system - group system - -# reset thermal-engine when framework died and thermal-engine is in VR mode -on property:init.svc.zygote=restarting && property:vendor.sys.qcom.thermalcfg=/vendor/etc/thermal-engine-${ro.hardware}-vr.conf - setprop vendor.sys.qcom.thermalcfg /vendor/etc/thermal-engine-${ro.hardware}.conf - restart vendor.thermal-engine diff --git a/vr/service.cpp b/vr/service.cpp deleted file mode 100644 index 1ff9cdf4..00000000 --- a/vr/service.cpp +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (C) 2017 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. - */ -#define LOG_TAG "android.hardware.vr@1.0-service.bonito" - -#include <android-base/logging.h> -#include <hidl/HidlSupport.h> -#include <hidl/HidlTransportSupport.h> -#include <utils/StrongPointer.h> - -#include "VrDevice.h" - -using ::android::hardware::configureRpcThreadpool; -using ::android::hardware::joinRpcThreadpool; -using ::android::hardware::vr::V1_0::implementation::VrDevice; -using ::android::hardware::vr::V1_0::IVr; -using ::android::sp; - -int main(int /* argc */, char* /* argv */ []) { - sp<IVr> vr = new VrDevice; - configureRpcThreadpool(1, true); - CHECK_EQ(vr->registerAsService(), android::NO_ERROR) - << "Failed to register vr HAL"; - joinRpcThreadpool(); - return 0; -} diff --git a/wpa_supplicant_overlay.conf b/wpa_supplicant_overlay.conf index 3ac13d10..e63a4bb2 100644 --- a/wpa_supplicant_overlay.conf +++ b/wpa_supplicant_overlay.conf @@ -4,3 +4,4 @@ tdls_external_control=1 wowlan_triggers=magic_pkt bss_max_count=512 bss_no_flush_when_down=1 +driver_param=use_p2p_group_interface=1 |