Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit adc801c2 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "ASoC: msmcobalt: remove custom PM QoS for Low-latency playback"

parents 514b9da1 fb39a8c3
Loading
Loading
Loading
Loading
+0 −27
Original line number Diff line number Diff line
@@ -2042,32 +2042,6 @@ static struct snd_soc_ops msm_wcn_ops = {
	.hw_params = msm_wcn_hw_params,
};

static int msm_get_ll_qos_val(struct snd_pcm_runtime *runtime)
{
	int usecs;

	/* take 10% of period time as the deadline */
	usecs = (100000 / runtime->rate) * runtime->period_size;
	usecs += ((100000 % runtime->rate) * runtime->period_size) /
		runtime->rate;

	return usecs;
}

static int msm_mm5_prepare(struct snd_pcm_substream *substream)
{
	if (pm_qos_request_active(&substream->latency_pm_qos_req))
		pm_qos_remove_request(&substream->latency_pm_qos_req);
	pm_qos_add_request(&substream->latency_pm_qos_req,
			   PM_QOS_CPU_DMA_LATENCY,
			   msm_get_ll_qos_val(substream->runtime));
	return 0;
}

static struct snd_soc_ops msm_mm5_ops = {
	.prepare = msm_mm5_prepare,
};

/* Digital audio interface glue - connects codec <---> CPU */
static struct snd_soc_dai_link msm_common_dai_links[] = {
	/* FrontEnd DAI Links */
@@ -2300,7 +2274,6 @@ static struct snd_soc_dai_link msm_common_dai_links[] = {
		/* this dainlink has playback support */
		.ignore_pmdown_time = 1,
		.be_id = MSM_FRONTEND_DAI_MULTIMEDIA5,
		.ops = &msm_mm5_ops,
	},
	{
		.name = "Listen 1 Audio Service",