device-lynx.mk 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319
  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. TARGET_KERNEL_DIR ?= device/google/lynx-kernel
  17. TARGET_BOARD_KERNEL_HEADERS := device/google/lynx-kernel/kernel-headers
  18. ifdef RELEASE_GOOGLE_LYNX_KERNEL_VERSION
  19. TARGET_LINUX_KERNEL_VERSION := $(RELEASE_GOOGLE_LYNX_KERNEL_VERSION)
  20. endif
  21. ifdef RELEASE_GOOGLE_LYNX_KERNEL_DIR
  22. TARGET_KERNEL_DIR := $(RELEASE_GOOGLE_LYNX_KERNEL_DIR)
  23. TARGET_BOARD_KERNEL_HEADERS := $(RELEASE_GOOGLE_LYNX_KERNEL_DIR)/kernel-headers
  24. endif
  25. $(call inherit-product-if-exists, vendor/google_devices/lynx/prebuilts/device-vendor-lynx.mk)
  26. $(call inherit-product-if-exists, vendor/google_devices/gs201/prebuilts/device-vendor.mk)
  27. $(call inherit-product-if-exists, vendor/google_devices/gs201/proprietary/device-vendor.mk)
  28. $(call inherit-product-if-exists, vendor/google_devices/lynx/proprietary/lynx/device-vendor-lynx.mk)
  29. $(call inherit-product-if-exists, vendor/google_devices/lynx/proprietary/device-vendor.mk)
  30. $(call inherit-product-if-exists, vendor/google_devices/lynx/proprietary/WallpapersLynx.mk)
  31. DEVICE_PACKAGE_OVERLAYS += device/google/lynx/lynx/overlay
  32. include device/google/lynx/audio/lynx/audio-tables.mk
  33. include device/google/gs201/device-shipping-common.mk
  34. include hardware/google/pixel/vibrator/cs40l26/device.mk
  35. include device/google/gs-common/touch/gti/gti.mk
  36. include device/google/gs-common/wlan/dump.mk
  37. # go/lyric-soong-variables
  38. $(call soong_config_set,lyric,camera_hardware,lynx)
  39. $(call soong_config_set,lyric,tuning_product,lynx)
  40. $(call soong_config_set,google3a_config,target_device,lynx)
  41. # Init files
  42. PRODUCT_COPY_FILES += \
  43. device/google/lynx/conf/init.lynx.rc:$(TARGET_COPY_OUT_VENDOR)/etc/init/hw/init.lynx.rc
  44. # Recovery files
  45. PRODUCT_COPY_FILES += \
  46. device/google/lynx/conf/init.recovery.device.rc:$(TARGET_COPY_OUT_RECOVERY)/root/init.recovery.lynx.rc
  47. # insmod files
  48. PRODUCT_COPY_FILES += \
  49. device/google/lynx/init.insmod.lynx.cfg:$(TARGET_COPY_OUT_VENDOR)/etc/init.insmod.lynx.cfg
  50. # Camera
  51. PRODUCT_COPY_FILES += \
  52. device/google/lynx/media_profiles_lynx.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_profiles_V1_0.xml
  53. # Media Performance Class 13
  54. PRODUCT_PROPERTY_OVERRIDES += ro.odm.build.media_performance_class=33
  55. # Display Config
  56. PRODUCT_COPY_FILES += \
  57. device/google/lynx/lynx/display_colordata_dev_cal0.pb:$(TARGET_COPY_OUT_VENDOR)/etc/display_colordata_dev_cal0.pb \
  58. device/google/lynx/lynx/display_golden_cal0.pb:$(TARGET_COPY_OUT_VENDOR)/etc/display_golden_cal0.pb
  59. # Display
  60. PRODUCT_DEFAULT_PROPERTY_OVERRIDES += vendor.display.lbe.supported=1
  61. PRODUCT_DEFAULT_PROPERTY_OVERRIDES += ro.surface_flinger.set_idle_timer_ms=1000
  62. PRODUCT_DEFAULT_PROPERTY_OVERRIDES += ro.surface_flinger.ignore_hdr_camera_layers=true
  63. #config of primary display frames to reach LHBM peak brightness
  64. PRODUCT_DEFAULT_PROPERTY_OVERRIDES += vendor.primarydisplay.lhbm.frames_to_reach_peak_brightness=2
  65. # NFC
  66. PRODUCT_COPY_FILES += \
  67. frameworks/native/data/etc/android.hardware.nfc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.xml \
  68. frameworks/native/data/etc/android.hardware.nfc.hce.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hce.xml \
  69. frameworks/native/data/etc/android.hardware.nfc.hcef.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hcef.xml \
  70. frameworks/native/data/etc/com.nxp.mifare.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/com.nxp.mifare.xml \
  71. frameworks/native/data/etc/android.hardware.nfc.ese.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.ese.xml \
  72. device/google/lynx/nfc/libnfc-hal-st.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-hal-st.conf \
  73. device/google/lynx/nfc/libnfc-nci-lynx.conf:$(TARGET_COPY_OUT_PRODUCT)/etc/libnfc-nci.conf
  74. PRODUCT_PACKAGES += \
  75. $(RELEASE_PACKAGE_NFC_STACK) \
  76. Tag \
  77. android.hardware.nfc-service.st \
  78. NfcOverlayLynx
  79. # SecureElement
  80. PRODUCT_PACKAGES += \
  81. [email protected] \
  82. [email protected]
  83. PRODUCT_COPY_FILES += \
  84. frameworks/native/data/etc/android.hardware.se.omapi.ese.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.ese.xml \
  85. frameworks/native/data/etc/android.hardware.se.omapi.uicc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.uicc.xml \
  86. device/google/lynx/nfc/libse-gto-hal.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libse-gto-hal.conf \
  87. device/google/lynx/nfc/libse-gto-hal2.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libse-gto-hal2.conf
  88. DEVICE_MANIFEST_FILE += \
  89. device/google/lynx/nfc/manifest_se.xml
  90. # Thermal Config
  91. PRODUCT_COPY_FILES += \
  92. device/google/lynx/thermal_info_config_lynx.json:$(TARGET_COPY_OUT_VENDOR)/etc/thermal_info_config.json \
  93. device/google/lynx/thermal_info_config_charge_lynx.json:$(TARGET_COPY_OUT_VENDOR)/etc/thermal_info_config_charge.json
  94. # Power HAL config
  95. PRODUCT_COPY_FILES += \
  96. device/google/lynx/powerhint.json:$(TARGET_COPY_OUT_VENDOR)/etc/powerhint.json
  97. # PowerStats HAL
  98. PRODUCT_SOONG_NAMESPACES += \
  99. device/google/lynx/powerstats \
  100. device/google/lynx
  101. # Bluetooth HAL and Pixel extension
  102. include device/google/lynx/bluetooth/qti_default.mk
  103. # Keymaster HAL
  104. #LOCAL_KEYMASTER_PRODUCT_PACKAGE ?= [email protected]
  105. # Gatekeeper HAL
  106. #LOCAL_GATEKEEPER_PRODUCT_PACKAGE ?= [email protected]
  107. # Gatekeeper
  108. # PRODUCT_PACKAGES += \
  109. # [email protected]
  110. # Keymint replaces Keymaster
  111. # PRODUCT_PACKAGES += \
  112. # android.hardware.security.keymint-service
  113. # Keymaster
  114. #PRODUCT_PACKAGES += \
  115. # [email protected] \
  116. # [email protected]
  117. #PRODUCT_PACKAGES += [email protected]
  118. #PRODUCT_PACKAGES += [email protected]
  119. #LOCAL_KEYMASTER_PRODUCT_PACKAGE := [email protected]
  120. #LOCAL_KEYMASTER_PRODUCT_PACKAGE ?= [email protected]
  121. # PRODUCT_PROPERTY_OVERRIDES += \
  122. # ro.hardware.keystore_desede=true \
  123. # ro.hardware.keystore=software \
  124. # ro.hardware.gatekeeper=software
  125. # Fingerprint HAL
  126. GOODIX_CONFIG_BUILD_VERSION := g7_trusty
  127. ifneq (,$(filter AP1%,$(RELEASE_PLATFORM_VERSION)))
  128. PRODUCT_SOONG_NAMESPACES += vendor/google_devices/lynx/prebuilts/firmware/fingerprint/24Q1
  129. else ifneq (,$(filter AP2%,$(RELEASE_PLATFORM_VERSION)))
  130. PRODUCT_SOONG_NAMESPACES += vendor/google_devices/lynx/prebuilts/firmware/fingerprint/24Q2
  131. else
  132. PRODUCT_SOONG_NAMESPACES += vendor/google_devices/lynx/prebuilts/firmware/fingerprint/trunk
  133. endif
  134. $(call inherit-product-if-exists, vendor/goodix/udfps/configuration/udfps_common.mk)
  135. ifeq ($(filter factory%, $(TARGET_PRODUCT)),)
  136. $(call inherit-product-if-exists, vendor/goodix/udfps/configuration/udfps_shipping.mk)
  137. else
  138. $(call inherit-product-if-exists, vendor/goodix/udfps/configuration/udfps_factory.mk)
  139. endif
  140. # Vibrator HAL
  141. ADAPTIVE_HAPTICS_FEATURE := adaptive_haptics_v1
  142. PRODUCT_VENDOR_PROPERTIES += \
  143. ro.vendor.vibrator.hal.supported_primitives=243 \
  144. ro.vendor.vibrator.hal.f0.comp.enabled=1 \
  145. ro.vendor.vibrator.hal.redc.comp.enabled=0 \
  146. persist.vendor.vibrator.hal.context.enable=false \
  147. persist.vendor.vibrator.hal.context.scale=40 \
  148. persist.vendor.vibrator.hal.context.fade=true \
  149. persist.vendor.vibrator.hal.context.cooldowntime=1600 \
  150. persist.vendor.vibrator.hal.context.settlingtime=5000
  151. # Trusty liboemcrypto.so
  152. PRODUCT_SOONG_NAMESPACES += vendor/google_devices/lynx/prebuilts
  153. ifneq (,$(filter AP1%,$(RELEASE_PLATFORM_VERSION)))
  154. PRODUCT_SOONG_NAMESPACES += vendor/google_devices/lynx/prebuilts/trusty/24Q1
  155. else ifneq (,$(filter AP2%,$(RELEASE_PLATFORM_VERSION)))
  156. PRODUCT_SOONG_NAMESPACES += vendor/google_devices/lynx/prebuilts/trusty/24Q2
  157. else
  158. PRODUCT_SOONG_NAMESPACES += vendor/google_devices/lynx/prebuilts/trusty/trunk
  159. endif
  160. # GPS xml
  161. ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
  162. PRODUCT_COPY_FILES += \
  163. device/google/lynx/location/gps.xml.l10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/gps.xml \
  164. device/google/lynx/location/lhd.conf.l10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/lhd.conf \
  165. device/google/lynx/location/scd.conf.l10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/scd.conf
  166. else
  167. PRODUCT_COPY_FILES += \
  168. device/google/lynx/location/gps_user.xml.l10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/gps.xml \
  169. device/google/lynx/location/lhd_user.conf.l10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/lhd.conf \
  170. device/google/lynx/location/scd_user.conf.l10:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/scd.conf
  171. endif
  172. # Wifi HAL
  173. PRODUCT_SOONG_NAMESPACES += hardware/qcom/wlan/wcn6740
  174. # DCK properties based on target
  175. PRODUCT_PROPERTY_OVERRIDES += \
  176. ro.gms.dck.eligible_wcc=2 \
  177. ro.gms.dck.se_capability=1
  178. # WIFI COEX
  179. PRODUCT_COPY_FILES += \
  180. device/google/lynx/wifi/coex_table.xml:$(TARGET_COPY_OUT_VENDOR)/etc/wifi/coex_table.xml
  181. # WiFi Overlay
  182. PRODUCT_PACKAGES += \
  183. WifiOverlay2023Mid
  184. # Wifi Aware Interface
  185. PRODUCT_PROPERTY_OVERRIDES += \
  186. wifi.aware.interface=wifi-aware0
  187. # Set zram size
  188. PRODUCT_VENDOR_PROPERTIES += \
  189. vendor.zram.size=3g
  190. # Increment the SVN for any official public releases
  191. PRODUCT_VENDOR_PROPERTIES += \
  192. ro.vendor.build.svn=34
  193. # Set support hide display cutout feature
  194. PRODUCT_PRODUCT_PROPERTIES += \
  195. ro.support_hide_display_cutout=true
  196. # Set support One-handed mode
  197. PRODUCT_PRODUCT_PROPERTIES += \
  198. ro.support_one_handed_mode=true
  199. # Fingerprint als feed forward
  200. PRODUCT_VENDOR_PROPERTIES += \
  201. persist.vendor.udfps.als_feed_forward_supported=true \
  202. persist.vendor.udfps.lhbm_controlled_in_hal_supported=true
  203. # Hide cutout overlays
  204. PRODUCT_PACKAGES += \
  205. NoCutoutOverlay \
  206. AvoidAppsInCutoutOverlay
  207. # MIPI Coex Configs
  208. PRODUCT_COPY_FILES += \
  209. device/google/lynx/lynx/radio/lynx_display_primary_mipi_coex_table.csv:$(TARGET_COPY_OUT_VENDOR)/etc/modem/display_primary_mipi_coex_table.csv
  210. # Camera
  211. PRODUCT_PROPERTY_OVERRIDES += \
  212. persist.vendor.camera.extended_launch_boost=1 \
  213. persist.vendor.camera.optimized_tnr_freq=1 \
  214. persist.vendor.camera.raise_buf_allocation_priority=1 \
  215. persist.vendor.camera.start_cpu_throttling_at_moderate_thermal=1
  216. # Enable camera 1080P 60FPS binning mode
  217. PRODUCT_VENDOR_PROPERTIES += \
  218. persist.vendor.camera.1080P_60fps_binning=true
  219. # Increase thread priority for nodes stop
  220. PRODUCT_VENDOR_PROPERTIES += \
  221. persist.vendor.camera.increase_thread_priority_nodes_stop=true
  222. # OIS with system imu
  223. PRODUCT_VENDOR_PROPERTIES += \
  224. persist.vendor.camera.ois_with_system_imu=true
  225. # Enable camera exif model/make reporting
  226. PRODUCT_VENDOR_PROPERTIES += \
  227. persist.vendor.camera.exif_reveal_make_model=true
  228. # Enable front camera always binning for 720P or smaller resolution
  229. PRODUCT_VENDOR_PROPERTIES += \
  230. persist.vendor.camera.front_720P_always_binning=true
  231. # Device features
  232. PRODUCT_COPY_FILES += \
  233. frameworks/native/data/etc/handheld_core_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/handheld_core_hardware.xml
  234. # The default value of this variable is false and should only be set to true when
  235. # the device allows users to enable the seamless transfer feature.
  236. PRODUCT_PRODUCT_PROPERTIES += \
  237. euicc.seamless_transfer_enabled_in_non_qs=true
  238. ##Audio Vendor property
  239. PRODUCT_PROPERTY_OVERRIDES += \
  240. persist.vendor.audio.cca.enabled=false
  241. # userdebug specific
  242. ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
  243. PRODUCT_COPY_FILES += \
  244. device/google/gs201/init.hardware.wlc.rc.userdebug:$(TARGET_COPY_OUT_VENDOR)/etc/init/init.wlc.rc
  245. endif
  246. # SKU specific RROs
  247. PRODUCT_PACKAGES += \
  248. SettingsOverlayG82U8 \
  249. SettingsOverlayG0DZQ \
  250. SettingsOverlayGHL1X \
  251. SettingsOverlayGWKK3
  252. # Enable DeviceAsWebcam support
  253. PRODUCT_VENDOR_PROPERTIES += \
  254. ro.usb.uvc.enabled=true
  255. # Quick Start device-specific settings
  256. PRODUCT_PRODUCT_PROPERTIES += \
  257. ro.quick_start.oem_id=00e0 \
  258. ro.quick_start.device_id=lynx