[alsa-devel] [PATCH] [ALSA] hda - bug fix on references without checking CONFIG_SND_HDA_POWER_SAVE
Lin, Mengdong
mengdong.lin at intel.com
Fri Aug 24 04:52:53 CEST 2012
Sorry, please ignore this patch. The bug fix is not enough.
Thanks
Mengdong
> -----Original Message-----
> From: Lin, Mengdong
> Sent: Friday, August 24, 2012 10:48 AM
> To: alsa-devel at alsa-project.org
> Cc: tiwai at suse.de; Wu, Fengguang; Lin, Mengdong
> Subject: [PATCH] [ALSA] hda - bug fix on references without checking
> CONFIG_SND_HDA_POWER_SAVE
>
> From: Mengdong Lin <mengdong.lin at intel.com>
>
> The patch to support runtime PM introduced a bug:
> Module parameter 'power_save_controller', and the codec flag 'd3_stop_clk'
> 'd3_stop_clk_ok' are defined only when HDA power save is enabled in config.
> But there are references to them without checking macro
> CONFIG_SND_HDA_POWER_SAVE.
>
> This patch is to fix the bug.
>
> Signed-off-by: Mengdong Lin <mengdong.lin at intel.com>
> ---
> sound/pci/hda/hda_intel.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c index
> 2baa3ee..97307df 100644
> --- a/sound/pci/hda/hda_intel.c
> +++ b/sound/pci/hda/hda_intel.c
> @@ -2515,8 +2515,10 @@ static int azx_runtime_suspend(struct device
> *dev)
> struct snd_card *card = dev_get_drvdata(dev);
> struct azx *chip = card->private_data;
>
> +#ifdef CONFIG_SND_HDA_POWER_SAVE
> if (!power_save_controller)
> return -EAGAIN;
> +#endif
>
> azx_stop_chip(chip);
> azx_clear_irq_pending(chip);
> --
> 1.7.9.5
More information about the Alsa-devel
mailing list