Loading sound/soc/msm/sdm660-common.c +9 −0 Original line number Diff line number Diff line Loading @@ -44,6 +44,8 @@ enum { EXT_DISP_RX_IDX_MAX, }; bool codec_reg_done; /* TDM default config */ static struct dev_config tdm_rx_cfg[TDM_INTERFACE_MAX][TDM_PORT_MAX] = { { /* PRI TDM */ Loading Loading @@ -2016,6 +2018,12 @@ int msm_common_snd_controls_size(void) } EXPORT_SYMBOL(msm_common_snd_controls_size); void msm_set_codec_reg_done(bool done) { codec_reg_done = done; } EXPORT_SYMBOL(msm_set_codec_reg_done); static inline int param_is_mask(int p) { return (p >= SNDRV_PCM_HW_PARAM_FIRST_MASK) && Loading Loading @@ -3050,6 +3058,7 @@ static int msm_asoc_machine_probe(struct platform_device *pdev) if (!pdata) return -ENOMEM; msm_set_codec_reg_done(false); match = of_match_node(sdm660_asoc_machine_of_match, pdev->dev.of_node); if (!match) Loading sound/soc/msm/sdm660-common.h +1 −0 Original line number Diff line number Diff line Loading @@ -122,4 +122,5 @@ void msm_aux_pcm_snd_shutdown(struct snd_pcm_substream *substream); int msm_mi2s_snd_startup(struct snd_pcm_substream *substream); void msm_mi2s_snd_shutdown(struct snd_pcm_substream *substream); int msm_common_snd_controls_size(void); void msm_set_codec_reg_done(bool done); #endif sound/soc/msm/sdm660-external.c +2 −6 Original line number Diff line number Diff line Loading @@ -55,7 +55,6 @@ static int msm_ext_spk_control = 1; static struct wcd_mbhc_config *wcd_mbhc_cfg_ptr; bool codec_reg_done; struct msm_asoc_wcd93xx_codec { void* (*get_afe_config_fn)(struct snd_soc_codec *codec, Loading Loading @@ -1771,7 +1770,6 @@ int msm_audrx_init(struct snd_soc_pcm_runtime *rtd) if (!entry) { pr_debug("%s: Cannot create codecs module entry\n", __func__); pdata->codec_root = NULL; goto done; } pdata->codec_root = entry; Loading @@ -1794,18 +1792,16 @@ int msm_audrx_init(struct snd_soc_pcm_runtime *rtd) if (!entry) { pr_debug("%s: Cannot create codecs module entry\n", __func__); ret = 0; goto err_snd_module; goto done; } pdata->codec_root = entry; tasha_codec_info_create_codec_entry(pdata->codec_root, codec); tasha_mbhc_zdet_gpio_ctrl(msm_config_hph_en0_gpio, rtd->codec); } codec_reg_done = true; done: msm_set_codec_reg_done(true); return 0; err_snd_module: err_afe_cfg: return ret; } Loading sound/soc/msm/sdm660-internal.c +1 −0 Original line number Diff line number Diff line Loading @@ -1314,6 +1314,7 @@ static int msm_audrx_init(struct snd_soc_pcm_runtime *rtd) msm_dig_codec_info_create_codec_entry(codec_root, dig_cdc); msm_anlg_codec_info_create_codec_entry(codec_root, ana_cdc); done: msm_set_codec_reg_done(true); return 0; } Loading Loading
sound/soc/msm/sdm660-common.c +9 −0 Original line number Diff line number Diff line Loading @@ -44,6 +44,8 @@ enum { EXT_DISP_RX_IDX_MAX, }; bool codec_reg_done; /* TDM default config */ static struct dev_config tdm_rx_cfg[TDM_INTERFACE_MAX][TDM_PORT_MAX] = { { /* PRI TDM */ Loading Loading @@ -2016,6 +2018,12 @@ int msm_common_snd_controls_size(void) } EXPORT_SYMBOL(msm_common_snd_controls_size); void msm_set_codec_reg_done(bool done) { codec_reg_done = done; } EXPORT_SYMBOL(msm_set_codec_reg_done); static inline int param_is_mask(int p) { return (p >= SNDRV_PCM_HW_PARAM_FIRST_MASK) && Loading Loading @@ -3050,6 +3058,7 @@ static int msm_asoc_machine_probe(struct platform_device *pdev) if (!pdata) return -ENOMEM; msm_set_codec_reg_done(false); match = of_match_node(sdm660_asoc_machine_of_match, pdev->dev.of_node); if (!match) Loading
sound/soc/msm/sdm660-common.h +1 −0 Original line number Diff line number Diff line Loading @@ -122,4 +122,5 @@ void msm_aux_pcm_snd_shutdown(struct snd_pcm_substream *substream); int msm_mi2s_snd_startup(struct snd_pcm_substream *substream); void msm_mi2s_snd_shutdown(struct snd_pcm_substream *substream); int msm_common_snd_controls_size(void); void msm_set_codec_reg_done(bool done); #endif
sound/soc/msm/sdm660-external.c +2 −6 Original line number Diff line number Diff line Loading @@ -55,7 +55,6 @@ static int msm_ext_spk_control = 1; static struct wcd_mbhc_config *wcd_mbhc_cfg_ptr; bool codec_reg_done; struct msm_asoc_wcd93xx_codec { void* (*get_afe_config_fn)(struct snd_soc_codec *codec, Loading Loading @@ -1771,7 +1770,6 @@ int msm_audrx_init(struct snd_soc_pcm_runtime *rtd) if (!entry) { pr_debug("%s: Cannot create codecs module entry\n", __func__); pdata->codec_root = NULL; goto done; } pdata->codec_root = entry; Loading @@ -1794,18 +1792,16 @@ int msm_audrx_init(struct snd_soc_pcm_runtime *rtd) if (!entry) { pr_debug("%s: Cannot create codecs module entry\n", __func__); ret = 0; goto err_snd_module; goto done; } pdata->codec_root = entry; tasha_codec_info_create_codec_entry(pdata->codec_root, codec); tasha_mbhc_zdet_gpio_ctrl(msm_config_hph_en0_gpio, rtd->codec); } codec_reg_done = true; done: msm_set_codec_reg_done(true); return 0; err_snd_module: err_afe_cfg: return ret; } Loading
sound/soc/msm/sdm660-internal.c +1 −0 Original line number Diff line number Diff line Loading @@ -1314,6 +1314,7 @@ static int msm_audrx_init(struct snd_soc_pcm_runtime *rtd) msm_dig_codec_info_create_codec_entry(codec_root, dig_cdc); msm_anlg_codec_info_create_codec_entry(codec_root, ana_cdc); done: msm_set_codec_reg_done(true); return 0; } Loading