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] [day] [month] [year] [list]
Message-ID: <3ba81b7f7859de8ac64e4cf07cc5aa21c3850ae9.camel@kernel.org>
Date: Fri, 02 May 2025 00:16:59 +0200
From: Niklas Schnelle <niks@...nel.org>
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,
 mario.limonciello@....com,  Liam Girdwood <lgirdwood@...il.com>, Jaroslav
 Kysela <perex@...ex.cz>, Takashi Iwai <tiwai@...e.com>, Uwe
 Kleine-König	 <u.kleine-koenig@...libre.com>, Greg KH
 <gregkh@...uxfoundation.org>, Peter Zijlstra <peterz@...radead.org>, "open
 list:SOUND - SOC LAYER / DYNAMIC AUDIO POWER MANAGEM..."	
 <linux-sound@...r.kernel.org>, open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 1/3] ASoC: amd: acp: Fix NULL pointer deref on acp
 resume path

On Fri, 2025-04-25 at 11:31 +0530, Venkata Prasad Potturu wrote:
> update chip data using dev_get_drvdata(dev->parent) instead of
> dev_get_platdata(dev).
> 
> BUG: kernel NULL pointer dereference, address: 0000000000000010
> Call Trace:
>  <TASK>
>  ? __pfx_platform_pm_resume+0x10/0x10
>  platform_pm_resume+0x28/0x60
>  dpm_run_callback+0x51/0x1a0
>  device_resume+0x1a6/0x2b0
>  dpm_resume+0x168/0x230
> 
> Fixes: e3933683b25e ("ASoC: amd: acp: Remove redundant acp_dev_data structure")
> 
> Signed-off-by: Venkata Prasad Potturu <venkataprasad.potturu@....com>

This is the first time I see an empty line between the Fixes and the
Signed-off-by tags. I checked checkpatch.pl --strict and that doesn't
complain, but I'm curious now, is that a subsystem thing since you have
it in all 3 patches?

> ---
>  sound/soc/amd/acp/acp-rembrandt.c | 2 +-
>  sound/soc/amd/acp/acp-renoir.c    | 2 +-
>  sound/soc/amd/acp/acp63.c         | 2 +-
>  sound/soc/amd/acp/acp70.c         | 2 +-
>  4 files changed, 4 insertions(+), 4 deletions(-)
> 
--- snip ---
> index 6d5f5ade075c..217b717e9beb 100644
> --- a/sound/soc/amd/acp/acp70.c
> +++ b/sound/soc/amd/acp/acp70.c
> @@ -182,7 +182,7 @@ static void acp_acp70_audio_remove(struct platform_device *pdev)
>  
>  static int acp70_pcm_resume(struct device *dev)
>  {
> -	struct acp_chip_info *chip = dev_get_platdata(dev);
> +	struct acp_chip_info *chip = dev_get_drvdata(dev->parent);
>  	struct acp_stream *stream;
>  	struct snd_pcm_substream *substream;
>  	snd_pcm_uframes_t buf_in_frames;

Hi Venkata,

Yesterday I ran into what I believe is the issue fixed by this patch on
my very recently acquired Framework 13 with a Ryzen AI 340. While I was
still bisecting this I found a thread[0] of Jacek Luczak having
bisected this and the revert at least solved the suspend issue for me
too, though I was still getting a sound subsystem related crash[2] that
looked related so was waiting for a proper fix. As a side note you
might want to consider adding a Reported-by tag from Jacek.

I had mentioned this on the Framework forums[1] where Mario Limonciello
helpfully pointed me at this series. I just tried your series on top of
v6.15-rc4 and suspend now works. I also haven't seen the other crash I
was still getting with just the revert from the previous thread. And
sound still works too. So feel free to add, or ignore, my:

Tested-by: Niklas Schnelle <niks@...nel.org>

Thanks,
Niklas


[0] https://lore.kernel.org/lkml/CADDYkjR0JG_JTQeQMAvUJvtb9RxFH6_LzV2Fr_1cnqPTgV_Z8w@mail.gmail.com/
[1] https://community.frame.work/t/regression-framework-13-ryzen-340-doesnt-wake-from-suspend-on-v6-15-rc4-works-fine-on-v6-14-4/68514
[2] https://pastebin.com/pR54sve3

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ