| 78d39246 | 09-Dec-2023 |
Cristian Ciocaltea <cristian.ciocaltea@collabora.com> |
ASoC: amd: vangogh: Switch to {RUNTIME,SYSTEM_SLEEP}_PM_OPS
Replace the old SET_{RUNTIME,SYSTEM_SLEEP}_PM_OPS() helpers with their modern alternatives and drop the now unnecessary __maybe_unused qua
ASoC: amd: vangogh: Switch to {RUNTIME,SYSTEM_SLEEP}_PM_OPS
Replace the old SET_{RUNTIME,SYSTEM_SLEEP}_PM_OPS() helpers with their modern alternatives and drop the now unnecessary __maybe_unused qualifier in the suspend and resume functions.
Additionally, make use of pm_ptr() to ensure the PM ops are dropped when building with CONFIG_PM disabled.
Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Link: https://msgid.link/r/20231209203229.878730-4-cristian.ciocaltea@collabora.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| 2cef11ec | 09-Dec-2023 |
Cristian Ciocaltea <cristian.ciocaltea@collabora.com> |
ASoC: amd: vangogh: Allow probing ACP PCI when SOF is disabled
Since commit e89f45edb747 ("ASoC: amd: vangogh: Add check for acp config flags in vangogh platform"), the Vangogh ACP PCI driver could
ASoC: amd: vangogh: Allow probing ACP PCI when SOF is disabled
Since commit e89f45edb747 ("ASoC: amd: vangogh: Add check for acp config flags in vangogh platform"), the Vangogh ACP PCI driver could not be used anymore for boards which happen to have a matching entry in acp-config list.
Commit f18818eb0dbe ("ASoC: amd: vangogh: Add condition check for acp config flag") slightly changed the behaviour to permit loading the driver if AMD_LEGACY flag is set. However, for AMD_SOF flag the probing is still denied, even if SOF support is disabled in kernel configuration.
While this helps preventing conflicts between SOF and generic ACP drivers, there are cases where a fallback to the generic non-SOF support would still be needed or useful, e.g. SOF firmware is not available or doesn't work properly, SOF driver is broken or doesn't provide full support for a particular hardware, or simply for testing/debugging the alternative solution. A real-life example is Steam Deck OLED, which works with both drivers.
Prevent returning from probe() when ACP config indicates SOF support for the current board *and* the Vangogh SOF driver is not enabled in kernel configuration.
Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Link: https://msgid.link/r/20231209203229.878730-3-cristian.ciocaltea@collabora.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| ddd1ee12 | 09-Dec-2023 |
Cristian Ciocaltea <cristian.ciocaltea@collabora.com> |
ASoC: amd: vangogh: Drop conflicting ACPI-based probing
The Vangogh machine driver variant based on the MAX98388 amplifier, as found on Valve's Steam Deck OLED, relies on probing via an ACPI match t
ASoC: amd: vangogh: Drop conflicting ACPI-based probing
The Vangogh machine driver variant based on the MAX98388 amplifier, as found on Valve's Steam Deck OLED, relies on probing via an ACPI match table. This worked fine until commit 197b1f7f0df1 ("ASoC: amd: Add new dmi entries to config entry") enabled SOF support for the target machine (i.e. Galileo product), causing the sound card to enter the deferred probe state indefinitely:
$ cat /sys/kernel/debug/devices_deferred AMDI8821:00 acp5x_mach: Register card (acp5x-max98388) failed
The issue is related to commit e89f45edb747 ("ASoC: amd: vangogh: Add check for acp config flags in vangogh platform"), which tries to mitigate potential conflicts between SOF and generic ACP Vangogh drivers, due to sharing the PCI device IDs.
However, the solution is effective only if the machine driver is directly probed by pci-acp5x through platform_device_register_full().
Hence, remove the conflicting ACPI based probing and rely exclusively on DMI quirks for sound card setup.
Fixes: dba22efd0d17 ("ASoC: amd: vangogh: Add support for NAU8821/MAX98388 variant") Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Link: https://msgid.link/r/20231209203229.878730-2-cristian.ciocaltea@collabora.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| dba22efd | 05-Jul-2023 |
Cristian Ciocaltea <cristian.ciocaltea@collabora.com> |
ASoC: amd: vangogh: Add support for NAU8821/MAX98388 variant
Extend the Vangogh machine driver to support a variant based on the Nuvoton NAU88L21 Codec and the Analog Devices MAX98388 Speaker Amplif
ASoC: amd: vangogh: Add support for NAU8821/MAX98388 variant
Extend the Vangogh machine driver to support a variant based on the Nuvoton NAU88L21 Codec and the Analog Devices MAX98388 Speaker Amplifier.
Additionally, enable probing via ACPI match table for this and future hardware revisions.
Co-developed-by: Lucas Tanure <lucas.tanure@collabora.com> Signed-off-by: Lucas Tanure <lucas.tanure@collabora.com> Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Link: https://lore.kernel.org/r/20230705214800.193244-4-cristian.ciocaltea@collabora.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| 3dd26e27 | 05-Jul-2023 |
Cristian Ciocaltea <cristian.ciocaltea@collabora.com> |
ASoC: amd: vangogh: Use dmi_first_match() for DMI quirk handling
In preparation for supporting ACPI probing, move DMI quirk handling logic at the probe's top, to be able to return as quickly as poss
ASoC: amd: vangogh: Use dmi_first_match() for DMI quirk handling
In preparation for supporting ACPI probing, move DMI quirk handling logic at the probe's top, to be able to return as quickly as possible in case there is no DMI matching.
Additionally, simplify the code by replacing dmi_check_system() and related callback with dmi_first_match(). While at it, also drop a few unnecessary empty lines.
Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Link: https://lore.kernel.org/r/20230705214800.193244-3-cristian.ciocaltea@collabora.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| e9023248 | 17-Feb-2023 |
Lucas Tanure <lucas.tanure@collabora.com> |
ASoC: amd: vangogh: Add components prefix in structs and function names
Add prefixes 8821/35l41 in structs and function names so future platforms can be added and reference the correct sound card. A
ASoC: amd: vangogh: Add components prefix in structs and function names
Add prefixes 8821/35l41 in structs and function names so future platforms can be added and reference the correct sound card. Also include acp5x prefix to cs35l41_conf.
Signed-off-by: Lucas Tanure <lucas.tanure@collabora.com> Link: https://lore.kernel.org/r/20230217110850.1045250-10-lucas.tanure@collabora.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| c10955e4 | 17-Feb-2023 |
Lucas Tanure <lucas.tanure@collabora.com> |
ASoC: amd: vangogh: Centralize strings definition
Replace occurrences of strings by their definition, avoiding bugs where the string changed, but not all places have been modified. While at it renam
ASoC: amd: vangogh: Centralize strings definition
Replace occurrences of strings by their definition, avoiding bugs where the string changed, but not all places have been modified. While at it rename defines to use NAU8821 codec name instead of NUVOTON and align with the other defines.
Signed-off-by: Lucas Tanure <lucas.tanure@collabora.com> Link: https://lore.kernel.org/r/20230217110850.1045250-9-lucas.tanure@collabora.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| ab89aa0d | 17-Feb-2023 |
Lucas Tanure <lucas.tanure@collabora.com> |
ASoC: amd: vangogh: Move nau8821 and CPU side code up for future platform
Move nau8821 and CPU side code up in the source so future platforms can be added.
Signed-off-by: Lucas Tanure <lucas.tanure
ASoC: amd: vangogh: Move nau8821 and CPU side code up for future platform
Move nau8821 and CPU side code up in the source so future platforms can be added.
Signed-off-by: Lucas Tanure <lucas.tanure@collabora.com> Link: https://lore.kernel.org/r/20230217110850.1045250-8-lucas.tanure@collabora.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|
| 9490fbb8 | 17-Feb-2023 |
Lucas Tanure <lucas.tanure@collabora.com> |
ASoC: amd: vangogh: Check Bit Clock rate before snd_soc_dai_set_pll
Check bit clock is valid before setting it with snd_soc_dai_set_pll
Signed-off-by: Lucas Tanure <lucas.tanure@collabora.com> Link
ASoC: amd: vangogh: Check Bit Clock rate before snd_soc_dai_set_pll
Check bit clock is valid before setting it with snd_soc_dai_set_pll
Signed-off-by: Lucas Tanure <lucas.tanure@collabora.com> Link: https://lore.kernel.org/r/20230217110850.1045250-7-lucas.tanure@collabora.com Signed-off-by: Mark Brown <broonie@kernel.org>
show more ...
|