blob: 69af02a3fbdfb1e08d121f4f4904939da327a93e [file] [log] [blame]
rjw1f884582022-01-06 17:20:42 +08001LOCAL_DIR := $(GET_LOCAL_DIR)
2MODULE := $(LOCAL_DIR)
3
4MODULE_SRCS += \
5 $(LOCAL_DIR)/dcm/dcm.c \
6 $(LOCAL_DIR)/dcm/dcm_ctrl.c \
7 $(LOCAL_DIR)/gpio/mt_gpio.c \
8 $(LOCAL_DIR)/key/mtk_key.c \
9 $(LOCAL_DIR)/pll/pll.c \
10 $(LOCAL_DIR)/spm/spm_mtcmos.c \
11 $(LOCAL_DIR)/trng/mtk_trng.c \
12 $(LOCAL_DIR)/uart/uart.c \
13 $(LOCAL_DIR)/musb/mt_usb.c \
14 $(LOCAL_DIR)/musb/mt_usb_qmu.c \
15 $(LOCAL_DIR)/musb/usb_i2c.c \
16 $(LOCAL_DIR)/musb/phy-a60810.c \
17 $(LOCAL_DIR)/wdt/mtk_wdt.c \
18 $(LOCAL_DIR)/wdt/mtk_drm.c \
19 $(LOCAL_DIR)/pwrap/pwrap.c \
20 $(LOCAL_DIR)/timer/mt_gpt_v4.c \
21 $(LOCAL_DIR)/emi/emi_mpu_v1.c \
22 $(LOCAL_DIR)/i2c/mtk_i2c.c
23
24# GCE
25MODULE_SRCS += $(LOCAL_DIR)/gce/mtk_gce.c
26
27ifeq ("$(PMIC)","MT6389")
28MODULE_SRCS += \
29 $(LOCAL_DIR)/pmic/$(PMIC)/pmic.c \
30 $(LOCAL_DIR)/pmic/$(PMIC)/pmic_initial_setting.c \
31 $(LOCAL_DIR)/pmic/$(PMIC)/mtk_regulator_core.c \
32 $(LOCAL_DIR)/pmic/$(PMIC)/mt6389.c \
33 $(LOCAL_DIR)/clkbuf/clkbuf_ctl.c \
34
35endif
36
37MODULE_DEPS += \
38 lib/bio \
39 lib/cksum \
40 lib/fdt \
41 lib/mempool \
42 lib/partition \
43
44ifeq ($(LK_AS_BL33),0)
45MODULE_SRCS += \
46 $(LOCAL_DIR)/bgr/bgr.c
47
48MODULE_DEPS += \
49 $(LOCAL_DIR)/../../../../dramk_2731
50endif
51
52MODULE_SRCS += \
53 $(LOCAL_DIR)/vefuse/vefuse.c
54
55ifeq ($(ARCH),arm64)
56MODULE_EXTRA_OBJS += $(LOCAL_DIR)/../../../../lk_ext_mod/platform/mt2731/drivers/efuse/arm64/libefuse.o
57endif
58ifeq ($(ARCH),arm)
59MODULE_EXTRA_OBJS += $(LOCAL_DIR)/../../../../lk_ext_mod/platform/mt2731/drivers/efuse/arm/libefuse.o
60endif
61
62ifeq ($(strip $(ENABLE_MODEM_LOAD)),1)
63MODULES += \
64 $(LOCAL_DIR)/md
65endif
66
67ifeq ($(strip $(HSM_OS_SUPPORT)),yes)
68MODULES += \
69 $(LOCAL_DIR)/hsm
70GLOBAL_DEFINES += ENABLE_HSM_CLK
71endif
72
73include make/module.mk
74include $(LOCAL_DIR)/audio/rules.mk