1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
|
// SPDX-License-Identifier: GPL-2.0-or-later
/*
* Support for Digigram AlpX PCI-e boards
*
* Copyright (c) 2024 Digigram Digital (info@digigram.com)
*/
#ifndef _ALPX_VARIANTS_MADI_H_
#define _ALPX_VARIANTS_MADI_H_
#include "alpx.h"
#include "alpx_reg.h"
#include <sound/tlv.h>
#include "alpx_variants_common.h"
/* MADI */
static struct snd_pcm_hardware alpmadi_hardware_specs = {
.info = SNDRV_PCM_INFO_MMAP |
SNDRV_PCM_INFO_MMAP_VALID |
SNDRV_PCM_INFO_INTERLEAVED |
SNDRV_PCM_INFO_BLOCK_TRANSFER |
SNDRV_PCM_INFO_RESUME,
.formats = SNDRV_PCM_FMTBIT_S32_LE,
.rates = SNDRV_PCM_RATE_CONTINUOUS |
SNDRV_PCM_RATE_8000_192000,
.rate_min = 8000,
.rate_max = 192000,
.channels_min = 64,
.channels_max = 64,
.buffer_bytes_max = SZ_1M * 4, /* period_bytes_max * periods_max */
.period_bytes_min = 48, /* min latency 1ms */
.period_bytes_max = SZ_1M, /* 20ms at 192kHz * nchans * 4B, rounded at 2^n */
.periods_min = 1,
.periods_max = 4,
};
/* Alp MADI Variant */
static struct alpx_variant alpx_madi_variant __attribute__((unused)) = {
.shortname = "AlpMADI",
.longname = "Alp MADI",
.model = ALPX_VARIANT_MODEL_MADI,
.mixername = "AlpX-MADI_Mix",
.capture_hw = &alpmadi_hardware_specs,
.playback_hw = &alpmadi_hardware_specs,
.gpios = {
.base = 0,
.inputs_reg_offset = 0,
.inputs_qty = 0,
.outputs_reg_offset = 0,
.outputs_qty = 0,
},
.flash_golden_production_base = ALPxxx_FLASH_GOLDEN_PRODUCTION_BASE,
.flash_partitions.partitions = alpx_mtd_partitions,
.flash_partitions.qty = ARRAY_SIZE(alpx_mtd_partitions),
.flash_partitions.qty_for_fw_update = 1,
};
/* Alp MADI Loopback */
static struct alpx_variant alpx_madi_loopback_variant __attribute__((unused)) = {
.shortname = "AlpLoopback",
.longname = "Alp Loopback",
.model = ALPX_VARIANT_MODEL_MADI_LOOPBACK,
.mixername = "AlpX-MADI-Loopback_Mix",
.capture_hw = &alpmadi_hardware_specs,
.playback_hw = &alpmadi_hardware_specs,
.flash_golden_production_base = ALPxxx_FLASH_GOLDEN_PRODUCTION_BASE,
.gpios = {
.base = 0,
.inputs_reg_offset = 0,
.inputs_qty = 0,
.outputs_reg_offset = 0,
.outputs_qty = 0,
},
.flash_partitions.partitions = alpx_mtd_partitions,
.flash_partitions.qty = ARRAY_SIZE(alpx_mtd_partitions),
.flash_partitions.qty_for_fw_update = 1,
};
#endif /* _ALPX_VARIANTS_MADI_H_ */
|