summaryrefslogtreecommitdiffstats
path: root/dummy
diff options
context:
space:
mode:
authorMark Farrugia <mark.farrugia@fiberdyne.com.au>2018-10-25 17:37:07 +1100
committerMark Farrugia <mark.farrugia@fiberdyne.com.au>2018-10-26 17:27:50 +1100
commitd66dbf0820e9e7e14a6f723c1ce92b7ac4e0280d (patch)
treea63bb7dea2279c61cdfa52c78d3b889e6e0c8869 /dummy
parentd8ff159e37cb3768358b350b2dc80118d81d4b2c (diff)
Refactor all avirt_ symbols to have have snd prefix, as per Linux sound
This will aid the eventual migration the the upstream mainline Linux kernel Fix some checkpatch warnings, and other compiler warnings Signed-off-by: Mark Farrugia <mark.farrugia@fiberdyne.com.au>
Diffstat (limited to 'dummy')
-rw-r--r--dummy/Makefile4
-rw-r--r--dummy/dummy.c22
2 files changed, 13 insertions, 13 deletions
diff --git a/dummy/Makefile b/dummy/Makefile
index 78579d7..11ceceb 100644
--- a/dummy/Makefile
+++ b/dummy/Makefile
@@ -1,6 +1,6 @@
-obj-$(CONFIG_AVIRT_DUMMYAP) += avirt_dummyap.o
+obj-$(CONFIG_AVIRT_AP_DUMMY) += snd-avirt-ap-dummy.o
$(info $(src))
-avirt_dummyap-objs := dummy.o
+snd-avirt-ap-dummy-objs := dummy.o
ccflags-y += -Idrivers/staging/
ccflags-y += -I$(src)/../
diff --git a/dummy/dummy.c b/dummy/dummy.c
index 100972a..5f19564 100644
--- a/dummy/dummy.c
+++ b/dummy/dummy.c
@@ -34,7 +34,7 @@ MODULE_LICENSE("GPL v2");
#define get_dummy_ops(substream) \
(*(const struct dummy_timer_ops **)(substream)->runtime->private_data)
-static struct avirt_coreinfo *coreinfo;
+static struct snd_avirt_coreinfo *coreinfo;
/*******************************************************************************
* System Timer Interface
@@ -140,7 +140,7 @@ static void dummy_systimer_callback(struct timer_list *t)
dpcm->elapsed = 0;
spin_unlock_irqrestore(&dpcm->lock, flags);
if (elapsed)
- avirt_pcm_period_elapsed(dpcm->substream);
+ snd_avirt_pcm_period_elapsed(dpcm->substream);
}
static snd_pcm_uframes_t
@@ -241,18 +241,18 @@ static struct snd_pcm_ops dummyap_pcm_ops = {
/*******************************************************************************
* Dummy Audio Path AVIRT registration
******************************************************************************/
-int dummy_configure(struct snd_card *card,
- struct config_group *avirt_stream_group,
- unsigned int stream_count)
+static int dummy_configure(struct snd_card *card,
+ struct config_group *snd_avirt_stream_group,
+ unsigned int stream_count)
{
// Do something with streams
struct list_head *entry;
- list_for_each (entry, &avirt_stream_group->cg_children) {
+ list_for_each (entry, &snd_avirt_stream_group->cg_children) {
struct config_item *item =
container_of(entry, struct config_item, ci_entry);
- struct avirt_stream *stream =
- avirt_stream_from_config_item(item);
+ struct snd_avirt_stream *stream =
+ snd_avirt_stream_from_config_item(item);
AP_INFOK("stream name:%s device:%d channels:%d", stream->name,
stream->device, stream->channels);
}
@@ -272,7 +272,7 @@ static struct snd_pcm_hardware dummyap_hw = {
.periods_max = DUMMY_PERIODS_MAX,
};
-static struct avirt_audiopath dummyap_module = {
+static struct snd_avirt_audiopath dummyap_module = {
.uid = "ap_dummy",
.name = "Dummy Audio Path",
.version = { 0, 0, 1 },
@@ -287,7 +287,7 @@ static int __init dummy_init(void)
pr_info("init()\n");
- err = avirt_audiopath_register(&dummyap_module, &coreinfo);
+ err = snd_avirt_audiopath_register(&dummyap_module, &coreinfo);
if ((err < 0) || (!coreinfo)) {
pr_err("%s: coreinfo is NULL!\n", __func__);
return err;
@@ -300,7 +300,7 @@ static void __exit dummy_exit(void)
{
pr_info("exit()\n");
- avirt_audiopath_deregister(&dummyap_module);
+ snd_avirt_audiopath_deregister(&dummyap_module);
}
module_init(dummy_init);