blob: 03d0b962de0effbaab2a4a675c0c473245aeda54 [file] [log] [blame]
Dmitry Shmidt64185fa2017-07-28 15:08:55 -07001ifndef TARGET_KERNEL_USE
John Stultz5d031842020-06-05 06:17:12 +00002TARGET_KERNEL_USE=5.4
Dmitry Shmidt64185fa2017-07-28 15:08:55 -07003endif
Yongqin Liuaa064df2020-11-24 16:07:20 +08004LOCAL_KERNEL_HOME ?= device/linaro/hikey-kernel/hikey960/$(TARGET_KERNEL_USE)
5TARGET_PREBUILT_KERNEL := $(LOCAL_KERNEL_HOME)/Image.gz-dtb
6TARGET_PREBUILT_DTB := $(LOCAL_KERNEL_HOME)/hi3660-hikey960.dtb
Dmitry Shmidt64185fa2017-07-28 15:08:55 -07007
John Stultz75f00f92017-08-01 12:32:05 -07008ifeq ($(TARGET_KERNEL_USE), 4.4)
John Stultz6dc5ce52017-11-01 18:58:15 -07009 HIKEY_USE_DRM_HWCOMPOSER := false
John Stultz75f00f92017-08-01 12:32:05 -070010 HIKEY_USE_LEGACY_TI_BLUETOOTH := true
11else
John Stultz6dc5ce52017-11-01 18:58:15 -070012 ifeq ($(TARGET_KERNEL_USE), 4.9)
13 HIKEY_USE_DRM_HWCOMPOSER := false
14 else
15 HIKEY_USE_DRM_HWCOMPOSER := true
16 endif
John Stultz75f00f92017-08-01 12:32:05 -070017 HIKEY_USE_LEGACY_TI_BLUETOOTH := false
18endif
John Stultzd497f632017-05-30 23:51:33 -070019
John Stultz5d031842020-06-05 06:17:12 +000020ifndef HIKEY_USES_GKI
21 ifeq ($(TARGET_KERNEL_USE), 5.4)
22 HIKEY_USES_GKI := true
23 endif
24endif
25
Dmitry Shmidt5d080802017-04-11 14:20:03 -070026#
Robin Lee81bde6d2020-08-15 22:17:32 +020027# Inherit the common device configuration
Anton Hansson1399b122018-02-08 14:57:45 +000028$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk)
Dmitry Shmidt5d080802017-04-11 14:20:03 -070029$(call inherit-product, device/linaro/hikey/hikey960/device-hikey960.mk)
30$(call inherit-product, device/linaro/hikey/device-common.mk)
Dmitry Shmidt5d080802017-04-11 14:20:03 -070031
Sahaj Sarup93980e02018-09-11 13:24:20 +000032PRODUCT_PROPERTY_OVERRIDES += ro.opengles.version=196608
33
Dmitry Shmidt5d080802017-04-11 14:20:03 -070034#
35# Overrides
36PRODUCT_NAME := hikey960
37PRODUCT_DEVICE := hikey960
38PRODUCT_BRAND := Android
39PRODUCT_MODEL := AOSP on hikey960
John Stultz3d2ce4c2019-06-24 23:57:29 +000040
John Stultz84925462019-07-12 07:04:13 +000041ifneq ($(HIKEY_USES_GKI),)
Yongqin Liuaa064df2020-11-24 16:07:20 +080042 HIKEY_MOD_DIR := $(LOCAL_KERNEL_HOME)
John Stultz84925462019-07-12 07:04:13 +000043 HIKEY_MODS := $(wildcard $(HIKEY_MOD_DIR)/*.ko)
John Stultz9d126402020-09-15 03:26:56 +000044 SDCARDFS_KO := $(wildcard $(HIKEY_MOD_DIR)/sdcardfs*.ko)
Yongqin Liue05046e2020-11-24 21:00:19 +080045 CMA_HEAP_KO := $(wildcard $(HIKEY_MOD_DIR)/cma_heap.ko)
John Stultz4ab665e2021-01-08 04:35:02 +000046 SYSTEM_HEAP_KO := $(wildcard $(HIKEY_MOD_DIR)/system_heap.ko)
Yongqin Liue05046e2020-11-24 21:00:19 +080047 ION_CMA_HEAP_KO := $(wildcard $(HIKEY_MOD_DIR)/ion_cma_heap*.ko)
John Stultz84925462019-07-12 07:04:13 +000048 ifneq ($(HIKEY_MODS),)
49 BOARD_VENDOR_KERNEL_MODULES += $(HIKEY_MODS)
50 BOARD_VENDOR_RAMDISK_KERNEL_MODULES += \
Yongqin Liue05046e2020-11-24 21:00:19 +080051 $(CMA_HEAP_KO) \
John Stultz4ab665e2021-01-08 04:35:02 +000052 $(SYSTEM_HEAP_KO) \
Yongqin Liue05046e2020-11-24 21:00:19 +080053 $(ION_CMA_HEAP_KO) \
54 $(SDCARDFS_KO)
John Stultz84925462019-07-12 07:04:13 +000055 endif
John Stultz3d2ce4c2019-06-24 23:57:29 +000056endif