build fix for sound/drivers/pcsp/pcsp.c
PATCH 1/1 build fix for sound/drivers/pcsp/pcsp.c
x86.git testing found the following build error in v2.6.26-rc1:
sound/drivers/pcsp/pcsp.c: In function 'pcsp_suspend':
sound/drivers/pcsp/pcsp.c:201: error: implicit declaration of function 'snd_pcm_suspend_all'
with the following config:
http://redhat.com/~mingo/misc/config-Sun_May__4_19_20_01_CEST_2008.bad
the reason is the .suspend callback - which is defined even in the case of !CONFIG_PM in which case snd_pcm_suspend_all() is not available. Undefine the method for that case, like other platform drivers do.
--- sound/drivers/pcsp/pcsp.c | 4 ++++ 1 file changed, 4 insertions(+)
sound/drivers/pcsp/pcsp.c +4 -0
@@ -194,6 +194,7 @@ static void pcsp_stop_beep(struct snd_pcspin_unlock_irq (&chip->substream_lock); } +#ifdef CONFIG_PM static int pcsp_suspend (struct platform_device *dev,pm_message_t state) {struct snd_pcsp *chip =platform_get_drvdata (dev);
@@ -201,6 +202,7 @@ static int pcsp_suspend(struct platform_snd_pcm_suspend_all (chip->pcm); return 0; } +#endif static void pcsp_shutdown (struct platform_device *dev) {
@@ -215,7 +217,9 @@ static struct platform_driver pcsp_platf }, .probe = pcsp_probe, .remove = __devexit_p(pcsp_remove), +#ifdef CONFIG_PM .suspend = pcsp_suspend, +#endif .shutdown = pcsp_shutdown, };
Hello.
Quoted 1 line · Ingo Molnar
sound/drivers/pcsp/pcsp.c:201: error: implicit declaration of function 'snd_pcm_suspend_all'
There was a fix for that recently.
http://hg-mirror.alsa-project.org/alsa-kernel/rev/84966a18bd41