1d6f3710aSGarlic Tseng /* 2d6f3710aSGarlic Tseng * mt2701-afe-clock-ctrl.h -- Mediatek 2701 afe clock ctrl definition 3d6f3710aSGarlic Tseng * 4d6f3710aSGarlic Tseng * Copyright (c) 2016 MediaTek Inc. 5d6f3710aSGarlic Tseng * Author: Garlic Tseng <garlic.tseng@mediatek.com> 6d6f3710aSGarlic Tseng * 7d6f3710aSGarlic Tseng * This program is free software; you can redistribute it and/or modify 8d6f3710aSGarlic Tseng * it under the terms of the GNU General Public License version 2 and 9d6f3710aSGarlic Tseng * only version 2 as published by the Free Software Foundation. 10d6f3710aSGarlic Tseng * 11d6f3710aSGarlic Tseng * This program is distributed in the hope that it will be useful, 12d6f3710aSGarlic Tseng * but WITHOUT ANY WARRANTY; without even the implied warranty of 13d6f3710aSGarlic Tseng * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14d6f3710aSGarlic Tseng * GNU General Public License for more details. 15d6f3710aSGarlic Tseng */ 16d6f3710aSGarlic Tseng 17d6f3710aSGarlic Tseng #ifndef _MT2701_AFE_CLOCK_CTRL_H_ 18d6f3710aSGarlic Tseng #define _MT2701_AFE_CLOCK_CTRL_H_ 19d6f3710aSGarlic Tseng 20d6f3710aSGarlic Tseng struct mtk_base_afe; 21d6f3710aSGarlic Tseng 22d6f3710aSGarlic Tseng int mt2701_init_clock(struct mtk_base_afe *afe); 23d6f3710aSGarlic Tseng int mt2701_afe_enable_clock(struct mtk_base_afe *afe); 24*d8d99d8eSRyder Lee int mt2701_afe_disable_clock(struct mtk_base_afe *afe); 25d6f3710aSGarlic Tseng 26*d8d99d8eSRyder Lee int mt2701_afe_enable_i2s(struct mtk_base_afe *afe, int id, int dir); 27*d8d99d8eSRyder Lee void mt2701_afe_disable_i2s(struct mtk_base_afe *afe, int id, int dir); 28*d8d99d8eSRyder Lee int mt2701_afe_enable_mclk(struct mtk_base_afe *afe, int id); 29*d8d99d8eSRyder Lee void mt2701_afe_disable_mclk(struct mtk_base_afe *afe, int id); 30d6f3710aSGarlic Tseng 31*d8d99d8eSRyder Lee int mt2701_enable_btmrg_clk(struct mtk_base_afe *afe); 32*d8d99d8eSRyder Lee void mt2701_disable_btmrg_clk(struct mtk_base_afe *afe); 33d6f3710aSGarlic Tseng 34d6f3710aSGarlic Tseng void mt2701_mclk_configuration(struct mtk_base_afe *afe, int id, int domain, 35d6f3710aSGarlic Tseng int mclk); 36d6f3710aSGarlic Tseng 37d6f3710aSGarlic Tseng #endif 38