linux/sound/soc/qcom/qdsp6/q6apm.c

// SPDX-License-Identifier: GPL-2.0
// Copyright (c) 2020, Linaro Limited

#include <dt-bindings/soc/qcom,gpr.h>
#include <linux/delay.h>
#include <linux/jiffies.h>
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/of.h>
#include <linux/of_platform.h>
#include <linux/sched.h>
#include <linux/slab.h>
#include <linux/soc/qcom/apr.h>
#include <linux/wait.h>
#include <sound/soc.h>
#include <sound/soc-dapm.h>
#include <sound/pcm.h>
#include "audioreach.h"
#include "q6apm.h"

/* Graph Management */
struct apm_graph_mgmt_cmd {} __packed;

#define APM_GRAPH_MGMT_PSIZE(p, n)

static struct q6apm *g_apm;

int q6apm_send_cmd_sync(struct q6apm *apm, struct gpr_pkt *pkt, uint32_t rsp_opcode)
{}

static struct audioreach_graph *q6apm_get_audioreach_graph(struct q6apm *apm, uint32_t graph_id)
{}

static int audioreach_graph_mgmt_cmd(struct audioreach_graph *graph, uint32_t opcode)
{}

static void q6apm_put_audioreach_graph(struct kref *ref)
{}


static int q6apm_get_apm_state(struct q6apm *apm)
{}

bool q6apm_is_adsp_ready(void)
{}
EXPORT_SYMBOL_GPL();

static struct audioreach_module *__q6apm_find_module_by_mid(struct q6apm *apm,
						    struct audioreach_graph_info *info,
						    uint32_t mid)
{}

int q6apm_graph_media_format_shmem(struct q6apm_graph *graph,
				   struct audioreach_module_config *cfg)
{}
EXPORT_SYMBOL_GPL();

int q6apm_map_memory_regions(struct q6apm_graph *graph, unsigned int dir, phys_addr_t phys,
			     size_t period_sz, unsigned int periods)
{}
EXPORT_SYMBOL_GPL();

int q6apm_unmap_memory_regions(struct q6apm_graph *graph, unsigned int dir)
{}
EXPORT_SYMBOL_GPL();

int q6apm_remove_initial_silence(struct device *dev, struct q6apm_graph *graph, uint32_t samples)
{}
EXPORT_SYMBOL_GPL();

int q6apm_remove_trailing_silence(struct device *dev, struct q6apm_graph *graph, uint32_t samples)
{}
EXPORT_SYMBOL_GPL();

int q6apm_enable_compress_module(struct device *dev, struct q6apm_graph *graph, bool en)
{}
EXPORT_SYMBOL_GPL();

int q6apm_set_real_module_id(struct device *dev, struct q6apm_graph *graph,
			     uint32_t codec_id)
{}
EXPORT_SYMBOL_GPL();

int q6apm_graph_media_format_pcm(struct q6apm_graph *graph, struct audioreach_module_config *cfg)
{}
EXPORT_SYMBOL_GPL();

static int q6apm_graph_get_tx_shmem_module_iid(struct q6apm_graph *graph)
{}

int q6apm_graph_get_rx_shmem_module_iid(struct q6apm_graph *graph)
{}
EXPORT_SYMBOL_GPL();

int q6apm_write_async(struct q6apm_graph *graph, uint32_t len, uint32_t msw_ts,
		      uint32_t lsw_ts, uint32_t wflags)
{}
EXPORT_SYMBOL_GPL();

int q6apm_read(struct q6apm_graph *graph)
{}
EXPORT_SYMBOL_GPL();

static int graph_callback(struct gpr_resp_pkt *data, void *priv, int op)
{}

struct q6apm_graph *q6apm_graph_open(struct device *dev, q6apm_cb cb,
				     void *priv, int graph_id)
{}
EXPORT_SYMBOL_GPL();

int q6apm_graph_close(struct q6apm_graph *graph)
{}
EXPORT_SYMBOL_GPL();

int q6apm_graph_prepare(struct q6apm_graph *graph)
{}
EXPORT_SYMBOL_GPL();

int q6apm_graph_start(struct q6apm_graph *graph)
{}
EXPORT_SYMBOL_GPL();

int q6apm_graph_stop(struct q6apm_graph *graph)
{}
EXPORT_SYMBOL_GPL();

int q6apm_graph_flush(struct q6apm_graph *graph)
{}
EXPORT_SYMBOL_GPL();

static int q6apm_audio_probe(struct snd_soc_component *component)
{}

static void q6apm_audio_remove(struct snd_soc_component *component)
{}

#define APM_AUDIO_DRV_NAME

static const struct snd_soc_component_driver q6apm_audio_component =;

static int apm_probe(gpr_device_t *gdev)
{}

struct audioreach_module *q6apm_find_module_by_mid(struct q6apm_graph *graph, uint32_t mid)
{}

static int apm_callback(struct gpr_resp_pkt *data, void *priv, int op)
{}

#ifdef CONFIG_OF
static const struct of_device_id apm_device_id[]  =;
MODULE_DEVICE_TABLE(of, apm_device_id);
#endif

static gpr_driver_t apm_driver =;

module_gpr_driver();
MODULE_DESCRIPTION();
MODULE_LICENSE();