]> git.ipfire.org Git - thirdparty/linux.git/commit
resource: Pass full extent of empty space to resource_alignf callback
authorIlpo Järvinen <ilpo.jarvinen@linux.intel.com>
Tue, 24 Mar 2026 16:56:25 +0000 (18:56 +0200)
committerBjorn Helgaas <bhelgaas@google.com>
Fri, 27 Mar 2026 15:18:39 +0000 (10:18 -0500)
commitf699bcc8bcdf99565928a7b1fc7ee656f6c81815
treee1c50dbc2a6c82ed9c243b689e3593d4cb2dbec8
parentedfaa81d5da5fbfe3c73fece3ca0417a04cc4ba2
resource: Pass full extent of empty space to resource_alignf callback

__find_resource_space() calculates the full extent of empty space but only
passes the aligned space to resource_alignf callback. In some situations,
the callback may choose take advantage of the free space before the
requested alignment.

Pass the full extent of the calculated empty space to resource_alignf
callback as an additional parameter.

Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Tested-by: Xifer <xiferdev@gmail.com>
Link: https://patch.msgid.link/20260324165633.4583-3-ilpo.jarvinen@linux.intel.com
16 files changed:
arch/alpha/kernel/pci.c
arch/arm/kernel/bios32.c
arch/m68k/kernel/pcibios.c
arch/mips/pci/pci-generic.c
arch/mips/pci/pci-legacy.c
arch/parisc/kernel/pci.c
arch/powerpc/kernel/pci-common.c
arch/s390/pci/pci.c
arch/sh/drivers/pci/pci.c
arch/x86/pci/i386.c
arch/xtensa/kernel/pci.c
drivers/pci/setup-res.c
drivers/pcmcia/rsrc_nonstatic.c
include/linux/ioport.h
include/linux/pci.h
kernel/resource.c