13a280ed1SRyder Lee /* SPDX-License-Identifier: GPL-2.0 */
2283b6124SGarlic Tseng /*
3283b6124SGarlic Tseng  * mtk-afe-platform-driver.h  --  Mediatek afe platform driver definition
4283b6124SGarlic Tseng  *
5283b6124SGarlic Tseng  * Copyright (c) 2016 MediaTek Inc.
6283b6124SGarlic Tseng  * Author: Garlic Tseng <garlic.tseng@mediatek.com>
7283b6124SGarlic Tseng  */
8283b6124SGarlic Tseng 
9283b6124SGarlic Tseng #ifndef _MTK_AFE_PLATFORM_DRIVER_H_
10283b6124SGarlic Tseng #define _MTK_AFE_PLATFORM_DRIVER_H_
11283b6124SGarlic Tseng 
12f1b5bf07SKuninori Morimoto #define AFE_PCM_NAME "mtk-afe-pcm"
13f1b5bf07SKuninori Morimoto extern const struct snd_soc_component_driver mtk_afe_pcm_platform;
14283b6124SGarlic Tseng 
1513be427eSKaiChieh Chuang struct mtk_base_afe;
16b3c702f5SKaiChieh Chuang struct snd_pcm;
1713be427eSKaiChieh Chuang struct snd_soc_component;
18b3c702f5SKaiChieh Chuang struct snd_soc_pcm_runtime;
19b3c702f5SKaiChieh Chuang 
201fddf424SKuninori Morimoto snd_pcm_uframes_t mtk_afe_pcm_pointer(struct snd_soc_component *component,
211fddf424SKuninori Morimoto 				      struct snd_pcm_substream *substream);
221fddf424SKuninori Morimoto int mtk_afe_pcm_new(struct snd_soc_component *component,
231fddf424SKuninori Morimoto 		    struct snd_soc_pcm_runtime *rtd);
241fddf424SKuninori Morimoto void mtk_afe_pcm_free(struct snd_soc_component *component,
251fddf424SKuninori Morimoto 		      struct snd_pcm *pcm);
2613be427eSKaiChieh Chuang 
2713be427eSKaiChieh Chuang int mtk_afe_combine_sub_dai(struct mtk_base_afe *afe);
2813be427eSKaiChieh Chuang int mtk_afe_add_sub_dai_control(struct snd_soc_component *component);
29283b6124SGarlic Tseng #endif
30283b6124SGarlic Tseng 
31