diff options
author | Vijendar Mukunda <Vijendar.Mukunda@amd.com> | 2024-02-14 11:40:01 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2024-02-19 18:02:11 +0100 |
commit | 0386d765f27a1fd3ed2ed6388a07e26d9659936d (patch) | |
tree | 21884547602ba207122d32e76e868ccd4c8d683d /sound/soc/amd/ps/acp63.h | |
parent | ASoC: Constify pointer to of_phandle_args (diff) | |
download | linux-0386d765f27a1fd3ed2ed6388a07e26d9659936d.tar.xz linux-0386d765f27a1fd3ed2ed6388a07e26d9659936d.zip |
ASoC: amd: ps: refactor acp device configuration read logic
Refactor acp device configuration read logic and use common function
to scan SoundWire devices.
Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com>
Link: https://msgid.link/r/20240214104014.1144668-1-Vijendar.Mukunda@amd.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/amd/ps/acp63.h')
-rw-r--r-- | sound/soc/amd/ps/acp63.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/sound/soc/amd/ps/acp63.h b/sound/soc/amd/ps/acp63.h index 8b853b8d0219..123b9ade69d4 100644 --- a/sound/soc/amd/ps/acp63.h +++ b/sound/soc/amd/ps/acp63.h @@ -5,6 +5,7 @@ * Copyright (C) 2022, 2023 Advanced Micro Devices, Inc. All rights reserved. */ +#include <linux/soundwire/sdw_amd.h> #include <sound/acp63_chip_offset_byte.h> #define ACP_DEVICE_ID 0x15E2 @@ -263,6 +264,11 @@ struct sdw_dma_ring_buf_reg { * @sdw0_dev_index: SoundWire Manager-0 platform device index * @sdw1_dev_index: SoundWire Manager-1 platform device index * @sdw_dma_dev_index: SoundWire DMA controller platform device index + * @info: SoundWire AMD information found in ACPI tables + * @is_sdw_dev: flag set to true when any SoundWire manager instances are available + * @is_pdm_dev: flag set to true when ACP PDM controller exists + * @is_pdm_config: flat set to true when PDM configuration is selected from BIOS + * @is_sdw_config: flag set to true when SDW configuration is selected from BIOS * @sdw0-dma_intr_stat: DMA interrupt status array for SoundWire manager-SW0 instance * @sdw_dma_intr_stat: DMA interrupt status array for SoundWire manager-SW1 instance * @acp_reset: flag set to true when bus reset is applied across all @@ -282,6 +288,11 @@ struct acp63_dev_data { u16 sdw0_dev_index; u16 sdw1_dev_index; u16 sdw_dma_dev_index; + struct sdw_amd_acpi_info info; + bool is_sdw_dev; + bool is_pdm_dev; + bool is_pdm_config; + bool is_sdw_config; u16 sdw0_dma_intr_stat[ACP63_SDW0_DMA_MAX_STREAMS]; u16 sdw1_dma_intr_stat[ACP63_SDW1_DMA_MAX_STREAMS]; bool acp_reset; |