rk3066 i2s : add I2S0 channels choose,default using two channels
author邱建斌 <qjb@rock-chips.com>
Fri, 21 Dec 2012 09:49:18 +0000 (17:49 +0800)
committer邱建斌 <qjb@rock-chips.com>
Fri, 21 Dec 2012 09:49:18 +0000 (17:49 +0800)
sound/soc/rk29/Kconfig
sound/soc/rk29/rk30_i2s.c

index 4bbf2e034aac3e003260d2c1affd676f5e4c6489..0f9602f08ffdf95140905f47246f90fbaeddbe33 100755 (executable)
@@ -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)"
index 9a2517de26e645ffcbfc81033abb89936525d213..64e6b2c0c524bf62bc517019dea979ab37a3f395 100755 (executable)
@@ -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);