Revert "ASoC: bolero: check clock source before clock switch"
This reverts commit93bc6299f3
and6cc7f52a6d
. Change-Id: I614b650d6e071b9d1867988ebc88246b9fdc8f91 Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
This commit is contained in:
@@ -2725,36 +2725,6 @@ static int tx_macro_clk_div_get(struct snd_soc_component *component)
|
||||
return tx_priv->dmic_clk_div;
|
||||
}
|
||||
|
||||
static int tx_macro_clk_switch(struct snd_soc_component *component, int clk_src)
|
||||
{
|
||||
struct device *tx_dev = NULL;
|
||||
struct tx_macro_priv *tx_priv = NULL;
|
||||
int ret = 0;
|
||||
|
||||
if (!component)
|
||||
return -EINVAL;
|
||||
|
||||
tx_dev = bolero_get_device_ptr(component->dev, TX_MACRO);
|
||||
if (!tx_dev) {
|
||||
dev_err(component->dev,
|
||||
"%s: null device for macro!\n", __func__);
|
||||
return -EINVAL;
|
||||
}
|
||||
tx_priv = dev_get_drvdata(tx_dev);
|
||||
if (!tx_priv) {
|
||||
dev_err(component->dev,
|
||||
"%s: priv is null for macro!\n", __func__);
|
||||
return -EINVAL;
|
||||
}
|
||||
if (tx_priv->swr_ctrl_data) {
|
||||
ret = swrm_wcd_notify(
|
||||
tx_priv->swr_ctrl_data[0].tx_swr_pdev,
|
||||
SWR_REQ_CLK_SWITCH, &clk_src);
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
static int tx_macro_core_vote(void *handle, bool enable)
|
||||
{
|
||||
struct tx_macro_priv *tx_priv = (struct tx_macro_priv *) handle;
|
||||
@@ -3236,7 +3206,6 @@ static void tx_macro_init_ops(struct macro_ops *ops,
|
||||
ops->reg_wake_irq = tx_macro_reg_wake_irq;
|
||||
ops->set_port_map = tx_macro_set_port_map;
|
||||
ops->clk_div_get = tx_macro_clk_div_get;
|
||||
ops->clk_switch = tx_macro_clk_switch;
|
||||
ops->reg_evt_listener = tx_macro_register_event_listener;
|
||||
ops->clk_enable = __tx_macro_mclk_enable;
|
||||
}
|
||||
|
Reference in New Issue
Block a user