diff options
author | Christian Pointner <equinox@helsinki.at> | 2024-05-10 18:26:46 (GMT) |
---|---|---|
committer | Christian Pointner <equinox@helsinki.at> | 2024-05-10 18:26:46 (GMT) |
commit | 627f7d488817e308d6f3a92fd9a877723ac7ae1d (patch) | |
tree | 554a3c53c90b20da5bd0da0c8da67a9b169bd10f /snd-alpx/alpx_variants_madi.h |
import snd-alpx V3.4.3
Diffstat (limited to 'snd-alpx/alpx_variants_madi.h')
-rw-r--r-- | snd-alpx/alpx_variants_madi.h | 89 |
1 files changed, 89 insertions, 0 deletions
diff --git a/snd-alpx/alpx_variants_madi.h b/snd-alpx/alpx_variants_madi.h new file mode 100644 index 0000000..d269e9f --- /dev/null +++ b/snd-alpx/alpx_variants_madi.h @@ -0,0 +1,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_ */ |