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 17# Restrict the visibility of Android.bp files to improve build analysis time 18$(call inherit-product-if-exists, vendor/google/products/sources_pixel.mk) 19 20TARGET_RECOVERY_DEFAULT_ROTATION := ROTATION_RIGHT 21 22TARGET_LINUX_KERNEL_VERSION := $(RELEASE_KERNEL_FELIX_VERSION) 23# Keeps flexibility for kasan and ufs builds 24TARGET_KERNEL_DIR ?= $(RELEASE_KERNEL_FELIX_DIR) 25TARGET_BOARD_KERNEL_HEADERS ?= $(RELEASE_KERNEL_FELIX_DIR)/kernel-headers 26 27$(call inherit-product-if-exists, vendor/google_devices/felix/prebuilts/device-vendor-felix.mk) 28$(call inherit-product-if-exists, vendor/google_devices/gs201/prebuilts/device-vendor.mk) 29$(call inherit-product-if-exists, vendor/google_devices/gs201/proprietary/device-vendor.mk) 30$(call inherit-product-if-exists, vendor/google_devices/felix/proprietary/felix/device-vendor-felix.mk) 31$(call inherit-product-if-exists, vendor/google_devices/felix/proprietary/device-vendor.mk) 32$(call inherit-product-if-exists, vendor/google_devices/felix/proprietary/WallpapersFelix.mk) 33 34$(call inherit-product, device/google/felix/uwb/uwb_calibration_country.mk) 35 36DEVICE_PACKAGE_OVERLAYS += device/google/felix/felix/overlay 37 38include device/google/felix/audio/felix/audio-tables.mk 39include device/google/gs201/device-shipping-common.mk 40$(call soong_config_set,fp_hal_feature,pixel_product, product_a) 41include device/google/felix/vibrator/cs40l26/device.mk 42include device/google/gs-common/bcmbt/bluetooth.mk 43include device/google/gs-common/display/dump_second_display.mk 44include device/google/gs-common/touch/gti/gti.mk 45include device/google/gs-common/touch/stm/stm6.mk 46ifeq ($(filter factory_felix, $(TARGET_PRODUCT)),) 47include device/google/felix/uwb/uwb_calibration.mk 48endif 49 50# go/lyric-soong-variables 51$(call soong_config_set,lyric,camera_hardware,felix) 52$(call soong_config_set,lyric,tuning_product,felix) 53$(call soong_config_set,google3a_config,target_device,felix) 54 55# Init files 56PRODUCT_COPY_FILES += \ 57 device/google/felix/conf/init.felix.rc:$(TARGET_COPY_OUT_VENDOR)/etc/init/hw/init.felix.rc 58 59# Recovery files 60PRODUCT_COPY_FILES += \ 61 device/google/felix/conf/init.recovery.device.rc:$(TARGET_COPY_OUT_RECOVERY)/root/init.recovery.felix.rc 62 63# insmod files 64PRODUCT_COPY_FILES += \ 65 device/google/felix/init.insmod.felix.cfg:$(TARGET_COPY_OUT_VENDOR)/etc/init.insmod.felix.cfg 66 67# Camera 68PRODUCT_COPY_FILES += \ 69 device/google/felix/media_profiles_felix.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/felix/felix/display_colordata_cal1.pb:$(TARGET_COPY_OUT_VENDOR)/etc/display_colordata_cal1.pb \ 77 device/google/felix/felix/display_colordata_dev_cal1.pb:$(TARGET_COPY_OUT_VENDOR)/etc/display_colordata_dev_cal1.pb \ 78 device/google/felix/felix/display_golden_cal0.pb:$(TARGET_COPY_OUT_VENDOR)/etc/display_golden_cal0.pb \ 79 device/google/felix/felix/display_golden_cal1.pb:$(TARGET_COPY_OUT_VENDOR)/etc/display_golden_cal1.pb 80 81# Display 82PRODUCT_DEFAULT_PROPERTY_OVERRIDES += \ 83 vendor.display.lbe.supported=1 \ 84 vendor.display.async_off.supported=true \ 85 ro.surface_flinger.ignore_hdr_camera_layers=true 86 87#config of display brightness dimming 88PRODUCT_DEFAULT_PROPERTY_OVERRIDES += vendor.display.0.brightness.dimming.usage=1 89PRODUCT_DEFAULT_PROPERTY_OVERRIDES += vendor.display.1.brightness.dimming.usage=2 90 91# Early wake up sysfs path for the secondary display 92PRODUCT_DEFAULT_PROPERTY_OVERRIDES += \ 93 vendor.display.secondary_early_wakeup_node=/sys/devices/platform/1c241000.drmdecon/early_wakeup 94 95# NFC 96PRODUCT_COPY_FILES += \ 97 frameworks/native/data/etc/android.hardware.nfc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.xml \ 98 frameworks/native/data/etc/android.hardware.nfc.hce.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hce.xml \ 99 frameworks/native/data/etc/android.hardware.nfc.hcef.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hcef.xml \ 100 frameworks/native/data/etc/com.nxp.mifare.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/com.nxp.mifare.xml \ 101 frameworks/native/data/etc/android.hardware.nfc.ese.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.ese.xml \ 102 device/google/felix/nfc/libnfc-hal-st.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-hal-st.conf \ 103 device/google/felix/nfc/libnfc-nci-felix.conf:$(TARGET_COPY_OUT_PRODUCT)/etc/libnfc-nci.conf 104 105PRODUCT_PACKAGES += \ 106 $(RELEASE_PACKAGE_NFC_STACK) \ 107 Tag \ 108 android.hardware.nfc-service.st \ 109 NfcOverlayFelix 110 111# SecureElement 112PRODUCT_PACKAGES += \ 113 android.hardware.secure_element@1.2-service-gto \ 114 android.hardware.secure_element@1.2-service-gto-ese2 115 116PRODUCT_COPY_FILES += \ 117 frameworks/native/data/etc/android.hardware.se.omapi.ese.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.ese.xml \ 118 frameworks/native/data/etc/android.hardware.se.omapi.uicc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.uicc.xml \ 119 device/google/felix/nfc/libse-gto-hal.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libse-gto-hal.conf \ 120 device/google/felix/nfc/libse-gto-hal2.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libse-gto-hal2.conf 121 122DEVICE_MANIFEST_FILE += \ 123 device/google/felix/nfc/manifest_se.xml 124 125# Thermal Config 126PRODUCT_COPY_FILES += \ 127 device/google/felix/thermal_info_config_felix.json:$(TARGET_COPY_OUT_VENDOR)/etc/thermal_info_config.json \ 128 device/google/felix/thermal_info_config_proactive_skin_felix.json:$(TARGET_COPY_OUT_VENDOR)/etc/thermal_info_config_proactive_skin.json \ 129 device/google/felix/thermal_info_config_charge_felix.json:$(TARGET_COPY_OUT_VENDOR)/etc/thermal_info_config_charge.json 130 131# Power HAL config 132PRODUCT_COPY_FILES += \ 133 device/google/felix/powerhint.json:$(TARGET_COPY_OUT_VENDOR)/etc/powerhint.json 134 135# Bluetooth HAL 136PRODUCT_COPY_FILES += \ 137 device/google/felix/bluetooth/bt_vendor_overlay.conf:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth/bt_vendor_overlay.conf 138PRODUCT_PROPERTY_OVERRIDES += \ 139 ro.bluetooth.a2dp_offload.supported=true \ 140 persist.bluetooth.a2dp_offload.disabled=false \ 141 persist.bluetooth.a2dp_offload.cap=sbc-aac-aptx-aptxhd-ldac-opus 142 143# Enable Bluetooth AutoOn feature 144PRODUCT_PRODUCT_PROPERTIES += \ 145 bluetooth.server.automatic_turn_on=true 146 147# Bluetooth Tx power caps 148PRODUCT_COPY_FILES += \ 149 device/google/felix/bluetooth/bluetooth_power_limits_felix_US.csv:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_power_limits.csv \ 150 device/google/felix/bluetooth/bluetooth_power_limits_felix_JP.csv:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_power_limits_JP.csv \ 151 device/google/felix/bluetooth/bluetooth_power_limits_felix_EU.csv:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_power_limits_EU.csv \ 152 device/google/felix/bluetooth/bluetooth_power_limits_felix_US.csv:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_power_limits_US.csv 153 154# Spatial Audio 155PRODUCT_PACKAGES += \ 156 libspatialaudio 157 158# optimize spatializer effect 159PRODUCT_PROPERTY_OVERRIDES += \ 160 audio.spatializer.effect.util_clamp_min=300 161 162# declare use of spatial audio 163PRODUCT_PROPERTY_OVERRIDES += \ 164 ro.audio.spatializer_enabled=true \ 165 ro.audio.spatializer_transaural_enabled_default=false \ 166 persist.vendor.audio.spatializer.speaker_enabled=true 167 168# Bluetooth SAR test tool 169PRODUCT_PACKAGES_DEBUG += \ 170 sar_test 171 172# Bluetooth hci_inject test tool 173PRODUCT_PACKAGES_DEBUG += \ 174 hci_inject 175 176# Bluetooth 177PRODUCT_PRODUCT_PROPERTIES += \ 178 persist.bluetooth.a2dp_aac.vbr_supported=true 179 180# default BDADDR for EVB only 181PRODUCT_PROPERTY_OVERRIDES += \ 182 ro.vendor.bluetooth.evb_bdaddr="22:22:22:33:44:55" 183 184# Keymaster HAL 185#LOCAL_KEYMASTER_PRODUCT_PACKAGE ?= android.hardware.keymaster@4.1-service 186 187# Gatekeeper HAL 188#LOCAL_GATEKEEPER_PRODUCT_PACKAGE ?= android.hardware.gatekeeper@1.0-service.software 189 190 191# Gatekeeper 192# PRODUCT_PACKAGES += \ 193# android.hardware.gatekeeper@1.0-service.software 194 195# Keymint replaces Keymaster 196# PRODUCT_PACKAGES += \ 197# android.hardware.security.keymint-service 198 199# Keymaster 200#PRODUCT_PACKAGES += \ 201# android.hardware.keymaster@4.0-impl \ 202# android.hardware.keymaster@4.0-service 203 204#PRODUCT_PACKAGES += android.hardware.keymaster@4.0-service.remote 205#PRODUCT_PACKAGES += android.hardware.keymaster@4.1-service.remote 206#LOCAL_KEYMASTER_PRODUCT_PACKAGE := android.hardware.keymaster@4.1-service 207#LOCAL_KEYMASTER_PRODUCT_PACKAGE ?= android.hardware.keymaster@4.1-service 208 209# PRODUCT_PROPERTY_OVERRIDES += \ 210# ro.hardware.keystore_desede=true \ 211# ro.hardware.keystore=software \ 212# ro.hardware.gatekeeper=software 213 214# PowerStats HAL 215PRODUCT_SOONG_NAMESPACES += \ 216 device/google/felix/powerstats/felix \ 217 device/google/felix 218 219# Increment the SVN for any official public releases 220ifdef RELEASE_SVN_FELIX 221TARGET_SVN ?= $(RELEASE_SVN_FELIX) 222else 223# Set this for older releases that don't use build flag 224TARGET_SVN ?= 54 225endif 226 227PRODUCT_VENDOR_PROPERTIES += \ 228 ro.vendor.build.svn=$(TARGET_SVN) 229 230# Vibrator HAL 231$(call soong_config_set,haptics,kernel_ver,v$(subst .,_,$(TARGET_LINUX_KERNEL_VERSION))) 232PRODUCT_VENDOR_PROPERTIES +=\ 233 ro.vendor.vibrator.hal.long.frequency.shift=0 \ 234 ro.vendor.vibrator.hal.gpio.num=44 \ 235 ro.vendor.vibrator.hal.gpio.shift=2 \ 236 persist.vendor.vibrator.hal.chirp.enabled=0 237ACTUATOR_MODEL := luxshare_ict_lt_xlra1906d 238 239# Fingerprint 240include device/google/gs101/fingerprint/fpc1540/sw42/fpc1540.mk 241FPC_MODULE_TYPE=1542_C 242# Fingerprint config 243include device/google/felix/fingerprint_config.mk 244 245# The default value of this variable is false and should only be set to true when 246# the device allows users to enable the seamless transfer feature. 247PRODUCT_PRODUCT_PROPERTIES += \ 248 euicc.seamless_transfer_enabled_in_non_qs=true 249 250# DCK properties based on target 251PRODUCT_PROPERTY_OVERRIDES += \ 252 ro.gms.dck.eligible_wcc=3 \ 253 ro.gms.dck.se_capability=1 254 255# Graphics 256PRODUCT_DEFAULT_PROPERTY_OVERRIDES += ro.surface_flinger.enable_frame_rate_override=true 257PRODUCT_DEFAULT_PROPERTY_OVERRIDES += debug.sf.set_idle_timer_ms_4619827677550801152=80 258PRODUCT_DEFAULT_PROPERTY_OVERRIDES += debug.sf.support_kernel_idle_timer_4619827677550801152=true 259PRODUCT_DEFAULT_PROPERTY_OVERRIDES += debug.sf.set_idle_timer_ms_4619827677550801153=1000 260PRODUCT_DEFAULT_PROPERTY_OVERRIDES += debug.sf.support_kernel_idle_timer_4619827677550801153=false 261 262# Set zram size 263PRODUCT_VENDOR_PROPERTIES += \ 264 vendor.zram.size=3g 265 266# SKU specific RROs 267PRODUCT_PACKAGES += \ 268 SettingsOverlayG0B96 \ 269 SettingsOverlayG9FPL 270 271# Trusty liboemcrypto.so 272PRODUCT_SOONG_NAMESPACES += vendor/google_devices/felix/prebuilts 273 274# Set zram size 275PRODUCT_VENDOR_PROPERTIES += \ 276 vendor.zram.size=3g 277 278# Set support one-handed mode 279PRODUCT_PRODUCT_PROPERTIES += \ 280 ro.support_one_handed_mode=false 281 282# Hinge angle sensor 283PRODUCT_COPY_FILES += \ 284 frameworks/native/data/etc/android.hardware.sensor.hinge_angle.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.hinge_angle.xml 285 286# Location 287ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) 288 PRODUCT_COPY_FILES += \ 289 device/google/felix/location/gps.xml.f10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/gps.xml \ 290 device/google/felix/location/lhd.conf.f10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/lhd.conf \ 291 device/google/felix/location/scd.conf.f10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/scd.conf 292else 293 PRODUCT_COPY_FILES += \ 294 device/google/felix/location/gps_user.xml.f10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/gps.xml \ 295 device/google/felix/location/lhd_user.conf.f10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/lhd.conf \ 296 device/google/felix/location/scd_user.conf.f10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/scd.conf 297endif 298 299PRODUCT_PACKAGES += \ 300 UwbOverlayF10 \ 301 WifiOverlay2023Mid_F10 302 303# MIPI Coex Configs 304PRODUCT_COPY_FILES += \ 305 device/google/felix/felix/radio/felix_camera_front_inner_mipi_coex_table.csv:$(TARGET_COPY_OUT_VENDOR)/etc/modem/camera_front_inner_mipi_coex_table.csv \ 306 device/google/felix/felix/radio/felix_display_secondary_mipi_coex_table.csv:$(TARGET_COPY_OUT_VENDOR)/etc/modem/display_secondary_mipi_coex_table.csv 307 308PRODUCT_SOONG_NAMESPACES += device/google/felix 309 310DEVICE_PRODUCT_COMPATIBILITY_MATRIX_FILE += device/google/felix/device_framework_matrix_product_felix.xml 311 312# Device features 313PRODUCT_COPY_FILES += \ 314 frameworks/native/data/etc/handheld_core_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/handheld_core_hardware.xml 315 316# Increase thread priority for nodes stop 317PRODUCT_VENDOR_PROPERTIES += \ 318 persist.vendor.camera.increase_thread_priority_nodes_stop=true 319 320##Audio Vendor property 321PRODUCT_PROPERTY_OVERRIDES += \ 322 persist.vendor.audio.cca.enabled=false 323 324# Camera 325PRODUCT_PROPERTY_OVERRIDES += \ 326 persist.vendor.camera.adjust_backend_min_freq_for_1p_front_video_1080p_30fps=1 \ 327 persist.vendor.camera.extended_launch_boost=1 \ 328 persist.vendor.camera.multicam_streaming_boost=1 \ 329 persist.vendor.camera.optimized_tnr_freq=1 \ 330 persist.vendor.camera.raise_buf_allocation_priority=1 \ 331 persist.vendor.camera.start_cpu_throttling_at_moderate_thermal=1 \ 332 camera.enable_landscape_to_portrait=true \ 333 persist.vendor.camera.debug.bypass_csi_link_error=true \ 334 vendor.camera.allow_sensor_binning_aspect_ratio_to_override_itp_output=false \ 335 vendor.camera.support_specific_stream_aspect_ratio=0.75 336 337# Enable camera exif model/make reporting 338PRODUCT_VENDOR_PROPERTIES += \ 339 persist.vendor.camera.exif_reveal_make_model=true 340 341# Enable front camera always binning for 720P or smaller resolution 342PRODUCT_VENDOR_PROPERTIES += \ 343 persist.vendor.camera.front_720P_always_binning=true 344 345# Bluetooth OPUS codec 346PRODUCT_PRODUCT_PROPERTIES += \ 347 persist.bluetooth.opus.enabled=true 348 349# WLC userdebug specific 350ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) 351 PRODUCT_COPY_FILES += \ 352 device/google/gs201/init.hardware.wlc.rc.userdebug:$(TARGET_COPY_OUT_VENDOR)/etc/init/init.wlc.rc 353endif 354 355# Bluetooth LE Audio 356PRODUCT_PRODUCT_PROPERTIES += \ 357 ro.bluetooth.leaudio_offload.supported=true \ 358 persist.bluetooth.leaudio_offload.disabled=false \ 359 ro.bluetooth.leaudio_switcher.supported=true \ 360 bluetooth.profile.bap.unicast.client.enabled=true \ 361 bluetooth.profile.csip.set_coordinator.enabled=true \ 362 bluetooth.profile.hap.client.enabled=true \ 363 bluetooth.profile.mcp.server.enabled=true \ 364 bluetooth.profile.ccp.server.enabled=true \ 365 bluetooth.profile.vcp.controller.enabled=true \ 366 367# Override BQR mask to enable LE Audio Choppy report 368ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) 369PRODUCT_PRODUCT_PROPERTIES += \ 370 persist.bluetooth.bqr.event_mask=262238 371else 372PRODUCT_PRODUCT_PROPERTIES += \ 373 persist.bluetooth.bqr.event_mask=94 374endif 375 376# Bluetooth LE Audio CIS handover to SCO 377# Set the property only if the controller doesn't support CIS and SCO 378# simultaneously. More details in b/242908683. 379PRODUCT_PRODUCT_PROPERTIES += \ 380 persist.bluetooth.leaudio.notify.idle.during.call=true 381 382# BT controller not able to support LE Audio dual mic SWB call 383PRODUCT_PRODUCT_PROPERTIES += \ 384 bluetooth.leaudio.dual_bidirection_swb.supported=false 385 386# LE Audio Offload Capabilities Setting 387PRODUCT_COPY_FILES += \ 388 device/google/felix/bluetooth/le_audio_codec_capabilities.xml:$(TARGET_COPY_OUT_VENDOR)/etc/le_audio_codec_capabilities.xml 389 390# LE Audio Unicast Allowlist 391PRODUCT_PRODUCT_PROPERTIES += \ 392 persist.bluetooth.leaudio.allow_list=SM-R510 393 394# Bluetooth EWP test tool 395PRODUCT_PACKAGES_DEBUG += \ 396 ewp_tool 397 398# Enable DeviceAsWebcam support 399PRODUCT_VENDOR_PROPERTIES += \ 400 ro.usb.uvc.enabled=true 401 402# Quick Start device-specific settings 403PRODUCT_PRODUCT_PROPERTIES += \ 404 ro.quick_start.oem_id=00e0 \ 405 ro.quick_start.device_id=felix 406 407# Set support hide display cutout feature 408PRODUCT_PRODUCT_PROPERTIES += \ 409 ro.support_hide_display_cutout=true 410 411PRODUCT_PACKAGES += \ 412 NoCutoutOverlay \ 413 AvoidAppsInCutoutOverlay 414 415