diff options
author | Mark Farrugia <mark.farrugia@fiberdyne.com.au> | 2018-09-05 14:53:53 +1000 |
---|---|---|
committer | Mark Farrugia <mark.farrugia@fiberdyne.com.au> | 2018-10-26 17:27:32 +1100 |
commit | 4e675e7d45af2fab1ab8d8a6e8d0c86bc4a2a960 (patch) | |
tree | 4a6d1390845f13eff77076fd0340f8f82e743cd1 /core.h | |
parent | 8be23a7c5fafd44296962620299569bf70529f3d (diff) |
Move ALSA info into coreinfo, for export to Audio Paths
Remove the avirt_alsa_driver
Signed-off-by: Mark Farrugia <mark.farrugia@fiberdyne.com.au>
Diffstat (limited to 'core.h')
-rw-r--r-- | core.h | 38 |
1 files changed, 26 insertions, 12 deletions
@@ -12,16 +12,7 @@ #include <sound/pcm.h> -#define DINFO(ap, fmt, args...) \ - printk(KERN_INFO "[%s]: %d:%s " fmt "\n", ap, __LINE__, __func__, \ - ##args) - -#define DERROR(ap, fmt, args...) \ - printk(KERN_ERR "[%s]: %d:%s " fmt "\n", ap, __LINE__, __func__, ##args) - -#define DPRINT(ap, fmt, args...) \ - printk(KERN_DEBUG "[%s]: %d:%s " fmt "\n", ap, __LINE__, __func__, \ - ##args) +#define MAX_NAME_LEN 32 /** * PCM buffer complete callback @@ -31,6 +22,9 @@ */ typedef int (*avirt_buff_complete)(struct snd_pcm_substream *substream); +/** + * AVIRT Audio Path info + */ struct avirt_audiopath { const char *name; unsigned version[3]; @@ -41,10 +35,30 @@ struct avirt_audiopath { void *context; }; +/* + * ALSA Substream device configuration + */ +struct avirt_alsa_devconfig { + const char devicename[MAX_NAME_LEN]; + int channels; +}; + +/** + * Collection of ALSA devices + */ +struct avirt_alsa_group { + struct avirt_alsa_devconfig *config; + int devices; +}; + +/** + * AVIRT core info + */ struct avirt_coreinfo { unsigned version[3]; - unsigned playback_num; - unsigned capture_num; + + struct avirt_alsa_group playback; + struct avirt_alsa_group capture; avirt_buff_complete pcm_buff_complete; }; |