| obj-$(CONFIG_SND_SOC_MEDIATEK) += common/ |
| obj-$(CONFIG_SND_SOC_MT2701) += mt2701/ |
| obj-$(CONFIG_SND_SOC_MT2731) += mt2731/ |
| obj-$(CONFIG_SND_SOC_MT8173) += mt8173/ |
| obj-$(CONFIG_SND_SOC_MT8183) += mt8183/ |
| |
| ifeq ($(CONFIG_SND_SOC_MTK_SMART_PHONE),y) |
| subdir-ccflags-y += -I$(srctree)/drivers/misc/mediatek/include |
| endif |
| # New architecture |
| ifeq ($(CONFIG_MTK_SND_SOC_NEW_ARCH),y) |
| |
| # MTK Platform Support |
| MTK_PLATFORM := $(subst ",,$(CONFIG_MTK_PLATFORM)) |
| |
| # MTK Codec Chip Support |
| # MTK_CODEC := $(subst ",,$(CONFIG_MTK_SND_SOC_CODEC)) |
| |
| # flags for not ready feature, uncomment after ready |
| subdir-ccflags-y += -DAUDIO_USING_WRAP_DRIVER |
| #subdir-ccflags-y += -D_MT_IDLE_HEADER |
| subdir-ccflags-y += -D_REG_SYNC_WRITE |
| |
| # include path |
| subdir-ccflags-y += -Werror -I$(srctree)/drivers/misc/mediatek/accdet/$(MTK_PLATFORM) |
| subdir-ccflags-y += -Werror -I$(srctree)/drivers/misc/mediatek/include |
| subdir-ccflags-y += -Werror -I$(srctree)/drivers/misc/mediatek/include/mt-plat/$(MTK_PLATFORM)/include |
| subdir-ccflags-y += -Werror -I$(srctree)/drivers/misc/mediatek/include/mt-plat |
| subdir-ccflags-y += -Werror -I$(srctree)/drivers/misc/mediatek/base/power/include |
| subdir-ccflags-y += -Werror -I$(srctree)/drivers/misc/mediatek/base/power/$(MTK_PLATFORM) |
| subdir-ccflags-y += -Werror -I$(srctree)/drivers/misc/mediatek/auxadc/ |
| subdir-ccflags-y += -Werror -I$(srctree)/drivers/misc/mediatek/dramc/$(MTK_PLATFORM)/ |
| |
| AUDIO_PLATFORM := $(subst ",,$(CONFIG_MTK_PLATFORM)) |
| |
| # Common include path |
| subdir-ccflags-y += -Werror -I$(src)/common_int |
| |
| # PMIC include path |
| #ifneq ($(MTK_CODEC),) |
| #subdir-ccflags-y += -Werror -I$(src)/codec/$(MTK_CODEC) |
| #endif |
| ifeq ($(CONFIG_MTK_PMIC_CHIP_MT6389),y) |
| subdir-ccflags-y += -Werror -I$(src)/codec/mt6389 |
| else ifeq ($(CONFIG_MTK_PMIC_CHIP_MT6356),y) |
| subdir-ccflags-y += -Werror -I$(src)/codec/mt6356 |
| else |
| subdir-ccflags-y += -Werror -I$(src)/codec/mt6389 |
| endif |
| |
| # Update pmic built flow to avoid codec init later than codec probe |
| #ifneq ($(MTK_CODEC),) |
| #obj-y += codec/$(MTK_CODEC)/ |
| #endif |
| |
| ifeq ($(CONFIG_MTK_PMIC_CHIP_MT6389),y) |
| obj-y += codec/mt6389/ |
| else ifeq ($(CONFIG_MTK_PMIC_CHIP_MT6356),y) |
| obj-y += codec/mt6356/ |
| else |
| obj-y += codec/mt6389/ |
| endif |
| |
| obj-y += common_int/ |
| |
| |
| obj-y += $(AUDIO_PLATFORM)/ |
| |
| # AP include path |
| subdir-ccflags-y += -Werror -I$(src)/$(AUDIO_PLATFORM) |
| endif |