blob: bd143badaab47365164a6c0c7f450c18fa5fc588 [file] [log] [blame]
Rashed Abdel-Tawab05aded82019-05-17 12:03:57 -07001# Platform names
2MSMNILE := msmnile #SM8150
3MSMSTEPPE := sm6150
4TRINKET := trinket #SM6125
5
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -07006B_FAMILY := msm8226 msm8610 msm8974
7B64_FAMILY := msm8992 msm8994
8BR_FAMILY := msm8909 msm8916
9UM_3_18_FAMILY := msm8937 msm8953 msm8996
10UM_4_4_FAMILY := msm8998 sdm660
Isaac Chen60912cf2018-10-03 15:29:15 +053011UM_4_9_FAMILY := sdm845 sdm710
Rashed Abdel-Tawab05aded82019-05-17 12:03:57 -070012UM_4_14_FAMILY := $(MSMNILE) $(MSMSTEPPE) $(TRINKET)
13UM_PLATFORMS := $(UM_3_18_FAMILY) $(UM_4_4_FAMILY) $(UM_4_9_FAMILY) $(UM_4_14_FAMILY)
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -070014
15BOARD_USES_ADRENO := true
16
17# UM platforms no longer need this set on O+
Ethan Chen66ce59c2019-06-22 13:30:38 -070018ifneq ($(filter $(B_FAMILY) $(B64_FAMILY) $(BR_FAMILY),$(TARGET_BOARD_PLATFORM)),)
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -070019 TARGET_USES_QCOM_BSP := true
20endif
21
22# Tell HALs that we're compiling an AOSP build with an in-line kernel
23TARGET_COMPILE_WITH_MSM_KERNEL := true
24
25ifneq ($(filter msm7x27a msm7x30 msm8660 msm8960,$(TARGET_BOARD_PLATFORM)),)
26 TARGET_USES_QCOM_BSP_LEGACY := true
27 # Enable legacy audio functions
28 ifeq ($(BOARD_USES_LEGACY_ALSA_AUDIO),true)
29 USE_CUSTOM_AUDIO_POLICY := 1
30 endif
31endif
32
33# Enable media extensions
34TARGET_USES_MEDIA_EXTENSIONS := true
35
36# Allow building audio encoders
37TARGET_USES_QCOM_MM_AUDIO := true
38
39# Enable color metadata for every UM platform
Ethan Chen66ce59c2019-06-22 13:30:38 -070040ifneq ($(filter $(UM_PLATFORMS),$(TARGET_BOARD_PLATFORM)),)
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -070041 TARGET_USES_COLOR_METADATA := true
42endif
43
44# Enable DRM PP driver on UM platforms that support it
Bruno Martinsd47d0622019-09-19 15:35:25 +020045ifneq ($(filter $(UM_4_9_FAMILY) $(UM_4_14_FAMILY),$(TARGET_BOARD_PLATFORM)),)
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -070046 TARGET_USES_DRM_PP := true
47endif
48
Han Wang2838e8a2019-09-28 11:23:16 +020049# Mark GRALLOC_USAGE_HW_2D, GRALLOC_USAGE_EXTERNAL_DISP and GRALLOC_USAGE_PRIVATE_WFD as valid gralloc bits
Bruno Martins9717ee72018-12-28 21:34:03 +000050TARGET_ADDITIONAL_GRALLOC_10_USAGE_BITS ?= 0
Han Wang2838e8a2019-09-28 11:23:16 +020051TARGET_ADDITIONAL_GRALLOC_10_USAGE_BITS += | (1 << 10)
52TARGET_ADDITIONAL_GRALLOC_10_USAGE_BITS += | (1 << 13)
Bruno Martins9717ee72018-12-28 21:34:03 +000053TARGET_ADDITIONAL_GRALLOC_10_USAGE_BITS += | (1 << 21)
54
Han Wang2838e8a2019-09-28 11:23:16 +020055# Mark GRALLOC_USAGE_PRIVATE_HEIF_VIDEO as valid gralloc bits on UM platforms that support it
Bruno Martinsd47d0622019-09-19 15:35:25 +020056ifneq ($(filter $(UM_4_9_FAMILY) $(UM_4_14_FAMILY),$(TARGET_BOARD_PLATFORM)),)
Bruno Martins9717ee72018-12-28 21:34:03 +000057 TARGET_ADDITIONAL_GRALLOC_10_USAGE_BITS += | (1 << 27)
58endif
59
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -070060# List of targets that use master side content protection
Rashed Abdel-Tawab05aded82019-05-17 12:03:57 -070061MASTER_SIDE_CP_TARGET_LIST := msm8996 $(UM_4_4_FAMILY) $(UM_4_9_FAMILY) $(UM_4_14_FAMILY)
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -070062
Ethan Chen66ce59c2019-06-22 13:30:38 -070063ifneq ($(filter $(B_FAMILY),$(TARGET_BOARD_PLATFORM)),)
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -070064 MSM_VIDC_TARGET_LIST := $(B_FAMILY)
65 QCOM_HARDWARE_VARIANT := msm8974
Ethan Chen66ce59c2019-06-22 13:30:38 -070066else ifneq ($(filter $(B64_FAMILY),$(TARGET_BOARD_PLATFORM)),)
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -070067 MSM_VIDC_TARGET_LIST := $(B64_FAMILY)
68 QCOM_HARDWARE_VARIANT := msm8994
Ethan Chen66ce59c2019-06-22 13:30:38 -070069else ifneq ($(filter $(BR_FAMILY),$(TARGET_BOARD_PLATFORM)),)
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -070070 MSM_VIDC_TARGET_LIST := $(BR_FAMILY)
71 QCOM_HARDWARE_VARIANT := msm8916
Ethan Chen66ce59c2019-06-22 13:30:38 -070072else ifneq ($(filter $(UM_3_18_FAMILY),$(TARGET_BOARD_PLATFORM)),)
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -070073 MSM_VIDC_TARGET_LIST := $(UM_3_18_FAMILY)
74 QCOM_HARDWARE_VARIANT := msm8996
Ethan Chen66ce59c2019-06-22 13:30:38 -070075else ifneq ($(filter $(UM_4_4_FAMILY),$(TARGET_BOARD_PLATFORM)),)
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -070076 MSM_VIDC_TARGET_LIST := $(UM_4_4_FAMILY)
77 QCOM_HARDWARE_VARIANT := msm8998
Ethan Chen66ce59c2019-06-22 13:30:38 -070078else ifneq ($(filter $(UM_4_9_FAMILY),$(TARGET_BOARD_PLATFORM)),)
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -070079 MSM_VIDC_TARGET_LIST := $(UM_4_9_FAMILY)
80 QCOM_HARDWARE_VARIANT := sdm845
Rashed Abdel-Tawab05aded82019-05-17 12:03:57 -070081else ifneq ($(filter $(UM_4_14_FAMILY),$(TARGET_BOARD_PLATFORM)),)
82 MSM_VIDC_TARGET_LIST := $(UM_4_14_FAMILY)
83 QCOM_HARDWARE_VARIANT := sm8150
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -070084else
85 MSM_VIDC_TARGET_LIST := $(TARGET_BOARD_PLATFORM)
86 QCOM_HARDWARE_VARIANT := $(TARGET_BOARD_PLATFORM)
87endif
Rashed Abdel-Tawabb8ac1422018-08-25 11:10:25 -070088
Rashed Abdel-Tawaba94cf0c2018-08-25 11:17:23 -070089PRODUCT_SOONG_NAMESPACES += \
Rashed Abdel-Tawab84948082019-09-07 23:49:07 -070090 hardware/qcom-caf/$(QCOM_HARDWARE_VARIANT)