Loading sound/soc/msm/qdsp6v2/q6afe.c +3 −0 Original line number Diff line number Diff line Loading @@ -5143,6 +5143,9 @@ int afe_spk_prot_get_calib_data(struct afe_spkr_prot_get_vi_calib *calib_resp) pr_err("%s: Invalid params\n", __func__); goto fail_cmd; } if (this_afe.vi_tx_port != -1) port = this_afe.vi_tx_port; ret = q6audio_validate_port(port); if (ret < 0) { pr_err("%s: invalid port 0x%x ret %d\n", __func__, port, ret); Loading sound/soc/msm/qdsp6v2/q6audio-v2.c +7 −1 Original line number Diff line number Diff line /* Copyright (c) 2012-2015, The Linux Foundation. All rights reserved. /* Copyright (c) 2012-2016, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -218,6 +218,8 @@ int q6audio_get_port_index(u16 port_id) return IDX_AFE_PORT_ID_QUATERNARY_TDM_RX_7; case AFE_PORT_ID_QUATERNARY_TDM_TX_7: return IDX_AFE_PORT_ID_QUATERNARY_TDM_TX_7; case AFE_PORT_ID_SENARY_MI2S_TX: return IDX_AFE_PORT_ID_SENARY_MI2S_TX; default: return -EINVAL; } } Loading Loading @@ -421,6 +423,8 @@ int q6audio_get_port_id(u16 port_id) return AFE_PORT_ID_QUATERNARY_TDM_RX_7; case AFE_PORT_ID_QUATERNARY_TDM_TX_7: return AFE_PORT_ID_QUATERNARY_TDM_TX_7; case AFE_PORT_ID_SENARY_MI2S_TX: return AFE_PORT_ID_SENARY_MI2S_TX; default: pr_warn("%s: Invalid port_id %d\n", __func__, port_id); return -EINVAL; Loading Loading @@ -538,6 +542,7 @@ int q6audio_is_digital_pcm_interface(u16 port_id) case AFE_PORT_ID_QUATERNARY_TDM_TX_6: case AFE_PORT_ID_QUATERNARY_TDM_RX_7: case AFE_PORT_ID_QUATERNARY_TDM_TX_7: case AFE_PORT_ID_SENARY_MI2S_TX: break; default: ret = -EINVAL; Loading Loading @@ -666,6 +671,7 @@ int q6audio_validate_port(u16 port_id) case AFE_PORT_ID_QUATERNARY_TDM_TX_6: case AFE_PORT_ID_QUATERNARY_TDM_RX_7: case AFE_PORT_ID_QUATERNARY_TDM_TX_7: case AFE_PORT_ID_SENARY_MI2S_TX: { ret = 0; break; Loading Loading
sound/soc/msm/qdsp6v2/q6afe.c +3 −0 Original line number Diff line number Diff line Loading @@ -5143,6 +5143,9 @@ int afe_spk_prot_get_calib_data(struct afe_spkr_prot_get_vi_calib *calib_resp) pr_err("%s: Invalid params\n", __func__); goto fail_cmd; } if (this_afe.vi_tx_port != -1) port = this_afe.vi_tx_port; ret = q6audio_validate_port(port); if (ret < 0) { pr_err("%s: invalid port 0x%x ret %d\n", __func__, port, ret); Loading
sound/soc/msm/qdsp6v2/q6audio-v2.c +7 −1 Original line number Diff line number Diff line /* Copyright (c) 2012-2015, The Linux Foundation. All rights reserved. /* Copyright (c) 2012-2016, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -218,6 +218,8 @@ int q6audio_get_port_index(u16 port_id) return IDX_AFE_PORT_ID_QUATERNARY_TDM_RX_7; case AFE_PORT_ID_QUATERNARY_TDM_TX_7: return IDX_AFE_PORT_ID_QUATERNARY_TDM_TX_7; case AFE_PORT_ID_SENARY_MI2S_TX: return IDX_AFE_PORT_ID_SENARY_MI2S_TX; default: return -EINVAL; } } Loading Loading @@ -421,6 +423,8 @@ int q6audio_get_port_id(u16 port_id) return AFE_PORT_ID_QUATERNARY_TDM_RX_7; case AFE_PORT_ID_QUATERNARY_TDM_TX_7: return AFE_PORT_ID_QUATERNARY_TDM_TX_7; case AFE_PORT_ID_SENARY_MI2S_TX: return AFE_PORT_ID_SENARY_MI2S_TX; default: pr_warn("%s: Invalid port_id %d\n", __func__, port_id); return -EINVAL; Loading Loading @@ -538,6 +542,7 @@ int q6audio_is_digital_pcm_interface(u16 port_id) case AFE_PORT_ID_QUATERNARY_TDM_TX_6: case AFE_PORT_ID_QUATERNARY_TDM_RX_7: case AFE_PORT_ID_QUATERNARY_TDM_TX_7: case AFE_PORT_ID_SENARY_MI2S_TX: break; default: ret = -EINVAL; Loading Loading @@ -666,6 +671,7 @@ int q6audio_validate_port(u16 port_id) case AFE_PORT_ID_QUATERNARY_TDM_TX_6: case AFE_PORT_ID_QUATERNARY_TDM_RX_7: case AFE_PORT_ID_QUATERNARY_TDM_TX_7: case AFE_PORT_ID_SENARY_MI2S_TX: { ret = 0; break; Loading