From: 邱建斌 Date: Fri, 21 Dec 2012 09:49:18 +0000 (+0800) Subject: rk3066 i2s : add I2S0 channels choose,default using two channels X-Git-Tag: firefly_0821_release~8086 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=2f18c497f006543d8315b0d1f63f616bfe9aaa10;p=firefly-linux-kernel-4.4.55.git rk3066 i2s : add I2S0 channels choose,default using two channels --- diff --git a/sound/soc/rk29/Kconfig b/sound/soc/rk29/Kconfig index 4bbf2e034aac..0f9602f08ffd 100755 --- a/sound/soc/rk29/Kconfig +++ b/sound/soc/rk29/Kconfig @@ -15,6 +15,18 @@ config SND_RK29_SOC_I2S_8CH depends on SND_RK29_SOC_I2S && !ARCH_RK3066B help This supports the use of the 8 Channel I2S interface on rk29 processors. + +if SND_RK29_SOC_I2S_8CH +choice + bool "Set I2S0 using the number of channels" + default SND_I2SO_USE_DOUBLE_CHANNELS + config SND_I2SO_USE_EIGHT_CHANNELS + tristate "I2S0 use 8 channels" + + config SND_I2SO_USE_DOUBLE_CHANNELS + tristate "I2S0 use 2 channels" +endchoice +endif config SND_RK29_SOC_I2S_2CH bool "Soc RK29 I2S 2 Channel support(I2S1)" diff --git a/sound/soc/rk29/rk30_i2s.c b/sound/soc/rk29/rk30_i2s.c index 9a2517de26e6..64e6b2c0c524 100755 --- a/sound/soc/rk29/rk30_i2s.c +++ b/sound/soc/rk29/rk30_i2s.c @@ -507,9 +507,11 @@ static int rockchip_i2s_dai_probe(struct snd_soc_dai *dai) rk30_mux_api_set(GPIO0B2_I2S8CHLRCKRX_NAME, GPIO0B_I2S_8CH_LRCK_RX); rk30_mux_api_set(GPIO0B3_I2S8CHLRCKTX_NAME, GPIO0B_I2S_8CH_LRCK_TX); rk30_mux_api_set(GPIO0B4_I2S8CHSDO0_NAME, GPIO0B_I2S_8CH_SDO0); - //rk30_mux_api_set(GPIO0B5_I2S8CHSDO1_NAME, GPIO0B_I2S_8CH_SDO1); - //rk30_mux_api_set(GPIO0B6_I2S8CHSDO2_NAME, GPIO0B_I2S_8CH_SDO2); - //rk30_mux_api_set(GPIO0B7_I2S8CHSDO3_NAME, GPIO0B_I2S_8CH_SDO3); + #ifdef SND_I2SO_USE_EIGHT_CHANNELS + rk30_mux_api_set(GPIO0B5_I2S8CHSDO1_NAME, GPIO0B_I2S_8CH_SDO1); + rk30_mux_api_set(GPIO0B6_I2S8CHSDO2_NAME, GPIO0B_I2S_8CH_SDO2); + rk30_mux_api_set(GPIO0B7_I2S8CHSDO3_NAME, GPIO0B_I2S_8CH_SDO3); + #endif break; case 1: rk30_mux_api_set(GPIO0C0_I2S12CHCLK_NAME, GPIO0C_I2S1_2CH_CLK);