aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Thompson <daniel.thompson@linaro.org>2016-11-25 14:41:25 +0000
committerDaniel Thompson <daniel.thompson@linaro.org>2016-11-25 14:49:33 +0000
commitece0e740c5492b51790c86dd2e9dabf04e829110 (patch)
tree46ba7bf55a2c9c44426565ba44dc08d707641332
parent8ffd454b8d754995833187b1b0ac3a53cf4c6c0d (diff)
downloadlinux-hacking/x20-3.18.tar.gz
sound: soc: mediatek: Correct over-zealous logginghacking/x20-3.18
Reduce verbose internal diagnostics messages to "debug" level. Signed-off-by: Daniel Thompson <daniel.thompson@linaro.org>
-rw-r--r--sound/soc/mediatek/mt_soc_audio_v3/mt_soc_codec_63xx.c254
1 files changed, 127 insertions, 127 deletions
diff --git a/sound/soc/mediatek/mt_soc_audio_v3/mt_soc_codec_63xx.c b/sound/soc/mediatek/mt_soc_audio_v3/mt_soc_codec_63xx.c
index 07e711aa43c3..079414ad8bcf 100644
--- a/sound/soc/mediatek/mt_soc_audio_v3/mt_soc_codec_63xx.c
+++ b/sound/soc/mediatek/mt_soc_audio_v3/mt_soc_codec_63xx.c
@@ -207,7 +207,7 @@ static bool GetDLStatus(void)
static bool mAnaSuspend;
void SetAnalogSuspend(bool bEnable)
{
- pr_warn("%s bEnable ==%d mAnaSuspend = %d\n", __func__, bEnable, mAnaSuspend);
+ pr_debug("%s bEnable ==%d mAnaSuspend = %d\n", __func__, bEnable, mAnaSuspend);
if ((bEnable == true) && (mAnaSuspend == false)) {
/*Ana_Log_Print();*/
SavePowerState();
@@ -509,7 +509,7 @@ EXPORT_SYMBOL(Auddrv_Read_Efuse_HPOffset);
#ifdef CONFIG_MTK_SPEAKER
static void Apply_Speaker_Gain(void)
{
- pr_warn("%s Speaker_pga_gain= %d\n", __func__, Speaker_pga_gain);
+ pr_debug("%s Speaker_pga_gain= %d\n", __func__, Speaker_pga_gain);
Ana_Set_Reg(SPK_ANA_CON0, Speaker_pga_gain << 11, 0x7800);
}
@@ -521,7 +521,7 @@ static void Apply_Speaker_Gain(void)
void setOffsetTrimMux(unsigned int Mux)
{
- pr_warn("%s Mux = %d\n", __func__, Mux);
+ pr_debug("%s Mux = %d\n", __func__, Mux);
Ana_Set_Reg(AUDDEC_ANA_CON3, Mux << 1, 0xf << 1); /* Audio offset trimming buffer mux selection */
}
@@ -535,7 +535,7 @@ static int mHprTrimOffset = 2048;
void SetHplTrimOffset(int Offset)
{
- pr_warn("%s Offset = %d\n", __func__, Offset);
+ pr_debug("%s Offset = %d\n", __func__, Offset);
mHplTrimOffset = Offset;
if ((Offset > 2098) || (Offset < 1998)) {
mHplTrimOffset = 2048;
@@ -545,7 +545,7 @@ void SetHplTrimOffset(int Offset)
void SetHprTrimOffset(int Offset)
{
- pr_warn("%s Offset = %d\n", __func__, Offset);
+ pr_debug("%s Offset = %d\n", __func__, Offset);
mHprTrimOffset = Offset;
if ((Offset > 2098) || (Offset < 1998)) {
mHprTrimOffset = 2048;
@@ -571,7 +571,7 @@ void EnableTrimbuffer(bool benable)
void OpenTrimBufferHardware(bool enable)
{ /* 0804 TODO!!! */
if (enable) {
- pr_warn("%s true\n", __func__);
+ pr_debug("%s true\n", __func__);
TurnOnDacPower();
/* set analog part (HP playback) */
Ana_Set_Reg(AUDDEC_ANA_CON8, 0x0000, 0x0002);
@@ -619,7 +619,7 @@ void OpenTrimBufferHardware(bool enable)
Ana_Set_Reg(AUDDEC_ANA_CON0, 0x0006, 0x0006); /* Enable Audio DACR */
} else {
- pr_warn("%s false\n", __func__);
+ pr_debug("%s false\n", __func__);
Ana_Set_Reg(AUDDEC_ANA_CON4, 0x0000, 0xffff); /* Disable drivers bias circuit */
Ana_Set_Reg(AUDDEC_ANA_CON0, 0x0000, 0xffff); /* Disable Audio DAC */
Ana_Set_Reg(AUDDEC_ANA_CON6, 0x2AC0, 0xfeeb); /* Disable AUD_CLK, bit2/4/8 is for ADC, do not set */
@@ -632,7 +632,7 @@ void OpenTrimBufferHardware(bool enable)
void OpenAnalogTrimHardware(bool enable)
{
if (enable) {
- pr_warn("%s true\n", __func__);
+ pr_debug("%s true\n", __func__);
TurnOnDacPower();
/* upmu_set_rg_vio18_cal(1);// for MT6328 E1 VIO18 patch only */
/* set analog part (HP playback) */
@@ -688,7 +688,7 @@ void OpenAnalogTrimHardware(bool enable)
/* Enable Audio DACR */
} else {
- pr_warn("%s false\n", __func__);
+ pr_debug("%s false\n", __func__);
Ana_Set_Reg(AUDDEC_ANA_CON4, 0x0000, 0xffff);
/* Disable drivers bias circuit */
Ana_Set_Reg(AUDDEC_ANA_CON0, 0x0000, 0xffff);
@@ -724,7 +724,7 @@ void OpenAnalogHeadphone(bool bEnable)
bool OpenHeadPhoneImpedanceSetting(bool bEnable)
{
- pr_warn("%s benable = %d\n", __func__, bEnable);
+ pr_debug("%s benable = %d\n", __func__, bEnable);
if (GetDLStatus() == true)
return false;
@@ -862,7 +862,7 @@ static void SetHprOffset(int OffsetTrimming)
int DCoffsetValue = 0;
unsigned short RegValue = 0;
- /*pr_warn("%s OffsetTrimming = %d\n", __func__, OffsetTrimming);*/
+ /*pr_debug("%s OffsetTrimming = %d\n", __func__, OffsetTrimming);*/
DCoffsetValue = OffsetTrimming * 1000000;
DCoffsetValue = (DCoffsetValue / DC1devider); /* in uv */
DCoffsetValue = (DCoffsetValue / DC1unit_in_uv);
@@ -879,7 +879,7 @@ static void SetHplOffset(int OffsetTrimming)
int DCoffsetValue = 0;
unsigned short RegValue = 0;
- /*pr_warn("%s OffsetTrimming = %d\n", __func__, OffsetTrimming);*/
+ /*pr_debug("%s OffsetTrimming = %d\n", __func__, OffsetTrimming);*/
DCoffsetValue = OffsetTrimming * 1000000;
DCoffsetValue = (DCoffsetValue / DC1devider); /* in uv */
DCoffsetValue = (DCoffsetValue / DC1unit_in_uv);
@@ -946,7 +946,7 @@ static void SetDcCompenSation_SPKHP(void)
static void SetDCcoupleNP(int MicBias, int mode)
{
- pr_warn("%s MicBias= %d mode = %d\n", __func__, MicBias, mode);
+ pr_debug("%s MicBias= %d mode = %d\n", __func__, MicBias, mode);
switch (mode) {
case AUDIO_ANALOGUL_MODE_ACC:
case AUDIO_ANALOGUL_MODE_DCC:
@@ -983,7 +983,7 @@ uint32 GetULFrequency(uint32 frequency)
{
uint32 Reg_value = 0;
- pr_warn("%s frequency =%d\n", __func__, frequency);
+ pr_debug("%s frequency =%d\n", __func__, frequency);
switch (frequency) {
case 8000:
case 16000:
@@ -1387,7 +1387,7 @@ static void HeadsetVoloumeRestore(void)
{
int index = 0, oldindex = 0, offset = 0, count = 1;
- pr_warn("%s\n", __func__);
+ pr_debug("%s\n", __func__);
index = 8;
oldindex = mCodec_data->mAudio_Ana_Volume[AUDIO_ANALOG_VOLUME_HPOUTR];
@@ -1422,7 +1422,7 @@ static void HeadsetVoloumeSet(void)
index = mCodec_data->mAudio_Ana_Volume[AUDIO_ANALOG_VOLUME_HPOUTR];
oldindex = 8;
if (index > oldindex) {
- pr_warn("%s index = %d oldindex = %d\n", __func__ , index, oldindex);
+ pr_debug("%s index = %d oldindex = %d\n", __func__ , index, oldindex);
offset = index - oldindex;
while (offset > 0) {
Ana_Set_Reg(ZCD_CON2, ((oldindex + count) << 7) | (oldindex + count),
@@ -1432,7 +1432,7 @@ static void HeadsetVoloumeSet(void)
udelay(200);
}
} else {
- pr_warn("%s index = %d oldindex = %d\n", __func__ , index, oldindex);
+ pr_debug("%s index = %d oldindex = %d\n", __func__ , index, oldindex);
offset = oldindex - index;
while (offset > 0) {
Ana_Set_Reg(ZCD_CON2, ((oldindex - count) << 7) | (oldindex - count),
@@ -1455,7 +1455,7 @@ static void Audio_Amp_Change(int channels, bool enable)
if (mCodec_data->mAudio_Ana_DevicePower[AUDIO_ANALOG_DEVICE_OUT_HEADSETL] == false
&& mCodec_data->mAudio_Ana_DevicePower[AUDIO_ANALOG_DEVICE_OUT_HEADSETR] ==
false) {
- pr_warn("%s\n", __func__);
+ pr_debug("%s\n", __func__);
/* upmu_set_rg_vio18_cal(1);// for MT6328 E1 VIO18 patch only */
/* set analog part (HP playback) */
@@ -1571,7 +1571,7 @@ static int Audio_AmpL_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_val
{
mutex_lock(&Ana_Ctrl_Mutex);
- pr_warn("%s() gain = %ld\n ", __func__, ucontrol->value.integer.value[0]);
+ pr_debug("%s() gain = %ld\n ", __func__, ucontrol->value.integer.value[0]);
if ((ucontrol->value.integer.value[0] == true)
&& (mCodec_data->mAudio_Ana_DevicePower[AUDIO_ANALOG_DEVICE_OUT_HEADSETL] == false)) {
Audio_Amp_Change(AUDIO_ANALOG_CHANNELS_LEFT1, true);
@@ -1601,7 +1601,7 @@ static int Audio_AmpR_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_val
{
mutex_lock(&Ana_Ctrl_Mutex);
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if ((ucontrol->value.integer.value[0] == true)
&& (mCodec_data->mAudio_Ana_DevicePower[AUDIO_ANALOG_DEVICE_OUT_HEADSETR] == false)) {
Audio_Amp_Change(AUDIO_ANALOG_CHANNELS_RIGHT1, true);
@@ -1622,7 +1622,7 @@ static int Audio_AmpR_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_val
static void Voice_Amp_Change(bool enable)
{
if (enable) {
- pr_warn("%s\n", __func__);
+ pr_debug("%s\n", __func__);
if (GetDLStatus() == false) {
TurnOnDacPower();
pr_warn("Voice_Amp_Change on amp\n");
@@ -1707,7 +1707,7 @@ static int Voice_Amp_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_valu
static int Voice_Amp_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
mutex_lock(&Ana_Ctrl_Mutex);
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if ((ucontrol->value.integer.value[0] == true)
&& (mCodec_data->mAudio_Ana_DevicePower[AUDIO_ANALOG_DEVICE_OUT_EARPIECEL] == false)) {
Voice_Amp_Change(true);
@@ -1730,7 +1730,7 @@ static void Speaker_Amp_Change(bool enable)
if (GetDLStatus() == false)
TurnOnDacPower();
- pr_warn("%s\n", __func__);
+ pr_debug("%s\n", __func__);
/* upmu_set_rg_vio18_cal(1);// for MT6328 E1 VIO18 patch only */
/* ClassAB spk pmic analog control */
Ana_Set_Reg(AUDNCP_CLKDIV_CON1, 0x0001, 0xffff);
@@ -1818,7 +1818,7 @@ static void Speaker_Amp_Change(bool enable)
static int Speaker_Amp_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
ucontrol->value.integer.value[0] =
mCodec_data->mAudio_Ana_DevicePower[AUDIO_ANALOG_DEVICE_OUT_SPEAKERL];
return 0;
@@ -1826,7 +1826,7 @@ static int Speaker_Amp_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_va
static int Speaker_Amp_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() value = %ld\n ", __func__, ucontrol->value.integer.value[0]);
+ pr_debug("%s() value = %ld\n ", __func__, ucontrol->value.integer.value[0]);
if ((ucontrol->value.integer.value[0] == true)
&& (mCodec_data->mAudio_Ana_DevicePower[AUDIO_ANALOG_DEVICE_OUT_SPEAKERL] == false)) {
Speaker_Amp_Change(true);
@@ -2284,7 +2284,7 @@ static void Headset_Speaker_Amp_Change(bool enable)
static int Headset_Speaker_Amp_Get(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
ucontrol->value.integer.value[0] =
mCodec_data->mAudio_Ana_DevicePower[AUDIO_ANALOG_DEVICE_OUT_SPEAKER_HEADSET_R];
return 0;
@@ -2295,7 +2295,7 @@ static int Headset_Speaker_Amp_Set(struct snd_kcontrol *kcontrol,
{
/* struct snd_soc_codec *codec = snd_kcontrol_chip(kcontrol); */
- pr_warn("%s() gain = %lu\n ", __func__, ucontrol->value.integer.value[0]);
+ pr_debug("%s() gain = %lu\n ", __func__, ucontrol->value.integer.value[0]);
if ((ucontrol->value.integer.value[0] == true)
&& (mCodec_data->mAudio_Ana_DevicePower[AUDIO_ANALOG_DEVICE_OUT_SPEAKER_HEADSET_R] ==
false)) {
@@ -2343,7 +2343,7 @@ static int Audio_Speaker_Pga_Gain_Set(struct snd_kcontrol *kcontrol,
{
Speaker_pga_gain = ucontrol->value.integer.value[0];
- pr_warn("%s Speaker_pga_gain= %d\n", __func__, Speaker_pga_gain);
+ pr_debug("%s Speaker_pga_gain= %d\n", __func__, Speaker_pga_gain);
Ana_Set_Reg(SPK_ANA_CON0, Speaker_pga_gain << 11, 0x7800);
return 0;
}
@@ -2359,7 +2359,7 @@ static int Audio_Speaker_OcFlag_Get(struct snd_kcontrol *kcontrol,
static int Audio_Speaker_OcFlag_Set(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s is not support setting\n", __func__);
+ pr_debug("%s is not support setting\n", __func__);
return 0;
}
@@ -2438,7 +2438,7 @@ int Audio_AuxAdcData_Get_ext(void)
#ifdef _GIT318_PMIC_READY
int dRetValue = PMIC_IMM_GetOneChannelValue(AUX_ICLASSAB_AP, 1, 0);
- pr_warn("%s dRetValue 0x%x\n", __func__, dRetValue);
+ pr_debug("%s dRetValue 0x%x\n", __func__, dRetValue);
return dRetValue;
#else
return 0;
@@ -2458,7 +2458,7 @@ static int Audio_AuxAdcData_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_el
#else
ucontrol->value.integer.value[0] = 0;
#endif
- pr_warn("%s dMax = 0x%lx\n", __func__, ucontrol->value.integer.value[0]);
+ pr_debug("%s dMax = 0x%lx\n", __func__, ucontrol->value.integer.value[0]);
return 0;
}
@@ -2466,7 +2466,7 @@ static int Audio_AuxAdcData_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_el
static int Audio_AuxAdcData_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
dAuxAdcChannel = ucontrol->value.integer.value[0];
- pr_warn("%s dAuxAdcChannel = 0x%x\n", __func__, dAuxAdcChannel);
+ pr_debug("%s dAuxAdcChannel = 0x%x\n", __func__, dAuxAdcChannel);
return 0;
}
@@ -2509,7 +2509,7 @@ static int Lineout_PGAL_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_v
{
int index = 0;
- /*pr_warn("%s(), index = %d\n", __func__, ucontrol->value.enumerated.item[0]);*/
+ /*pr_debug("%s(), index = %d\n", __func__, ucontrol->value.enumerated.item[0]);*/
if (ucontrol->value.enumerated.item[0] >= ARRAY_SIZE(DAC_DL_PGA_Speaker_GAIN)) {
pr_warn("return -EINVAL\n");
@@ -2529,7 +2529,7 @@ static int Lineout_PGAL_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_v
static int Lineout_PGAR_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s = %d\n", __func__, mCodec_data->mAudio_Ana_Volume[AUDIO_ANALOG_VOLUME_SPKR]);
+ pr_debug("%s = %d\n", __func__, mCodec_data->mAudio_Ana_Volume[AUDIO_ANALOG_VOLUME_SPKR]);
ucontrol->value.integer.value[0] = mCodec_data->mAudio_Ana_Volume[AUDIO_ANALOG_VOLUME_SPKR];
return 0;
}
@@ -2539,7 +2539,7 @@ static int Lineout_PGAR_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_v
/* struct snd_soc_codec *codec = snd_kcontrol_chip(kcontrol); */
int index = 0;
- /*pr_warn("%s(), index = %d\n", __func__, ucontrol->value.enumerated.item[0]);*/
+ /*pr_debug("%s(), index = %d\n", __func__, ucontrol->value.enumerated.item[0]);*/
if (ucontrol->value.enumerated.item[0] >= ARRAY_SIZE(DAC_DL_PGA_Speaker_GAIN)) {
pr_warn("return -EINVAL\n");
@@ -2570,7 +2570,7 @@ static int Handset_PGA_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_va
/* struct snd_soc_codec *codec = snd_kcontrol_chip(kcontrol); */
int index = 0;
- pr_warn("%s(), index = %d\n", __func__, ucontrol->value.enumerated.item[0]);
+ pr_debug("%s(), index = %d\n", __func__, ucontrol->value.enumerated.item[0]);
if (ucontrol->value.enumerated.item[0] >= ARRAY_SIZE(DAC_DL_PGA_Handset_GAIN)) {
pr_warn("return -EINVAL\n");
@@ -2602,7 +2602,7 @@ static int Headset_PGAL_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_v
/* struct snd_soc_codec *codec = snd_kcontrol_chip(kcontrol); */
int index = 0;
- /* pr_warn("%s(), index = %d arraysize = %d\n", __func__,
+ /* pr_debug("%s(), index = %d arraysize = %d\n", __func__,
ucontrol->value.enumerated.item[0], ARRAY_SIZE(DAC_DL_PGA_Headset_GAIN)); //mark for 64bit build fail */
if (ucontrol->value.enumerated.item[0] >= ARRAY_SIZE(DAC_DL_PGA_Headset_GAIN)) {
@@ -2636,7 +2636,7 @@ static int Headset_PGAR_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_v
/* struct snd_soc_codec *codec = snd_kcontrol_chip(kcontrol); */
int index = 0;
- /*pr_warn("%s(), index = %d\n", __func__, ucontrol->value.enumerated.item[0]);*/
+ /*pr_debug("%s(), index = %d\n", __func__, ucontrol->value.enumerated.item[0]);*/
if (ucontrol->value.enumerated.item[0] >= ARRAY_SIZE(DAC_DL_PGA_Headset_GAIN)) {
pr_err("return -EINVAL\n");
@@ -2668,20 +2668,20 @@ static int Audio_Hp_Impedance_Set(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
mHp_Impedance = ucontrol->value.integer.value[0];
- pr_warn("%s Audio_Hp_Impedance_Set = 0x%x\n", __func__, mHp_Impedance);
+ pr_debug("%s Audio_Hp_Impedance_Set = 0x%x\n", __func__, mHp_Impedance);
return 0;
}
static int Aud_Clk_Buf_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- /*pr_warn("\%s n", __func__);*/
+ /*pr_debug("\%s n", __func__);*/
ucontrol->value.integer.value[0] = audck_buf_Count;
return 0;
}
static int Aud_Clk_Buf_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- /*pr_warn("%s(), value = %d\n", __func__, ucontrol->value.enumerated.item[0]);*/
+ /*pr_debug("%s(), value = %d\n", __func__, ucontrol->value.enumerated.item[0]);*/
if (ucontrol->value.integer.value[0])
audckbufEnable(true);
@@ -2738,7 +2738,7 @@ void SetMicPGAGain(void)
int index = 0;
index = mCodec_data->mAudio_Ana_Volume[AUDIO_ANALOG_VOLUME_MICAMP1];
- pr_warn("%s AUDIO_ANALOG_VOLUME_MICAMP1 index =%d\n", __func__, index);
+ pr_debug("%s AUDIO_ANALOG_VOLUME_MICAMP1 index =%d\n", __func__, index);
/* Ana_Set_Reg(AUDENC_ANA_CON15, index , 0x0007); */
Ana_Set_Reg(AUDENC_ANA_CON10, index, 0x0007);
@@ -2779,7 +2779,7 @@ static bool TurnOnADcPowerACC(int ADCType, bool enable)
refmic_using_ADC_L = false;
- pr_warn("%s ADCType = %d enable = %d, refmic_using_ADC_L=%d\n", __func__, ADCType,
+ pr_debug("%s ADCType = %d enable = %d, refmic_using_ADC_L=%d\n", __func__, ADCType,
enable, refmic_using_ADC_L);
if (enable) {
@@ -2823,7 +2823,7 @@ static bool TurnOnADcPowerACC(int ADCType, bool enable)
}
if (ADCType == AUDIO_ANALOG_DEVICE_IN_ADC1) { /* main and headset mic */
- pr_warn("%s AUDIO_ANALOG_DEVICE_IN_ADC1 mux =%d\n", __func__,
+ pr_debug("%s AUDIO_ANALOG_DEVICE_IN_ADC1 mux =%d\n", __func__,
mCodec_data->mAudio_Ana_Mux[AUDIO_MICSOURCE_MUX_IN_1]);
if (mCodec_data->mAudio_Ana_Mux[AUDIO_MICSOURCE_MUX_IN_1] == 0) {
/* "ADC1", main_mic */
@@ -2845,7 +2845,7 @@ static bool TurnOnADcPowerACC(int ADCType, bool enable)
Ana_Set_Reg(AUDENC_ANA_CON10, 0x0003, 0x000f); /* Audio L PGA 18 dB gain(SMT) MT6328 */
} else if (ADCType == AUDIO_ANALOG_DEVICE_IN_ADC2) { /* ref mic */
- pr_warn("%s AUDIO_ANALOG_DEVICE_IN_ADC2 refmic_using_ADC_L =%d\n", __func__,
+ pr_debug("%s AUDIO_ANALOG_DEVICE_IN_ADC2 refmic_using_ADC_L =%d\n", __func__,
refmic_using_ADC_L);
SetDCcoupleNP(AUDIO_MIC_BIAS0, mAudio_Analog_Mic2_mode);
/* micbias0 DCCopuleNP */
@@ -3054,7 +3054,7 @@ static bool TurnOnADcPowerACC(int ADCType, bool enable)
static bool TurnOnADcPowerDmic(int ADCType, bool enable)
{
- pr_warn("%s ADCType = %d enable = %d\n", __func__, ADCType, enable);
+ pr_debug("%s ADCType = %d enable = %d\n", __func__, ADCType, enable);
if (enable) {
uint32 ULIndex = GetULFrequency(mBlockSampleRate[AUDIO_ANALOG_DEVICE_IN_ADC]);
uint32 SampleRate_VUL1 = mBlockSampleRate[AUDIO_ANALOG_DEVICE_IN_ADC];
@@ -3143,7 +3143,7 @@ static bool TurnOnADcPowerDmic(int ADCType, bool enable)
static bool TurnOnADcPowerDCC(int ADCType, bool enable, int ECMmode)
{
- pr_warn("%s ADCType = %d enable = %d\n", __func__, ADCType, enable);
+ pr_debug("%s ADCType = %d enable = %d\n", __func__, ADCType, enable);
if (enable) {
/* uint32 ULIndex = GetULFrequency(mBlockSampleRate[AUDIO_ANALOG_DEVICE_IN_ADC]); */
uint32 SampleRate_VUL1 = mBlockSampleRate[AUDIO_ANALOG_DEVICE_IN_ADC];
@@ -3200,7 +3200,7 @@ static bool TurnOnADcPowerDCC(int ADCType, bool enable, int ECMmode)
/* default value */
}
if (ADCType == AUDIO_ANALOG_DEVICE_IN_ADC1) { /* main and headset mic */
- pr_warn("%s AUDIO_MICSOURCE_MUX_IN_1 mux =%d\n", __func__,
+ pr_debug("%s AUDIO_MICSOURCE_MUX_IN_1 mux =%d\n", __func__,
mCodec_data->mAudio_Ana_Mux[AUDIO_MICSOURCE_MUX_IN_1]);
if (mCodec_data->mAudio_Ana_Mux[AUDIO_MICSOURCE_MUX_IN_1] == 0) { /* "ADC1", main_mic */
SetDCcoupleNP(AUDIO_MIC_BIAS0, mAudio_Analog_Mic1_mode);
@@ -3531,7 +3531,7 @@ static int Audio_ADC1_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_val
static int Audio_ADC1_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
mutex_lock(&Ana_Power_Mutex);
if (ucontrol->value.integer.value[0]) {
if (mAudio_Analog_Mic1_mode == AUDIO_ANALOGUL_MODE_ACC)
@@ -3577,7 +3577,7 @@ static int Audio_ADC2_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_val
static int Audio_ADC2_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
mutex_lock(&Ana_Power_Mutex);
if (ucontrol->value.integer.value[0]) {
if (mAudio_Analog_Mic2_mode == AUDIO_ANALOGUL_MODE_ACC)
@@ -3638,14 +3638,14 @@ static int Audio_ADC4_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_val
static int Audio_ADC1_Sel_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %d\n", __func__, mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_MIC1]);
+ pr_debug("%s() = %d\n", __func__, mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_MIC1]);
ucontrol->value.integer.value[0] = mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_MIC1];
return 0;
}
static int Audio_ADC1_Sel_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(Adc_Input_Sel)) {
pr_err("return -EINVAL\n");
@@ -3659,23 +3659,23 @@ static int Audio_ADC1_Sel_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem
else if (ucontrol->value.integer.value[0] == 2)
Ana_Set_Reg(AUDENC_ANA_CON0, (0x0002 << 9), 0x0600); /* Left preamp */
else
- pr_warn("%s() warning\n ", __func__);
+ pr_debug("%s() warning\n ", __func__);
- pr_warn("%s() done\n", __func__);
+ pr_debug("%s() done\n", __func__);
mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_MIC1] = ucontrol->value.integer.value[0];
return 0;
}
static int Audio_ADC2_Sel_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %d\n", __func__, mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_MIC2]);
+ pr_debug("%s() = %d\n", __func__, mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_MIC2]);
ucontrol->value.integer.value[0] = mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_MIC2];
return 0;
}
static int Audio_ADC2_Sel_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(Adc_Input_Sel)) {
pr_err("return -EINVAL\n");
return -EINVAL;
@@ -3688,9 +3688,9 @@ static int Audio_ADC2_Sel_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem
else if (ucontrol->value.integer.value[0] == 2) /* Right preamp */
Ana_Set_Reg(AUDENC_ANA_CON1, (0x0002 << 9), 0x0600);
else
- pr_warn("%s() warning\n ", __func__);
+ pr_warn("%s() %d unexpected\n ", __func__, ucontrol->value.integer.value[0]);
- pr_warn("%s() done\n", __func__);
+ pr_debug("%s() done\n", __func__);
mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_MIC2] = ucontrol->value.integer.value[0];
return 0;
}
@@ -3722,7 +3722,7 @@ static int Audio_ADC4_Sel_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem
static bool AudioPreAmp1_Sel(int Mul_Sel)
{
- pr_warn("%s Mul_Sel = %d ", __func__, Mul_Sel);
+ pr_debug("%s Mul_Sel = %d ", __func__, Mul_Sel);
if (Mul_Sel == 0)
Ana_Set_Reg(AUDENC_ANA_CON0, 0x0000, 0x00C0); /* pinumx open */
else if (Mul_Sel == 1)
@@ -3740,7 +3740,7 @@ static bool AudioPreAmp1_Sel(int Mul_Sel)
static int Audio_PreAmp1_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_PREAMP_1]; = %d\n", __func__,
+ pr_debug("%s() mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_PREAMP_1]; = %d\n", __func__,
mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_PREAMP_1]);
ucontrol->value.integer.value[0] =
mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_PREAMP_1];
@@ -3749,7 +3749,7 @@ static int Audio_PreAmp1_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_
static int Audio_PreAmp1_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(PreAmp_Mux_function)) {
pr_err("return -EINVAL\n");
@@ -3758,13 +3758,13 @@ static int Audio_PreAmp1_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_
mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_PREAMP_1] =
ucontrol->value.integer.value[0];
AudioPreAmp1_Sel(mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_PREAMP_1]);
- pr_warn("%s() done\n", __func__);
+ pr_debug("%s() done\n", __func__);
return 0;
}
static bool AudioPreAmp2_Sel(int Mul_Sel)
{
- pr_warn("%s Mul_Sel = %d ", __func__, Mul_Sel);
+ pr_debug("%s Mul_Sel = %d ", __func__, Mul_Sel);
if (Mul_Sel == 0)
Ana_Set_Reg(AUDENC_ANA_CON1, 0x0000, 0x00C0); /* pinumx open */
@@ -3783,7 +3783,7 @@ static bool AudioPreAmp2_Sel(int Mul_Sel)
static int Audio_PreAmp2_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_PREAMP_2]; = %d\n", __func__,
+ pr_debug("%s() mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_PREAMP_2]; = %d\n", __func__,
mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_PREAMP_2]);
ucontrol->value.integer.value[0] =
mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_PREAMP_2];
@@ -3792,7 +3792,7 @@ static int Audio_PreAmp2_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_
static int Audio_PreAmp2_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(PreAmp_Mux_function)) {
pr_err("return -EINVAL\n");
@@ -3801,7 +3801,7 @@ static int Audio_PreAmp2_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_
mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_PREAMP_2] =
ucontrol->value.integer.value[0];
AudioPreAmp2_Sel(mCodec_data->mAudio_Ana_Mux[AUDIO_ANALOG_MUX_IN_PREAMP_2]);
- pr_warn("%s() done\n", __func__);
+ pr_debug("%s() done\n", __func__);
return 0;
}
@@ -3819,7 +3819,7 @@ static int Audio_PGA1_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_val
{
int index = 0;
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(ADC_UL_PGA_GAIN)) {
pr_err("return -EINVAL\n");
return -EINVAL;
@@ -3845,7 +3845,7 @@ static int Audio_PGA2_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_val
{
int index = 0;
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(ADC_UL_PGA_GAIN)) {
pr_err("return -EINVAL\n");
return -EINVAL;
@@ -3894,13 +3894,13 @@ static int Audio_MicSource1_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_el
/* 6752 used for ADC1 Mic source selection, "ADC1" is main_mic, "ADC2" is headset_mic */
int index = 0;
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(Pmic_Digital_Mux)) {
pr_err("return -EINVAL\n");
return -EINVAL;
}
index = ucontrol->value.integer.value[0];
- pr_warn("%s() index = %d done\n", __func__, index);
+ pr_debug("%s() index = %d done\n", __func__, index);
mCodec_data->mAudio_Ana_Mux[AUDIO_MICSOURCE_MUX_IN_1] = ucontrol->value.integer.value[0];
return 0;
@@ -3947,7 +3947,7 @@ static int Audio_MicSource4_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_el
static int Audio_Mic1_Mode_Select_Get(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() mAudio_Analog_Mic1_mode = %d\n", __func__, mAudio_Analog_Mic1_mode);
+ pr_debug("%s() mAudio_Analog_Mic1_mode = %d\n", __func__, mAudio_Analog_Mic1_mode);
ucontrol->value.integer.value[0] = mAudio_Analog_Mic1_mode;
return 0;
}
@@ -3955,20 +3955,20 @@ static int Audio_Mic1_Mode_Select_Get(struct snd_kcontrol *kcontrol,
static int Audio_Mic1_Mode_Select_Set(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(Audio_AnalogMic_Mode)) {
pr_err("return -EINVAL\n");
return -EINVAL;
}
mAudio_Analog_Mic1_mode = ucontrol->value.integer.value[0];
- pr_warn("%s() mAudio_Analog_Mic1_mode = %d\n", __func__, mAudio_Analog_Mic1_mode);
+ pr_debug("%s() mAudio_Analog_Mic1_mode = %d\n", __func__, mAudio_Analog_Mic1_mode);
return 0;
}
static int Audio_Mic2_Mode_Select_Get(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %d\n", __func__, mAudio_Analog_Mic2_mode);
+ pr_debug("%s() = %d\n", __func__, mAudio_Analog_Mic2_mode);
ucontrol->value.integer.value[0] = mAudio_Analog_Mic2_mode;
return 0;
}
@@ -3976,13 +3976,13 @@ static int Audio_Mic2_Mode_Select_Get(struct snd_kcontrol *kcontrol,
static int Audio_Mic2_Mode_Select_Set(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(Audio_AnalogMic_Mode)) {
pr_err("return -EINVAL\n");
return -EINVAL;
}
mAudio_Analog_Mic2_mode = ucontrol->value.integer.value[0];
- pr_warn("%s() mAudio_Analog_Mic2_mode = %d\n", __func__, mAudio_Analog_Mic2_mode);
+ pr_debug("%s() mAudio_Analog_Mic2_mode = %d\n", __func__, mAudio_Analog_Mic2_mode);
return 0;
}
@@ -3990,7 +3990,7 @@ static int Audio_Mic2_Mode_Select_Set(struct snd_kcontrol *kcontrol,
static int Audio_Mic3_Mode_Select_Get(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %d\n", __func__, mAudio_Analog_Mic3_mode);
+ pr_debug("%s() = %d\n", __func__, mAudio_Analog_Mic3_mode);
ucontrol->value.integer.value[0] = mAudio_Analog_Mic3_mode;
return 0;
}
@@ -3998,20 +3998,20 @@ static int Audio_Mic3_Mode_Select_Get(struct snd_kcontrol *kcontrol,
static int Audio_Mic3_Mode_Select_Set(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(Audio_AnalogMic_Mode)) {
pr_err("return -EINVAL\n");
return -EINVAL;
}
mAudio_Analog_Mic3_mode = ucontrol->value.integer.value[0];
- pr_warn("%s() mAudio_Analog_Mic3_mode = %d\n", __func__, mAudio_Analog_Mic3_mode);
+ pr_debug("%s() mAudio_Analog_Mic3_mode = %d\n", __func__, mAudio_Analog_Mic3_mode);
return 0;
}
static int Audio_Mic4_Mode_Select_Get(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %d\n", __func__, mAudio_Analog_Mic4_mode);
+ pr_debug("%s() = %d\n", __func__, mAudio_Analog_Mic4_mode);
ucontrol->value.integer.value[0] = mAudio_Analog_Mic4_mode;
return 0;
}
@@ -4019,20 +4019,20 @@ static int Audio_Mic4_Mode_Select_Get(struct snd_kcontrol *kcontrol,
static int Audio_Mic4_Mode_Select_Set(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(Audio_AnalogMic_Mode)) {
pr_err("return -EINVAL\n");
return -EINVAL;
}
mAudio_Analog_Mic4_mode = ucontrol->value.integer.value[0];
- pr_warn("%s() mAudio_Analog_Mic4_mode = %d\n", __func__, mAudio_Analog_Mic4_mode);
+ pr_debug("%s() mAudio_Analog_Mic4_mode = %d\n", __func__, mAudio_Analog_Mic4_mode);
return 0;
}
static int Audio_Adc_Power_Mode_Get(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %d\n", __func__, mAdc_Power_Mode);
+ pr_debug("%s() = %d\n", __func__, mAdc_Power_Mode);
ucontrol->value.integer.value[0] = mAdc_Power_Mode;
return 0;
}
@@ -4040,13 +4040,13 @@ static int Audio_Adc_Power_Mode_Get(struct snd_kcontrol *kcontrol,
static int Audio_Adc_Power_Mode_Set(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(ADC_power_mode)) {
pr_err("return -EINVAL\n");
return -EINVAL;
}
mAdc_Power_Mode = ucontrol->value.integer.value[0];
- pr_warn("%s() mAdc_Power_Mode = %d\n", __func__, mAdc_Power_Mode);
+ pr_debug("%s() mAdc_Power_Mode = %d\n", __func__, mAdc_Power_Mode);
return 0;
}
@@ -4054,7 +4054,7 @@ static int Audio_Adc_Power_Mode_Set(struct snd_kcontrol *kcontrol,
static int Audio_Vow_ADC_Func_Switch_Get(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %d\n", __func__, mAudio_Vow_Analog_Func_Enable);
+ pr_debug("%s() = %d\n", __func__, mAudio_Vow_Analog_Func_Enable);
ucontrol->value.integer.value[0] = mAudio_Vow_Analog_Func_Enable;
return 0;
}
@@ -4062,7 +4062,7 @@ static int Audio_Vow_ADC_Func_Switch_Get(struct snd_kcontrol *kcontrol,
static int Audio_Vow_ADC_Func_Switch_Set(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(Audio_VOW_ADC_Function)) {
pr_err("return -EINVAL\n");
return -EINVAL;
@@ -4075,7 +4075,7 @@ static int Audio_Vow_ADC_Func_Switch_Set(struct snd_kcontrol *kcontrol,
mAudio_Vow_Analog_Func_Enable = ucontrol->value.integer.value[0];
- pr_warn("%s() mAudio_Vow_Analog_Func_Enable = %d\n", __func__,
+ pr_debug("%s() mAudio_Vow_Analog_Func_Enable = %d\n", __func__,
mAudio_Vow_Analog_Func_Enable);
return 0;
}
@@ -4083,7 +4083,7 @@ static int Audio_Vow_ADC_Func_Switch_Set(struct snd_kcontrol *kcontrol,
static int Audio_Vow_Digital_Func_Switch_Get(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %d\n", __func__, mAudio_Vow_Digital_Func_Enable);
+ pr_debug("%s() = %d\n", __func__, mAudio_Vow_Digital_Func_Enable);
ucontrol->value.integer.value[0] = mAudio_Vow_Digital_Func_Enable;
return 0;
}
@@ -4091,7 +4091,7 @@ static int Audio_Vow_Digital_Func_Switch_Get(struct snd_kcontrol *kcontrol,
static int Audio_Vow_Digital_Func_Switch_Set(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(Audio_VOW_Digital_Function)) {
pr_err("return -EINVAL\n");
return -EINVAL;
@@ -4104,7 +4104,7 @@ static int Audio_Vow_Digital_Func_Switch_Set(struct snd_kcontrol *kcontrol,
mAudio_Vow_Digital_Func_Enable = ucontrol->value.integer.value[0];
- pr_warn("%s() mAudio_Vow_Digital_Func_Enable = %d\n", __func__,
+ pr_debug("%s() mAudio_Vow_Digital_Func_Enable = %d\n", __func__,
mAudio_Vow_Digital_Func_Enable);
return 0;
}
@@ -4113,7 +4113,7 @@ static int Audio_Vow_Digital_Func_Switch_Set(struct snd_kcontrol *kcontrol,
static int Audio_Vow_MIC_Type_Select_Get(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %d\n", __func__, mAudio_VOW_Mic_type);
+ pr_debug("%s() = %d\n", __func__, mAudio_VOW_Mic_type);
ucontrol->value.integer.value[0] = mAudio_VOW_Mic_type;
return 0;
}
@@ -4121,13 +4121,13 @@ static int Audio_Vow_MIC_Type_Select_Get(struct snd_kcontrol *kcontrol,
static int Audio_Vow_MIC_Type_Select_Set(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.enumerated.item[0] > ARRAY_SIZE(Audio_VOW_MIC_Type)) {
pr_err("return -EINVAL\n");
return -EINVAL;
}
mAudio_VOW_Mic_type = ucontrol->value.integer.value[0];
- pr_warn("%s() mAudio_VOW_Mic_type = %d\n", __func__, mAudio_VOW_Mic_type);
+ pr_debug("%s() mAudio_VOW_Mic_type = %d\n", __func__, mAudio_VOW_Mic_type);
return 0;
}
@@ -4136,14 +4136,14 @@ static int Audio_Vow_Cfg0_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem
{
int value = /*Ana_Get_Reg(AFE_VOW_CFG0) */ reg_AFE_VOW_CFG0;
- pr_warn("%s() = %d\n", __func__, value);
+ pr_debug("%s() = %d\n", __func__, value);
ucontrol->value.integer.value[0] = value;
return 0;
}
static int Audio_Vow_Cfg0_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %d\n", __func__, (int)(ucontrol->value.integer.value[0]));
+ pr_debug("%s() = %d\n", __func__, (int)(ucontrol->value.integer.value[0]));
/* Ana_Set_Reg(AFE_VOW_CFG0, ucontrol->value.integer.value[0], 0xffff); */
reg_AFE_VOW_CFG0 = ucontrol->value.integer.value[0];
return 0;
@@ -4153,14 +4153,14 @@ static int Audio_Vow_Cfg1_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem
{
int value = /*Ana_Get_Reg(AFE_VOW_CFG1) */ reg_AFE_VOW_CFG1;
- pr_warn("%s() = %d\n", __func__, value);
+ pr_debug("%s() = %d\n", __func__, value);
ucontrol->value.integer.value[0] = value;
return 0;
}
static int Audio_Vow_Cfg1_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %ld\n", __func__, ucontrol->value.integer.value[0]);
+ pr_debug("%s() = %ld\n", __func__, ucontrol->value.integer.value[0]);
/* Ana_Set_Reg(AFE_VOW_CFG1, ucontrol->value.integer.value[0], 0xffff); */
reg_AFE_VOW_CFG1 = ucontrol->value.integer.value[0];
return 0;
@@ -4170,14 +4170,14 @@ static int Audio_Vow_Cfg2_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem
{
int value = /*Ana_Get_Reg(AFE_VOW_CFG2) */ reg_AFE_VOW_CFG2;
- pr_warn("%s() = %d\n", __func__, value);
+ pr_debug("%s() = %d\n", __func__, value);
ucontrol->value.integer.value[0] = value;
return 0;
}
static int Audio_Vow_Cfg2_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %ld\n", __func__, ucontrol->value.integer.value[0]);
+ pr_debug("%s() = %ld\n", __func__, ucontrol->value.integer.value[0]);
/* Ana_Set_Reg(AFE_VOW_CFG2, ucontrol->value.integer.value[0], 0xffff); */
reg_AFE_VOW_CFG2 = ucontrol->value.integer.value[0];
return 0;
@@ -4187,14 +4187,14 @@ static int Audio_Vow_Cfg3_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem
{
int value = /*Ana_Get_Reg(AFE_VOW_CFG3) */ reg_AFE_VOW_CFG3;
- pr_warn("%s() = %d\n", __func__, value);
+ pr_debug("%s() = %d\n", __func__, value);
ucontrol->value.integer.value[0] = value;
return 0;
}
static int Audio_Vow_Cfg3_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %ld\n", __func__, ucontrol->value.integer.value[0]);
+ pr_debug("%s() = %ld\n", __func__, ucontrol->value.integer.value[0]);
/* Ana_Set_Reg(AFE_VOW_CFG3, ucontrol->value.integer.value[0], 0xffff); */
reg_AFE_VOW_CFG3 = ucontrol->value.integer.value[0];
return 0;
@@ -4204,14 +4204,14 @@ static int Audio_Vow_Cfg4_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem
{
int value = /*Ana_Get_Reg(AFE_VOW_CFG4) */ reg_AFE_VOW_CFG4;
- pr_warn("%s() = %d\n", __func__, value);
+ pr_debug("%s() = %d\n", __func__, value);
ucontrol->value.integer.value[0] = value;
return 0;
}
static int Audio_Vow_Cfg4_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %ld\n", __func__, ucontrol->value.integer.value[0]);
+ pr_debug("%s() = %ld\n", __func__, ucontrol->value.integer.value[0]);
/* Ana_Set_Reg(AFE_VOW_CFG4, ucontrol->value.integer.value[0], 0xffff); */
reg_AFE_VOW_CFG4 = ucontrol->value.integer.value[0];
return 0;
@@ -4221,14 +4221,14 @@ static int Audio_Vow_Cfg5_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem
{
int value = /*Ana_Get_Reg(AFE_VOW_CFG5) */ reg_AFE_VOW_CFG5;
- pr_warn("%s() = %d\n", __func__, value);
+ pr_debug("%s() = %d\n", __func__, value);
ucontrol->value.integer.value[0] = value;
return 0;
}
static int Audio_Vow_Cfg5_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s() = %ld\n", __func__, ucontrol->value.integer.value[0]);
+ pr_debug("%s() = %ld\n", __func__, ucontrol->value.integer.value[0]);
/* Ana_Set_Reg(AFE_VOW_CFG5, ucontrol->value.integer.value[0], 0xffff); */
reg_AFE_VOW_CFG5 = ucontrol->value.integer.value[0];
return 0;
@@ -4238,14 +4238,14 @@ static int Audio_Vow_State_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_ele
{
int value = mIsVOWOn;
- pr_warn("%s() = %d\n", __func__, value);
+ pr_debug("%s() = %d\n", __func__, value);
ucontrol->value.integer.value[0] = value;
return 0;
}
static int Audio_Vow_State_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- /* pr_warn("%s() = %ld\n", __func__, ucontrol->value.integer.value[0]); */
+ /* pr_debug("%s() = %ld\n", __func__, ucontrol->value.integer.value[0]); */
/* reg_AFE_VOW_CFG5 = ucontrol->value.integer.value[0]; */
return 0;
}
@@ -4271,7 +4271,7 @@ static int32 Pmic_Loopback_Type;
static int Pmic_Loopback_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
ucontrol->value.integer.value[0] = Pmic_Loopback_Type;
return 0;
}
@@ -4327,21 +4327,21 @@ static int Pmic_Loopback_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_
/* turn on afe */
}
- pr_warn("%s() done\n", __func__);
+ pr_debug("%s() done\n", __func__);
Pmic_Loopback_Type = ucontrol->value.integer.value[0];
return 0;
}
static int SineTable_UL2_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
ucontrol->value.integer.value[0] = SineTable_UL2_flag;
return 0;
}
static int SineTable_DAC_HP_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
ucontrol->value.integer.value[0] = SineTable_DAC_HP_flag;
return 0;
}
@@ -4349,7 +4349,7 @@ static int SineTable_DAC_HP_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_el
static int SineTable_DAC_HP_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
/* 6752 TODO? */
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
return 0;
}
@@ -4361,14 +4361,14 @@ static void ADC_LOOP_DAC_Func(int command)
static bool DAC_LOOP_DAC_HS_flag;
static int ADC_LOOP_DAC_HS_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
ucontrol->value.integer.value[0] = DAC_LOOP_DAC_HS_flag;
return 0;
}
static int ADC_LOOP_DAC_HS_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.integer.value[0]) {
DAC_LOOP_DAC_HS_flag = ucontrol->value.integer.value[0];
ADC_LOOP_DAC_Func(AUDIO_ANALOG_DAC_LOOP_DAC_HS_ON);
@@ -4382,7 +4382,7 @@ static int ADC_LOOP_DAC_HS_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_ele
static bool DAC_LOOP_DAC_HP_flag;
static int ADC_LOOP_DAC_HP_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
ucontrol->value.integer.value[0] = DAC_LOOP_DAC_HP_flag;
return 0;
}
@@ -4390,7 +4390,7 @@ static int ADC_LOOP_DAC_HP_Get(struct snd_kcontrol *kcontrol, struct snd_ctl_ele
static int ADC_LOOP_DAC_HP_Set(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (ucontrol->value.integer.value[0]) {
DAC_LOOP_DAC_HP_flag = ucontrol->value.integer.value[0];
ADC_LOOP_DAC_Func(AUDIO_ANALOG_DAC_LOOP_DAC_HP_ON);
@@ -4405,7 +4405,7 @@ static bool Voice_Call_DAC_DAC_HS_flag;
static int Voice_Call_DAC_DAC_HS_Get(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
ucontrol->value.integer.value[0] = Voice_Call_DAC_DAC_HS_flag;
return 0;
}
@@ -4414,7 +4414,7 @@ static int Voice_Call_DAC_DAC_HS_Set(struct snd_kcontrol *kcontrol,
struct snd_ctl_elem_value *ucontrol)
{
/* 6752 TODO */
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
return 0;
}
@@ -4516,7 +4516,7 @@ static const struct snd_soc_dapm_route mtk_audio_map[] = {
static void mt6331_codec_init_reg(struct snd_soc_codec *codec)
{
- pr_warn("%s\n", __func__);
+ pr_debug("%s\n", __func__);
Ana_Set_Reg(TOP_CLKSQ, 0x0, 0x0001);
/* Disable CLKSQ 26MHz */
Ana_Set_Reg(AUDDEC_ANA_CON8, 0x0002, 0x0002);
@@ -4533,7 +4533,7 @@ static void mt6331_codec_init_reg(struct snd_soc_codec *codec)
void InitCodecDefault(void)
{
- pr_warn("%s\n", __func__);
+ pr_debug("%s\n", __func__);
mCodec_data->mAudio_Ana_Volume[AUDIO_ANALOG_VOLUME_MICAMP1] = 3;
mCodec_data->mAudio_Ana_Volume[AUDIO_ANALOG_VOLUME_MICAMP2] = 3;
mCodec_data->mAudio_Ana_Volume[AUDIO_ANALOG_VOLUME_MICAMP3] = 3;
@@ -4575,7 +4575,7 @@ static int mt6331_codec_probe(struct snd_soc_codec *codec)
{
struct snd_soc_dapm_context *dapm = &codec->dapm;
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
if (mInitCodec == true)
return 0;
@@ -4621,7 +4621,7 @@ static int mt6331_codec_probe(struct snd_soc_codec *codec)
static int mt6331_codec_remove(struct snd_soc_codec *codec)
{
- pr_warn("%s()\n", __func__);
+ pr_debug("%s()\n", __func__);
return 0;
}
@@ -4671,7 +4671,7 @@ static int mtk_mt6331_codec_dev_probe(struct platform_device *pdev)
dev_set_name(&pdev->dev, "%s", MT_SOC_CODEC_NAME);
- pr_warn("%s: dev name %s\n", __func__, dev_name(&pdev->dev));
+ pr_debug("%s: dev name %s\n", __func__, dev_name(&pdev->dev));
return snd_soc_register_codec(&pdev->dev,
&soc_mtk_codec, mtk_6331_dai_codecs,
ARRAY_SIZE(mtk_6331_dai_codecs));
@@ -4679,7 +4679,7 @@ static int mtk_mt6331_codec_dev_probe(struct platform_device *pdev)
static int mtk_mt6331_codec_dev_remove(struct platform_device *pdev)
{
- pr_warn("%s:\n", __func__);
+ pr_debug("%s:\n", __func__);
snd_soc_unregister_codec(&pdev->dev);
return 0;
@@ -4711,7 +4711,7 @@ static struct platform_device *soc_mtk_codec6331_dev;
static int __init mtk_mt6331_codec_init(void)
{
- pr_warn("%s:\n", __func__);
+ pr_debug("%s:\n", __func__);
#ifndef CONFIG_OF
int ret = 0;
@@ -4736,7 +4736,7 @@ module_init(mtk_mt6331_codec_init);
static void __exit mtk_mt6331_codec_exit(void)
{
- pr_warn("%s:\n", __func__);
+ pr_debug("%s:\n", __func__);
platform_driver_unregister(&mtk_codec_6331_driver);
}