Linux Sound subsystem development
 help / color / mirror / Atom feed
From: Takashi Iwai <tiwai@suse.de>
To: Heiner Kallweit <hkallweit1@gmail.com>
Cc: Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
	linux-sound@vger.kernel.org
Subject: Re: [PATCH] ALSA: hda: intel: Don't free interrupt when suspending
Date: Fri, 01 Nov 2024 09:21:26 +0100	[thread overview]
Message-ID: <87h68ruzy1.wl-tiwai@suse.de> (raw)
In-Reply-To: <1b7e109b-eb69-4542-8022-4ac8f9116474@gmail.com>

On Thu, 31 Oct 2024 20:32:52 +0100,
Heiner Kallweit wrote:
> 
> There's no need to free/re-request the interrupt on system suspend.
> PCI core takes care, using functions like pci_restore_msi_state().

Well, it wasn't always true for hibernation in the past,
e.g. snd-intel8x0 driver had to deal with it.  I guess it's no longer
needed for modern platforms for HD-audio, so I'm going to take this
for 6.13.


thanks,

Takashi

> 
> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
> ---
>  sound/pci/hda/hda_intel.c | 13 -------------
>  1 file changed, 13 deletions(-)
> 
> diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
> index b4540c5cd..9fc5e6c5d 100644
> --- a/sound/pci/hda/hda_intel.c
> +++ b/sound/pci/hda/hda_intel.c
> @@ -1040,14 +1040,6 @@ static int azx_suspend(struct device *dev)
>  	chip = card->private_data;
>  	bus = azx_bus(chip);
>  	azx_shutdown_chip(chip);
> -	if (bus->irq >= 0) {
> -		free_irq(bus->irq, chip);
> -		bus->irq = -1;
> -		chip->card->sync_irq = -1;
> -	}
> -
> -	if (chip->msi)
> -		pci_disable_msi(chip->pci);
>  
>  	trace_azx_suspend(chip);
>  	return 0;
> @@ -1062,11 +1054,6 @@ static int __maybe_unused azx_resume(struct device *dev)
>  		return 0;
>  
>  	chip = card->private_data;
> -	if (chip->msi)
> -		if (pci_enable_msi(chip->pci) < 0)
> -			chip->msi = 0;
> -	if (azx_acquire_irq(chip, 1) < 0)
> -		return -EIO;
>  
>  	__azx_runtime_resume(chip);
>  
> -- 
> 2.47.0
> 

  reply	other threads:[~2024-11-01  8:20 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-31 19:32 [PATCH] ALSA: hda: intel: Don't free interrupt when suspending Heiner Kallweit
2024-11-01  8:21 ` Takashi Iwai [this message]
2024-11-01  9:49   ` Heiner Kallweit
2024-11-02 10:08     ` Takashi Iwai
2024-11-04 13:23 ` Takashi Iwai

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87h68ruzy1.wl-tiwai@suse.de \
    --to=tiwai@suse.de \
    --cc=hkallweit1@gmail.com \
    --cc=linux-sound@vger.kernel.org \
    --cc=perex@perex.cz \
    --cc=tiwai@suse.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox