// SPDX-License-Identifier: GPL-2.0-only // This file incorporates work covered by the following copyright notice: // Copyright (c) 2023 Intel Corporation // Copyright (c) 2024 Advanced Micro Devices, Inc.
/* * soc_sdw_cs_amp - Helpers to handle CS35L56 from generic machine driver
*/
ret = snd_soc_limit_volume(card, volume_ctl_name, CS35L56_SPK_VOLUME_0DB); if (ret)
dev_err(card->dev, "%s limit set failed: %d\n", volume_ctl_name, ret);
/* * CS35L56 has 4 TX channels. When the capture is aggregated the * same bus slots will be allocated to all the amps on a bus. Only * one amp on that bus can be transmitting in each slot so divide * the available 4 slots between all the amps on a bus.
*/
amps_per_bus = dai_link->num_codecs / dai_link->num_cpus; if ((amps_per_bus == 0) || (amps_per_bus > CS_AMP_CHANNELS_PER_AMP)) {
dev_err(rtd->card->dev, "Illegal num_codecs:%u / num_cpus:%u\n",
dai_link->num_codecs, dai_link->num_cpus); return -EINVAL;
}
int asoc_sdw_cs_amp_init(struct snd_soc_card *card, struct snd_soc_dai_link *dai_links, struct asoc_sdw_codec_info *info, bool playback)
{ /* Do init on playback link only. */ if (!playback) return 0;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.