diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2024-11-19 12:19:59 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2024-11-19 12:19:59 -0800 |
commit | 9db8b240704cf66b8c9caaad586034399ac39641 (patch) | |
tree | b0c8c723294f70e7b763c9884148bb5bb0deb61e | |
parent | ab713e709938ec4045b4cddcd850a0135ae343b4 (diff) | |
parent | 90f1b42b179487ee77d182893408cc1c40d50b13 (diff) | |
download | lwn-9db8b240704cf66b8c9caaad586034399ac39641.tar.gz lwn-9db8b240704cf66b8c9caaad586034399ac39641.zip |
Merge tag 'x86_platform_for_v6.13' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull x86 platform cleanup from Borislav Petkov:
- Replace deprecated PCI functions used in intel-mid
* tag 'x86_platform_for_v6.13' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
x86/platform/intel-mid: Replace deprecated PCI functions
-rw-r--r-- | arch/x86/platform/intel-mid/pwr.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/arch/x86/platform/intel-mid/pwr.c b/arch/x86/platform/intel-mid/pwr.c index 27288d8d3f71..cd7e0c71adde 100644 --- a/arch/x86/platform/intel-mid/pwr.c +++ b/arch/x86/platform/intel-mid/pwr.c @@ -358,18 +358,18 @@ static int mid_pwr_probe(struct pci_dev *pdev, const struct pci_device_id *id) return ret; } - ret = pcim_iomap_regions(pdev, 1 << 0, pci_name(pdev)); - if (ret) { - dev_err(&pdev->dev, "I/O memory remapping failed\n"); - return ret; - } - pwr = devm_kzalloc(dev, sizeof(*pwr), GFP_KERNEL); if (!pwr) return -ENOMEM; + pwr->regs = pcim_iomap_region(pdev, 0, "intel_mid_pwr"); + ret = PTR_ERR_OR_ZERO(pwr->regs); + if (ret) { + dev_err(&pdev->dev, "Could not request / ioremap I/O-Mem: %d\n", ret); + return ret; + } + pwr->dev = dev; - pwr->regs = pcim_iomap_table(pdev)[0]; pwr->irq = pdev->irq; mutex_init(&pwr->lock); |