]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
ALSA: interwave: guard PM-only restore helpers with CONFIG_PM
authorCássio Gabriel <cassiogabrielcontato@gmail.com>
Fri, 10 Apr 2026 13:56:52 +0000 (10:56 -0300)
committerTakashi Iwai <tiwai@suse.de>
Fri, 10 Apr 2026 14:34:50 +0000 (16:34 +0200)
commitb7feba842c0d5f6c5b01592f80d164e974767501
tree1860ae73c1fa8838114035b617df6616ce388a65
parent47f72d57ddb11222479c80bd07f5bc036d84c94d
ALSA: interwave: guard PM-only restore helpers with CONFIG_PM

The InterWave PM patch added snd_interwave_restore_regs() and
snd_interwave_restore_memory() as static helpers, but both are used only
from the resume path under CONFIG_PM.

On configurations without CONFIG_PM, such as alpha allyesconfig, this
leaves both helpers unused and triggers -Wunused-function warnings with
W=1.

Move the PM-only helpers into the existing CONFIG_PM section. Keep
__snd_interwave_restore_regs() outside the guard because it is also used
during probe-time initialization.

Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202604101958.x16oNkfo-lkp@intel.com/
Signed-off-by: Cássio Gabriel <cassiogabrielcontato@gmail.com>
Link: https://patch.msgid.link/20260410-alsa-interwave-pm-warning-fix-v1-1-434d14c9c262@gmail.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/isa/gus/interwave.c