lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <cab6f9b5-605e-4d6f-8859-02d451e7ed99@amd.com>
Date: Mon, 16 Dec 2024 09:09:24 -0600
From: Mario Limonciello <mario.limonciello@....com>
To: Venkata Prasad Potturu <venkataprasad.potturu@....com>,
 broonie@...nel.org, alsa-devel@...a-project.org
Cc: Vijendar.Mukunda@....com, Basavaraj.Hiregoudar@....com,
 Sunil-kumar.Dommati@....com, syed.sabakareem@....com,
 Liam Girdwood <lgirdwood@...il.com>, Jaroslav Kysela <perex@...ex.cz>,
 Takashi Iwai <tiwai@...e.com>, Bard Liao <yung-chuan.liao@...ux.intel.com>,
 Péter Ujfalusi <peter.ujfalusi@...ux.intel.com>,
 Pierre-Louis Bossart <pierre-louis.bossart@...ux.dev>,
 "open list:SOUND - SOC LAYER / DYNAMIC AUDIO POWER MANAGEM..."
 <linux-sound@...r.kernel.org>, open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] ASoC: amd: ps: Fix for enabling DMIC on acp63 platform
 via _DSD entry

On 12/13/2024 00:11, Venkata Prasad Potturu wrote:
> Add condition check to register ACP PDM sound card by reading
> _WOV acpi entry.
> 
> Fixes: 0386d765f27a ("ASoC: amd: ps: refactor acp device configuration read logic")
> 
> Signed-off-by: Venkata Prasad Potturu <venkataprasad.potturu@....com>

Reviewed-by: Mario Limonciello <mario.limonciello@....com>

> ---
>   sound/soc/amd/ps/pci-ps.c | 17 ++++++++++++++++-
>   1 file changed, 16 insertions(+), 1 deletion(-)
> 
> diff --git a/sound/soc/amd/ps/pci-ps.c b/sound/soc/amd/ps/pci-ps.c
> index a7583844f5b4..983d7fa13938 100644
> --- a/sound/soc/amd/ps/pci-ps.c
> +++ b/sound/soc/amd/ps/pci-ps.c
> @@ -374,11 +374,18 @@ static int get_acp63_device_config(struct pci_dev *pci, struct acp63_dev_data *a
>   {
>   	struct acpi_device *pdm_dev;
>   	const union acpi_object *obj;
> +	acpi_handle handle;
> +	acpi_integer dmic_status;
>   	u32 config;
>   	bool is_dmic_dev = false;
>   	bool is_sdw_dev = false;
> +	bool wov_en, dmic_en;
>   	int ret;
>   
> +	/* IF WOV entry not found, enable dmic based on acp-audio-device-type entry*/
> +	wov_en = true;
> +	dmic_en = false;
> +
>   	config = readl(acp_data->acp63_base + ACP_PIN_CONFIG);
>   	switch (config) {
>   	case ACP_CONFIG_4:
> @@ -411,10 +418,18 @@ static int get_acp63_device_config(struct pci_dev *pci, struct acp63_dev_data *a
>   			if (!acpi_dev_get_property(pdm_dev, "acp-audio-device-type",
>   						   ACPI_TYPE_INTEGER, &obj) &&
>   						   obj->integer.value == ACP_DMIC_DEV)
> -				is_dmic_dev = true;
> +				dmic_en = true;
>   		}
> +
> +		handle = ACPI_HANDLE(&pci->dev);
> +		ret = acpi_evaluate_integer(handle, "_WOV", NULL, &dmic_status);
> +		if (!ACPI_FAILURE(ret))
> +			wov_en = dmic_status;
>   	}
>   
> +	if (dmic_en && wov_en)
> +		is_dmic_dev = true;
> +
>   	if (acp_data->is_sdw_config) {
>   		ret = acp_scan_sdw_devices(&pci->dev, ACP63_SDW_ADDR);
>   		if (!ret && acp_data->info.link_mask)


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ