1# 2# Copyright (C) 2021 The Android Open-Source Project 3# 4# Licensed under the Apache License, Version 2.0 (the "License"); 5# you may not use this file except in compliance with the License. 6# You may obtain a copy of the License at 7# 8# http://www.apache.org/licenses/LICENSE-2.0 9# 10# Unless required by applicable law or agreed to in writing, software 11# distributed under the License is distributed on an "AS IS" BASIS, 12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13# See the License for the specific language governing permissions and 14# limitations under the License. 15# 16 17TARGET_KERNEL_DIR ?= device/google/pantah-kernel 18TARGET_BOARD_KERNEL_HEADERS := device/google/pantah-kernel/kernel-headers 19 20$(call inherit-product-if-exists, vendor/google_devices/pantah/prebuilts/device-vendor-cheetah.mk) 21$(call inherit-product-if-exists, vendor/google_devices/gs201/prebuilts/device-vendor.mk) 22$(call inherit-product-if-exists, vendor/google_devices/gs201/proprietary/device-vendor.mk) 23$(call inherit-product-if-exists, vendor/google_devices/pantah/proprietary/cheetah/device-vendor-cheetah.mk) 24$(call inherit-product-if-exists, vendor/google_devices/cheetah/proprietary/device-vendor.mk) 25$(call inherit-product-if-exists, vendor/google_devices/pantah/proprietary/WallpapersCheetah.mk) 26 27DEVICE_PACKAGE_OVERLAYS += device/google/pantah/cheetah/overlay 28 29include device/google/pantah/audio/cheetah/audio-tables.mk 30include device/google/gs201/device-shipping-common.mk 31include hardware/google/pixel/vibrator/cs40l26/device.mk 32include device/google/gs101/bluetooth/bluetooth.mk 33 34DEVICE_PRODUCT_COMPATIBILITY_MATRIX_FILE += device/google/pantah/device_framework_matrix_product.xml 35ifeq ($(filter factory_cheetah, $(TARGET_PRODUCT)),) 36include device/google/pantah/uwb/uwb_calibration.mk 37endif 38 39# go/lyric-soong-variables 40$(call soong_config_set,lyric,camera_hardware,cheetah) 41$(call soong_config_set,lyric,tuning_product,cheetah) 42$(call soong_config_set,google3a_config,target_device,cheetah) 43 44PRODUCT_DEFAULT_PROPERTY_OVERRIDES += ro.surface_flinger.support_kernel_idle_timer=true 45PRODUCT_DEFAULT_PROPERTY_OVERRIDES += ro.surface_flinger.ignore_hdr_camera_layers=true 46 47# Init files 48PRODUCT_COPY_FILES += \ 49 device/google/pantah/conf/init.pantah.rc:$(TARGET_COPY_OUT_VENDOR)/etc/init/hw/init.pantah.rc \ 50 device/google/pantah/conf/init.cheetah.rc:$(TARGET_COPY_OUT_VENDOR)/etc/init/hw/init.cheetah.rc 51 52# Recovery files 53PRODUCT_COPY_FILES += \ 54 device/google/pantah/conf/init.recovery.device.rc:$(TARGET_COPY_OUT_RECOVERY)/root/init.recovery.cheetah.rc 55 56# insmod files 57PRODUCT_COPY_FILES += \ 58 device/google/pantah/init.insmod.cheetah.cfg:$(TARGET_COPY_OUT_VENDOR)/etc/init.insmod.cheetah.cfg 59 60# MIPI Coex Configs 61PRODUCT_COPY_FILES += \ 62 device/google/pantah/cheetah/radio/cheetah_display_primary_osc_coex_table.csv:$(TARGET_COPY_OUT_VENDOR)/etc/modem/display_primary_osc_coex_table.csv \ 63 device/google/pantah/cheetah/radio/cheetah_camera_rear_tele_mipi_coex_table.csv:$(TARGET_COPY_OUT_VENDOR)/etc/modem/camera_rear_tele_mipi_coex_table.csv \ 64 device/google/pantah/cheetah/radio/cheetah_camera_front_mipi_coex_table.csv:$(TARGET_COPY_OUT_VENDOR)/etc/modem/camera_front_mipi_coex_table.csv \ 65 device/google/pantah/cheetah/radio/cheetah_camera_front_dbr_coex_table.csv:$(TARGET_COPY_OUT_VENDOR)/etc/modem/camera_front_dbr_coex_table.csv 66 67# Camera 68PRODUCT_COPY_FILES += \ 69 device/google/pantah/media_profiles_cheetah.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_profiles_V1_0.xml 70 71# Media Performance Class 13 72PRODUCT_PROPERTY_OVERRIDES += ro.odm.build.media_performance_class=33 73 74# Display Config 75PRODUCT_COPY_FILES += \ 76 device/google/pantah/cheetah/display_colordata_dev_cal0.pb:$(TARGET_COPY_OUT_VENDOR)/etc/display_colordata_dev_cal0.pb \ 77 device/google/pantah/cheetah/display_colordata_boe-nt37290_cal0.pb:$(TARGET_COPY_OUT_VENDOR)/etc/display_colordata_boe-nt37290_cal0.pb \ 78 device/google/pantah/cheetah/display_colordata_sdc-s6e3hc3-c10_cal0.pb:$(TARGET_COPY_OUT_VENDOR)/etc/display_colordata_sdc-s6e3hc3-c10_cal0.pb \ 79 device/google/pantah/cheetah/display_colordata_sdc-s6e3hc4_cal0.pb:$(TARGET_COPY_OUT_VENDOR)/etc/display_colordata_sdc-s6e3hc4_cal0.pb \ 80 device/google/pantah/cheetah/display_golden_boe-nt37290_cal0.pb:$(TARGET_COPY_OUT_VENDOR)/etc/display_golden_boe-nt37290_cal0.pb \ 81 device/google/pantah/cheetah/display_golden_sdc-s6e3hc4_cal0.pb:$(TARGET_COPY_OUT_VENDOR)/etc/display_golden_sdc-s6e3hc4_cal0.pb 82 83# Display LBE 84PRODUCT_DEFAULT_PROPERTY_OVERRIDES += vendor.display.lbe.supported=1 85 86# config of display brightness dimming 87PRODUCT_DEFAULT_PROPERTY_OVERRIDES += vendor.display.0.brightness.dimming.usage=1 88 89# config of primary display frames to reach LHBM peak brightness 90PRODUCT_DEFAULT_PROPERTY_OVERRIDES += vendor.primarydisplay.lhbm.frames_to_reach_peak_brightness=2 91 92# Display RRS default Config 93PRODUCT_DEFAULT_PROPERTY_OVERRIDES += persist.vendor.display.primary.boot_config=1080x2340@120 94# TODO: b/250788756 - the property will be phased out after HWC loads user-preferred mode 95PRODUCT_DEFAULT_PROPERTY_OVERRIDES += vendor.display.preferred_mode=1080x2340@120 96 97# NFC 98PRODUCT_COPY_FILES += \ 99 frameworks/native/data/etc/android.hardware.nfc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.xml \ 100 frameworks/native/data/etc/android.hardware.nfc.hce.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hce.xml \ 101 frameworks/native/data/etc/android.hardware.nfc.hcef.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hcef.xml \ 102 frameworks/native/data/etc/com.nxp.mifare.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/com.nxp.mifare.xml \ 103 frameworks/native/data/etc/android.hardware.nfc.ese.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.ese.xml \ 104 device/google/pantah/nfc/libnfc-hal-st-proto1.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-hal-st-proto1.conf \ 105 device/google/pantah/nfc/libnfc-nci-cheetah.conf:$(TARGET_COPY_OUT_PRODUCT)/etc/libnfc-nci.conf 106 107ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) 108PRODUCT_COPY_FILES += \ 109 device/google/pantah/nfc/libnfc-hal-st-debug.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-hal-st.conf 110else 111PRODUCT_COPY_FILES += \ 112 device/google/pantah/nfc/libnfc-hal-st.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-hal-st.conf 113endif 114 115PRODUCT_PACKAGES += \ 116 NfcNci \ 117 Tag \ 118 android.hardware.nfc-service.st 119 120# SecureElement 121PRODUCT_PACKAGES += \ 122 android.hardware.secure_element@1.2-service-gto \ 123 android.hardware.secure_element@1.2-service-gto-ese2 124 125PRODUCT_COPY_FILES += \ 126 frameworks/native/data/etc/android.hardware.se.omapi.ese.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.ese.xml \ 127 frameworks/native/data/etc/android.hardware.se.omapi.uicc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.uicc.xml \ 128 device/google/pantah/nfc/libse-gto-hal.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libse-gto-hal.conf \ 129 device/google/pantah/nfc/libse-gto-hal2.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libse-gto-hal2.conf 130 131DEVICE_MANIFEST_FILE += \ 132 device/google/pantah/nfc/manifest_se.xml 133 134# Thermal Config 135PRODUCT_COPY_FILES += \ 136 device/google/pantah/thermal_info_config_cheetah.json:$(TARGET_COPY_OUT_VENDOR)/etc/thermal_info_config.json \ 137 device/google/pantah/thermal_info_config_charge_cheetah.json:$(TARGET_COPY_OUT_VENDOR)/etc/thermal_info_config_charge.json \ 138 device/google/pantah/thermal_info_config_proto.json:$(TARGET_COPY_OUT_VENDOR)/etc/thermal_info_config_proto.json 139 140# Power HAL config 141PRODUCT_COPY_FILES += \ 142 device/google/pantah/powerhint-cheetah.json:$(TARGET_COPY_OUT_VENDOR)/etc/powerhint.json 143PRODUCT_COPY_FILES += \ 144 device/google/pantah/powerhint-cheetah-a0.json:$(TARGET_COPY_OUT_VENDOR)/etc/powerhint-a0.json 145 146# Bluetooth HAL 147DEVICE_MANIFEST_FILE += \ 148 device/google/pantah/bluetooth/manifest_bluetooth.xml 149PRODUCT_SOONG_NAMESPACES += \ 150 vendor/broadcom/bluetooth 151PRODUCT_PACKAGES += \ 152 android.hardware.bluetooth@1.1-service.bcmbtlinux \ 153 bt_vendor.conf 154PRODUCT_COPY_FILES += \ 155 device/google/pantah/bluetooth/bt_vendor_overlay.conf:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth/bt_vendor_overlay.conf 156PRODUCT_PROPERTY_OVERRIDES += \ 157 ro.bluetooth.a2dp_offload.supported=true \ 158 persist.bluetooth.a2dp_offload.disabled=false \ 159 persist.bluetooth.a2dp_offload.cap=sbc-aac-aptx-aptxhd-ldac-opus 160 161# Spatial Audio 162PRODUCT_PACKAGES += \ 163 libspatialaudio 164 165# Bluetooth hci_inject test tool 166PRODUCT_PACKAGES_DEBUG += \ 167 hci_inject 168 169# Bluetooth OPUS codec 170PRODUCT_PRODUCT_PROPERTIES += \ 171 persist.bluetooth.opus.enabled=true 172 173# Bluetooth Tx power caps 174PRODUCT_COPY_FILES += \ 175 $(LOCAL_PATH)/bluetooth/bluetooth_power_limits_cheetah.csv:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_power_limits.csv \ 176 $(LOCAL_PATH)/bluetooth/bluetooth_power_limits_cheetah_GFE4J_JP.csv:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_power_limits_GFE4J_JP.csv \ 177 $(LOCAL_PATH)/bluetooth/bluetooth_power_limits_cheetah_GP4BC_CA.csv:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_power_limits_GP4BC_CA.csv \ 178 $(LOCAL_PATH)/bluetooth/bluetooth_power_limits_cheetah_GE2AE_EU.csv:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_power_limits_GE2AE_EU.csv \ 179 $(LOCAL_PATH)/bluetooth/bluetooth_power_limits_cheetah_GP4BC_EU.csv:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_power_limits_GP4BC_EU.csv \ 180 $(LOCAL_PATH)/bluetooth/bluetooth_power_limits_cheetah_GE2AE_US.csv:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_power_limits_GE2AE_US.csv \ 181 $(LOCAL_PATH)/bluetooth/bluetooth_power_limits_cheetah_GP4BC_US.csv:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_power_limits_GP4BC_US.csv 182 183# Bluetooth SAR test tool 184PRODUCT_PACKAGES_DEBUG += \ 185 sar_test 186 187# declare use of spatial audio 188PRODUCT_PROPERTY_OVERRIDES += \ 189 ro.audio.spatializer_enabled=true 190 191# optimize spatializer effect 192PRODUCT_PROPERTY_OVERRIDES += \ 193 audio.spatializer.effect.util_clamp_min=300 194 195# Keymaster HAL 196#LOCAL_KEYMASTER_PRODUCT_PACKAGE ?= android.hardware.keymaster@4.1-service 197 198# Gatekeeper HAL 199#LOCAL_GATEKEEPER_PRODUCT_PACKAGE ?= android.hardware.gatekeeper@1.0-service.software 200 201 202# Gatekeeper 203# PRODUCT_PACKAGES += \ 204# android.hardware.gatekeeper@1.0-service.software 205 206# Keymint replaces Keymaster 207# PRODUCT_PACKAGES += \ 208# android.hardware.security.keymint-service 209 210# Keymaster 211#PRODUCT_PACKAGES += \ 212# android.hardware.keymaster@4.0-impl \ 213# android.hardware.keymaster@4.0-service 214 215#PRODUCT_PACKAGES += android.hardware.keymaster@4.0-service.remote 216#PRODUCT_PACKAGES += android.hardware.keymaster@4.1-service.remote 217#LOCAL_KEYMASTER_PRODUCT_PACKAGE := android.hardware.keymaster@4.1-service 218#LOCAL_KEYMASTER_PRODUCT_PACKAGE ?= android.hardware.keymaster@4.1-service 219 220# PRODUCT_PROPERTY_OVERRIDES += \ 221# ro.hardware.keystore_desede=true \ 222# ro.hardware.keystore=software \ 223# ro.hardware.gatekeeper=software 224 225# default BDADDR for EVB only 226PRODUCT_PROPERTY_OVERRIDES += \ 227 ro.vendor.bluetooth.evb_bdaddr="22:22:22:33:44:55" 228 229# PowerStats HAL 230PRODUCT_SOONG_NAMESPACES += \ 231 device/google/pantah/powerstats/cheetah \ 232 device/google/pantah 233 234# Fingerprint HAL 235GOODIX_CONFIG_BUILD_VERSION := g7_trusty 236include device/google/gs101/fingerprint/udfps_common.mk 237ifeq ($(filter factory%, $(TARGET_PRODUCT)),) 238include device/google/gs101/fingerprint/udfps_shipping.mk 239else 240include device/google/gs101/fingerprint/udfps_factory.mk 241endif 242 243# WiFi Overlay 244PRODUCT_PACKAGES += \ 245 WifiOverlay2022_C10 246 247PRODUCT_SOONG_NAMESPACES += device/google/pantah/cheetah/ 248 249# Trusty liboemcrypto.so 250PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts 251 252# Location 253ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) 254 PRODUCT_COPY_FILES += \ 255 device/google/pantah/location/gps.xml.c10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/gps.xml \ 256 device/google/pantah/location/lhd.conf.c10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/lhd.conf \ 257 device/google/pantah/location/scd.conf.c10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/scd.conf 258else 259 PRODUCT_COPY_FILES += \ 260 device/google/pantah/location/gps_user.xml.c10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/gps.xml \ 261 device/google/pantah/location/lhd_user.conf.c10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/lhd.conf \ 262 device/google/pantah/location/scd_user.conf.c10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/scd.conf 263endif 264 265# Set support one-handed mode 266PRODUCT_PRODUCT_PROPERTIES += \ 267 ro.support_one_handed_mode=true 268 269# Set zram size 270PRODUCT_VENDOR_PROPERTIES += \ 271 vendor.zram.size=3g 272 273# Increment the SVN for any official public releases 274PRODUCT_VENDOR_PROPERTIES += \ 275 ro.vendor.build.svn=25 276 277# DCK properties based on target 278PRODUCT_PROPERTY_OVERRIDES += \ 279 ro.gms.dck.eligible_wcc=3 280 281# Set support hide display cutout feature 282PRODUCT_PRODUCT_PROPERTIES += \ 283 ro.support_hide_display_cutout=true 284 285PRODUCT_PACKAGES += \ 286 NoCutoutOverlay \ 287 AvoidAppsInCutoutOverlay 288 289# SKU specific RROs 290PRODUCT_PACKAGES += \ 291 SettingsOverlayGFE4J \ 292 SettingsOverlayGE2AE \ 293 SettingsOverlayGP4BC 294 295# Bluetooth LE Audio 296PRODUCT_PRODUCT_PROPERTIES += \ 297 ro.bluetooth.leaudio_offload.supported=true \ 298 persist.bluetooth.leaudio_offload.disabled=false \ 299 ro.bluetooth.leaudio_switcher.supported=true 300 301# LE Auido Offload Capabilities setting 302PRODUCT_COPY_FILES += \ 303 device/google/pantah/bluetooth/le_audio_codec_capabilities.xml:$(TARGET_COPY_OUT_VENDOR)/etc/le_audio_codec_capabilities.xml 304 305# Bluetooth EWP test tool 306PRODUCT_PACKAGES_DEBUG += \ 307 ewp_tool 308 309# userdebug specific 310ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) 311 PRODUCT_COPY_FILES += \ 312 device/google/gs201/init.hardware.wlc.rc.userdebug:$(TARGET_COPY_OUT_VENDOR)/etc/init/init.wlc.rc 313endif 314 315# Fingerprint HAL 316PRODUCT_VENDOR_PROPERTIES += \ 317 persist.vendor.udfps.als_feed_forward_supported=true \ 318 persist.vendor.udfps.lhbm_controlled_in_hal_supported=true 319 320# Vibrator HAL 321PRODUCT_VENDOR_PROPERTIES += \ 322 ro.vendor.vibrator.hal.chirp.enabled=1 323 324PRODUCT_PRODUCT_PROPERTIES += \ 325 persist.bluetooth.firmware.selection=BCM.hcd 326 327# Bluetooth AAC VBR 328PRODUCT_PRODUCT_PROPERTIES += \ 329 persist.bluetooth.a2dp_aac.vbr_supported=true 330 331# Override BQR mask to enable LE Audio Choppy report, remove BTRT logging 332ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) 333PRODUCT_PRODUCT_PROPERTIES += \ 334 persist.bluetooth.bqr.event_mask=262238 335else 336PRODUCT_PRODUCT_PROPERTIES += \ 337 persist.bluetooth.bqr.event_mask=94 338endif 339 340# Keyboard bottom and side padding in dp for portrait mode and height ratio 341PRODUCT_PRODUCT_PROPERTIES += \ 342 ro.com.google.ime.kb_pad_port_b=8 \ 343 ro.com.google.ime.kb_pad_port_l=11 \ 344 ro.com.google.ime.kb_pad_port_r=11 \ 345 ro.com.google.ime.height_ratio=1.025 346 347# Enable camera exif model/make reporting 348PRODUCT_VENDOR_PROPERTIES += \ 349 persist.vendor.camera.exif_reveal_make_model=true \ 350 persist.vendor.camera.front_720P_always_binning=true 351 352##Audio Vendor property 353PRODUCT_PROPERTY_OVERRIDES += \ 354 persist.vendor.audio.cca.enabled=false 355 356# The default value of this variable is false and should only be set to true when 357# the device allows users to enable the seamless transfer feature. 358PRODUCT_PRODUCT_PROPERTIES += \ 359 euicc.seamless_transfer_enabled_in_non_qs=true 360 361# Device features 362PRODUCT_COPY_FILES += \ 363 frameworks/native/data/etc/handheld_core_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/handheld_core_hardware.xml 364 365# Enable adpf cpu hint session for SurfaceFlinger 366PRODUCT_DEFAULT_PROPERTY_OVERRIDES += \ 367 debug.sf.enable_adpf_cpu_hint=true 368