Skip to content

Commit bfeb07b

Browse files
Philipp Stannerbjorn-helgaas
authored andcommitted
ALSA: korg1212: Replace deprecated PCI functions
pcim_iomap_table() and pcim_iomap_regions_request_all() have been deprecated by the PCI subsystem in commit e354bb8 ("PCI: Deprecate pcim_iomap_table(), pcim_iomap_regions_request_all()"). Replace these functions with their successors, pcim_iomap() and pcim_request_all_regions(). Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Philipp Stanner <[email protected]> Signed-off-by: Bjorn Helgaas <[email protected]> Reviewed-by: Takashi Iwai <[email protected]>
1 parent 55285d8 commit bfeb07b

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

sound/pci/korg1212/korg1212.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2108,7 +2108,7 @@ static int snd_korg1212_create(struct snd_card *card, struct pci_dev *pci)
21082108
for (i=0; i<kAudioChannels; i++)
21092109
korg1212->volumePhase[i] = 0;
21102110

2111-
err = pcim_iomap_regions_request_all(pci, 1 << 0, "korg1212");
2111+
err = pcim_request_all_regions(pci, "korg1212");
21122112
if (err < 0)
21132113
return err;
21142114

@@ -2130,7 +2130,9 @@ static int snd_korg1212_create(struct snd_card *card, struct pci_dev *pci)
21302130
korg1212->iomem2, iomem2_size,
21312131
stateName[korg1212->cardState]);
21322132

2133-
korg1212->iobase = pcim_iomap_table(pci)[0];
2133+
korg1212->iobase = pcim_iomap(pci, 0, 0);
2134+
if (!korg1212->iobase)
2135+
return -ENOMEM;
21342136

21352137
err = devm_request_irq(&pci->dev, pci->irq, snd_korg1212_interrupt,
21362138
IRQF_SHARED,

0 commit comments

Comments
 (0)