Skip to content

Commit 1e73359

Browse files
arndbtiwai
authored andcommitted
ALSA: hda/ca0132 - make pci_iounmap() call conditional
When building without CONFIG_PCI, we can (depending on the architecture) get a link failure: ERROR: "pci_iounmap" [sound/pci/hda/snd-hda-codec-ca0132.ko] undefined! Adding a compile-time check for PCI gets it to work correctly on 32-bit ARM. Fixes: d99501b ("ALSA: hda/ca0132 - Call pci_iounmap() instead of iounmap()") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
1 parent 46079ba commit 1e73359

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sound/pci/hda/patch_ca0132.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8451,7 +8451,7 @@ static void ca0132_free(struct hda_codec *codec)
84518451
ca0132_exit_chip(codec);
84528452

84538453
snd_hda_power_down(codec);
8454-
if (spec->mem_base)
8454+
if (IS_ENABLED(CONFIG_PCI) && spec->mem_base)
84558455
pci_iounmap(codec->bus->pci, spec->mem_base);
84568456
kfree(spec->spec_init_verbs);
84578457
kfree(codec->spec);

0 commit comments

Comments
 (0)