}
// bclk = codec_clk / 4
- // lrck = bclk / (vwl * 2)
+ // lrck = bclk / (wl * 2)
div = (((rk616->stereo_sysclk / 4) / rate) / 2);
if ((rk616->stereo_sysclk % (4 * rate * 2) > 0) ||
switch (params_channels(params)) {
case RK616_MONO:
- adc_aif1 |= RK616_I2S_TYPE_MONO;
+ adc_aif1 |= RK616_ADC_TYPE_MONO;
break;
case RK616_STEREO:
- adc_aif1 |= RK616_I2S_TYPE_STEREO;
+ adc_aif1 |= RK616_ADC_TYPE_STEREO;
break;
default:
return -EINVAL;
snd_soc_update_bits(codec, RK616_ADC_INT_CTL1,
RK616_ADC_VWL_MASK | RK616_ADC_SWAP_MASK |
- RK616_I2S_TYPE_MASK, adc_aif1);
+ RK616_ADC_TYPE_MASK, adc_aif1);
snd_soc_update_bits(codec, RK616_ADC_INT_CTL2,
RK616_ADC_WL_MASK | RK616_ADC_RST_MASK, adc_aif2);
snd_soc_update_bits(codec, RK616_DAC_INT_CTL1,
{0x848, 0x1f}, //MIXINL power down and mute, MININL No selecting, MICMUX from BST_L
{0x840, 0x99}, //BST_L power down, mute, and Single-Ended(bit 6), volume 0(bit 5)
{0x83c, 0x7c}, //power down
- {0x828, 0x09}, //Set for Capture pop noise
};
#define RK616_CODEC_CAPTURE_POWER_DOWN_LIST_LEN ARRAY_SIZE(capture_power_down_list)
#define RK616_ADC_SWAP_EN (0x1 << 1)
#define RK616_ADC_SWAP_DIS (0x0 << 1)
-#define RK616_I2S_TYPE_MASK 0x1
-#define RK616_I2S_TYPE_SFT 0
-#define RK616_I2S_TYPE_STEREO 0x1
-#define RK616_I2S_TYPE_MONO 0x0
+#define RK616_ADC_TYPE_MASK 0x1
+#define RK616_ADC_TYPE_SFT 0
+#define RK616_ADC_TYPE_MONO 0x1
+#define RK616_ADC_TYPE_STEREO 0x0
/* ADC Interface Control 2 (0x0c) */
#define RK616_I2S_MODE_MASK (0x1 << 4)
#define RK616_ADC_PWRD_SFT 6
#define RK616_DIFFIN_MIR_PGAR_RLPWRD (0x1 << 5)
-#define RK616_DIFFIN_MIR_PGAR_RLPWRD_SFT 5
+#define RK616_DIFFIN_MIR_PGAR_RLPWRD_SFT 5
#define RK616_MIC1_MIC2_MIL_PGAL_RLPWRD (0x1 << 4)
#define RK616_MIC1_MIC2_MIL_PGAL_RLPWRD_SFT 4