All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2] ASoC: amd: Don't show messages about deferred probing by default
@ 2021-07-21 18:36 Mario Limonciello
  2021-07-21 18:36 ` [PATCH] ASoC: amd: renoir: Run hibernation callbacks Mario Limonciello
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Mario Limonciello @ 2021-07-21 18:36 UTC (permalink / raw)
  To: Mark Brown, Takashi Iwai,
	moderated list:SOUND - SOC LAYER / DYNAMIC AUDIO POWER MANAGEM...
  Cc: markpearson, Mario Limonciello, Vijendar Mukunda

Nearly every boot with a Lenovo P14s is showing
acp_pdm_mach acp_pdm_mach.0: snd_soc_register_card(acp) failed: -517

This isn't useful to a user, especially as probing will run again.
Downgrade the message to debug, and only show errors.

CC: markpearson@lenovo.com
Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>
---
 sound/soc/amd/renoir/acp3x-rn.c | 14 +++++++++-----
 1 file changed, 9 insertions(+), 5 deletions(-)

Changes from v1->v2:
 * Simplify down to one return line.

diff --git a/sound/soc/amd/renoir/acp3x-rn.c b/sound/soc/amd/renoir/acp3x-rn.c
index 306134b89a82..ed73da496744 100644
--- a/sound/soc/amd/renoir/acp3x-rn.c
+++ b/sound/soc/amd/renoir/acp3x-rn.c
@@ -54,12 +54,16 @@ static int acp_probe(struct platform_device *pdev)
 	snd_soc_card_set_drvdata(card, machine);
 	ret = devm_snd_soc_register_card(&pdev->dev, card);
 	if (ret) {
-		dev_err(&pdev->dev,
-			"snd_soc_register_card(%s) failed: %d\n",
-			acp_card.name, ret);
-		return ret;
+		if (ret != -EPROBE_DEFER)
+			dev_err(&pdev->dev,
+				"snd_soc_register_card(%s) failed: %d\n",
+				card->name, ret);
+		else
+			dev_dbg(&pdev->dev,
+				"snd_soc_register_card(%s) probe deferred: %d\n",
+				card->name, ret);
 	}
-	return 0;
+	return ret;
 }
 
 static struct platform_driver acp_mach_driver = {
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH] ASoC: amd: renoir: Run hibernation callbacks
  2021-07-21 18:36 [PATCH v2] ASoC: amd: Don't show messages about deferred probing by default Mario Limonciello
@ 2021-07-21 18:36 ` Mario Limonciello
  2021-07-22 11:28   ` Mark Brown
  2021-07-22 17:10   ` Mark Brown
  2021-07-22  6:59 ` [PATCH v2] ASoC: amd: Don't show messages about deferred probing by default Mukunda,Vijendar
  2021-07-22 11:18 ` Mark Brown
  2 siblings, 2 replies; 6+ messages in thread
From: Mario Limonciello @ 2021-07-21 18:36 UTC (permalink / raw)
  To: Mark Brown, Takashi Iwai,
	moderated list:SOUND - SOC LAYER / DYNAMIC AUDIO POWER MANAGEM...
  Cc: Mario Limonciello, Vijendar Mukunda

The registers need to be re-initialized after hibernation or
microphone may be non-functional.

BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=213793
Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>
---
 sound/soc/amd/renoir/rn-pci-acp3x.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/sound/soc/amd/renoir/rn-pci-acp3x.c b/sound/soc/amd/renoir/rn-pci-acp3x.c
index 19438da5dfa5..7b8040e812a1 100644
--- a/sound/soc/amd/renoir/rn-pci-acp3x.c
+++ b/sound/soc/amd/renoir/rn-pci-acp3x.c
@@ -382,6 +382,8 @@ static const struct dev_pm_ops rn_acp_pm = {
 	.runtime_resume =  snd_rn_acp_resume,
 	.suspend = snd_rn_acp_suspend,
 	.resume =	snd_rn_acp_resume,
+	.restore =	snd_rn_acp_resume,
+	.poweroff =	snd_rn_acp_suspend,
 };
 
 static void snd_rn_acp_remove(struct pci_dev *pci)
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH v2] ASoC: amd: Don't show messages about deferred probing by default
  2021-07-21 18:36 [PATCH v2] ASoC: amd: Don't show messages about deferred probing by default Mario Limonciello
  2021-07-21 18:36 ` [PATCH] ASoC: amd: renoir: Run hibernation callbacks Mario Limonciello
@ 2021-07-22  6:59 ` Mukunda,Vijendar
  2021-07-22 11:18 ` Mark Brown
  2 siblings, 0 replies; 6+ messages in thread
From: Mukunda,Vijendar @ 2021-07-22  6:59 UTC (permalink / raw)
  To: Mario Limonciello, Mark Brown, Takashi Iwai,
	moderated list:SOUND - SOC LAYER / DYNAMIC AUDIO POWER MANAGEM...
  Cc: markpearson

On 7/22/21 12:06 AM, Mario Limonciello wrote:
> Nearly every boot with a Lenovo P14s is showing
> acp_pdm_mach acp_pdm_mach.0: snd_soc_register_card(acp) failed: -517
> 
> This isn't useful to a user, especially as probing will run again.
> Downgrade the message to debug, and only show errors.
> 
> CC: markpearson@lenovo.com
> Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>

Reviewed-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com>
> ---
>  sound/soc/amd/renoir/acp3x-rn.c | 14 +++++++++-----
>  1 file changed, 9 insertions(+), 5 deletions(-)
> 
> Changes from v1->v2:
>  * Simplify down to one return line.
> 
> diff --git a/sound/soc/amd/renoir/acp3x-rn.c b/sound/soc/amd/renoir/acp3x-rn.c
> index 306134b89a82..ed73da496744 100644
> --- a/sound/soc/amd/renoir/acp3x-rn.c
> +++ b/sound/soc/amd/renoir/acp3x-rn.c
> @@ -54,12 +54,16 @@ static int acp_probe(struct platform_device *pdev)
>  	snd_soc_card_set_drvdata(card, machine);
>  	ret = devm_snd_soc_register_card(&pdev->dev, card);
>  	if (ret) {
> -		dev_err(&pdev->dev,
> -			"snd_soc_register_card(%s) failed: %d\n",
> -			acp_card.name, ret);
> -		return ret;
> +		if (ret != -EPROBE_DEFER)
> +			dev_err(&pdev->dev,
> +				"snd_soc_register_card(%s) failed: %d\n",
> +				card->name, ret);
> +		else
> +			dev_dbg(&pdev->dev,
> +				"snd_soc_register_card(%s) probe deferred: %d\n",
> +				card->name, ret);
>  	}
> -	return 0;
> +	return ret;
>  }
>  
>  static struct platform_driver acp_mach_driver = {
> 


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v2] ASoC: amd: Don't show messages about deferred probing by default
  2021-07-21 18:36 [PATCH v2] ASoC: amd: Don't show messages about deferred probing by default Mario Limonciello
  2021-07-21 18:36 ` [PATCH] ASoC: amd: renoir: Run hibernation callbacks Mario Limonciello
  2021-07-22  6:59 ` [PATCH v2] ASoC: amd: Don't show messages about deferred probing by default Mukunda,Vijendar
@ 2021-07-22 11:18 ` Mark Brown
  2 siblings, 0 replies; 6+ messages in thread
From: Mark Brown @ 2021-07-22 11:18 UTC (permalink / raw)
  To: Mario Limonciello
  Cc: markpearson,
	moderated list:SOUND - SOC LAYER / DYNAMIC AUDIO POWER MANAGEM...,
	Takashi Iwai, Vijendar Mukunda

[-- Attachment #1: Type: text/plain, Size: 341 bytes --]

On Wed, Jul 21, 2021 at 01:36:02PM -0500, Mario Limonciello wrote:
> Nearly every boot with a Lenovo P14s is showing
> acp_pdm_mach acp_pdm_mach.0: snd_soc_register_card(acp) failed: -517
> 
> This isn't useful to a user, especially as probing will run again.
> Downgrade the message to debug, and only show errors.

dev_err_probe()

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] ASoC: amd: renoir: Run hibernation callbacks
  2021-07-21 18:36 ` [PATCH] ASoC: amd: renoir: Run hibernation callbacks Mario Limonciello
@ 2021-07-22 11:28   ` Mark Brown
  2021-07-22 17:10   ` Mark Brown
  1 sibling, 0 replies; 6+ messages in thread
From: Mark Brown @ 2021-07-22 11:28 UTC (permalink / raw)
  To: Mario Limonciello
  Cc: moderated list:SOUND - SOC LAYER / DYNAMIC AUDIO POWER MANAGEM...,
	Takashi Iwai, Vijendar Mukunda

[-- Attachment #1: Type: text/plain, Size: 367 bytes --]

On Wed, Jul 21, 2021 at 01:36:03PM -0500, Mario Limonciello wrote:
> The registers need to be re-initialized after hibernation or
> microphone may be non-functional.

You've sent this in reply to version 2 of an apparently unrelated patch,
please don't send patches in reply to existing threads especially not
unrelated ones - it really confuses the tooling. 

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] ASoC: amd: renoir: Run hibernation callbacks
  2021-07-21 18:36 ` [PATCH] ASoC: amd: renoir: Run hibernation callbacks Mario Limonciello
  2021-07-22 11:28   ` Mark Brown
@ 2021-07-22 17:10   ` Mark Brown
  1 sibling, 0 replies; 6+ messages in thread
From: Mark Brown @ 2021-07-22 17:10 UTC (permalink / raw)
  To: Takashi Iwai, Mario Limonciello,
	moderated list:SOUND - SOC LAYER / DYNAMIC AUDIO POWER MANAGEM...
  Cc: Mark Brown, Vijendar Mukunda

On Wed, 21 Jul 2021 13:36:03 -0500, Mario Limonciello wrote:
> The registers need to be re-initialized after hibernation or
> microphone may be non-functional.

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next

Thanks!

[1/1] ASoC: amd: renoir: Run hibernation callbacks
      commit: d00f541a49406afc2c091aac121e29b3b61480a2

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-07-22 17:11 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-21 18:36 [PATCH v2] ASoC: amd: Don't show messages about deferred probing by default Mario Limonciello
2021-07-21 18:36 ` [PATCH] ASoC: amd: renoir: Run hibernation callbacks Mario Limonciello
2021-07-22 11:28   ` Mark Brown
2021-07-22 17:10   ` Mark Brown
2021-07-22  6:59 ` [PATCH v2] ASoC: amd: Don't show messages about deferred probing by default Mukunda,Vijendar
2021-07-22 11:18 ` Mark Brown

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.