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

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

Merge "ASoC: DPCM: make some DPCM API calls non static for compressed usage"

parents b20a8365 23fd5bff
Loading
Loading
Loading
Loading
+19 −0
Original line number Diff line number Diff line
@@ -12,6 +12,7 @@
#define __LINUX_SND_SOC_DPCM_H

#include <linux/list.h>
#include <linux/slab.h>
#include <sound/pcm.h>

struct snd_soc_pcm_runtime;
@@ -135,4 +136,22 @@ int soc_dpcm_be_digital_mute(struct snd_soc_pcm_runtime *fe, int mute);
int soc_dpcm_debugfs_add(struct snd_soc_pcm_runtime *rtd);
int soc_dpcm_runtime_update(struct snd_soc_dapm_widget *);

int dpcm_path_get(struct snd_soc_pcm_runtime *fe,
	int stream, struct snd_soc_dapm_widget_list **list_);
int dpcm_process_paths(struct snd_soc_pcm_runtime *fe,
	int stream, struct snd_soc_dapm_widget_list **list, int new);
int dpcm_be_dai_startup(struct snd_soc_pcm_runtime *fe, int stream);
int dpcm_be_dai_shutdown(struct snd_soc_pcm_runtime *fe, int stream);
void dpcm_be_disconnect(struct snd_soc_pcm_runtime *fe, int stream);
void dpcm_clear_pending_state(struct snd_soc_pcm_runtime *fe, int stream);
int dpcm_be_dai_hw_free(struct snd_soc_pcm_runtime *fe, int stream);
int dpcm_be_dai_hw_params(struct snd_soc_pcm_runtime *fe, int tream);
int dpcm_be_dai_trigger(struct snd_soc_pcm_runtime *fe, int stream, int cmd);
int dpcm_be_dai_prepare(struct snd_soc_pcm_runtime *fe, int stream);

static inline void dpcm_path_put(struct snd_soc_dapm_widget_list **list)
{
	kfree(*list);
}

#endif
+10 −16
Original line number Diff line number Diff line
@@ -793,7 +793,7 @@ static void dpcm_be_reparent(struct snd_soc_pcm_runtime *fe,
}

/* disconnect a BE and FE */
static void dpcm_be_disconnect(struct snd_soc_pcm_runtime *fe, int stream)
void dpcm_be_disconnect(struct snd_soc_pcm_runtime *fe, int stream)
{
	struct snd_soc_dpcm *dpcm, *d;

@@ -889,7 +889,7 @@ static int widget_in_list(struct snd_soc_dapm_widget_list *list,
	return 0;
}

static int dpcm_path_get(struct snd_soc_pcm_runtime *fe,
int dpcm_path_get(struct snd_soc_pcm_runtime *fe,
	int stream, struct snd_soc_dapm_widget_list **list_)
{
	struct snd_soc_dai *cpu_dai = fe->cpu_dai;
@@ -911,11 +911,6 @@ static int dpcm_path_get(struct snd_soc_pcm_runtime *fe,
	return paths;
}

static inline void dpcm_path_put(struct snd_soc_dapm_widget_list **list)
{
	kfree(*list);
}

static int dpcm_prune_paths(struct snd_soc_pcm_runtime *fe, int stream,
	struct snd_soc_dapm_widget_list **list_)
{
@@ -1010,7 +1005,7 @@ static int dpcm_add_paths(struct snd_soc_pcm_runtime *fe, int stream,
 * Find the corresponding BE DAIs that source or sink audio to this
 * FE substream.
 */
static int dpcm_process_paths(struct snd_soc_pcm_runtime *fe,
int dpcm_process_paths(struct snd_soc_pcm_runtime *fe,
	int stream, struct snd_soc_dapm_widget_list **list, int new)
{
	if (new)
@@ -1019,7 +1014,7 @@ static int dpcm_process_paths(struct snd_soc_pcm_runtime *fe,
		return dpcm_prune_paths(fe, stream, list);
}

static void dpcm_clear_pending_state(struct snd_soc_pcm_runtime *fe, int stream)
void dpcm_clear_pending_state(struct snd_soc_pcm_runtime *fe, int stream)
{
	struct snd_soc_dpcm *dpcm;

@@ -1057,7 +1052,7 @@ static void dpcm_be_dai_startup_unwind(struct snd_soc_pcm_runtime *fe,
	}
}

static int dpcm_be_dai_startup(struct snd_soc_pcm_runtime *fe, int stream)
int dpcm_be_dai_startup(struct snd_soc_pcm_runtime *fe, int stream)
{
	struct snd_soc_dpcm *dpcm;
	int err, count = 0;
@@ -1199,7 +1194,7 @@ be_err:
	return ret;
}

static int dpcm_be_dai_shutdown(struct snd_soc_pcm_runtime *fe, int stream)
int dpcm_be_dai_shutdown(struct snd_soc_pcm_runtime *fe, int stream)
{
	struct snd_soc_dpcm *dpcm;

@@ -1260,7 +1255,7 @@ static int dpcm_fe_dai_shutdown(struct snd_pcm_substream *substream)
	return 0;
}

static int dpcm_be_dai_hw_free(struct snd_soc_pcm_runtime *fe, int stream)
int dpcm_be_dai_hw_free(struct snd_soc_pcm_runtime *fe, int stream)
{
	struct snd_soc_dpcm *dpcm;

@@ -1325,7 +1320,7 @@ static int dpcm_fe_dai_hw_free(struct snd_pcm_substream *substream)
	return 0;
}

static int dpcm_be_dai_hw_params(struct snd_soc_pcm_runtime *fe, int stream)
int dpcm_be_dai_hw_params(struct snd_soc_pcm_runtime *fe, int stream)
{
	struct snd_soc_dpcm *dpcm;
	int ret;
@@ -1455,8 +1450,7 @@ static int dpcm_do_trigger(struct snd_soc_dpcm *dpcm,
	return ret;
}

static int dpcm_be_dai_trigger(struct snd_soc_pcm_runtime *fe, int stream,
			       int cmd)
int dpcm_be_dai_trigger(struct snd_soc_pcm_runtime *fe, int stream, int cmd)
{
	struct snd_soc_dpcm *dpcm;
	int ret = 0;
@@ -1625,7 +1619,7 @@ out:
	return ret;
}

static int dpcm_be_dai_prepare(struct snd_soc_pcm_runtime *fe, int stream)
int dpcm_be_dai_prepare(struct snd_soc_pcm_runtime *fe, int stream)
{
	struct snd_soc_dpcm *dpcm;
	int ret = 0;