]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
drm/amdgpu: Remove driver side BAR release before resize
authorIlpo Järvinen <ilpo.jarvinen@linux.intel.com>
Thu, 13 Nov 2025 16:26:27 +0000 (18:26 +0200)
committerBjorn Helgaas <bhelgaas@google.com>
Fri, 14 Nov 2025 18:34:20 +0000 (12:34 -0600)
commitdb92e3fef53e2083001dcc4c86a3ecff4ab4dc4e
treef355389b1f00900b5226937adae20bf880f351dd
parent4efaa80b3d75bdbe8fd1f8ef56e6541511da4600
drm/amdgpu: Remove driver side BAR release before resize

PCI core handles releasing device's resources and their rollback in case of
failure of a BAR resizing operation. Releasing resource prior to calling
pci_resize_resource() prevents PCI core from restoring the BARs as they
were.

Remove driver-side release of BARs from the amdgpu driver.

Also remove the driver initiated assignment as pci_resize_resource() should
try to assign as much as possible. If the driver side call manages to get
more required resources assigned in some scenario, such a problem should be
fixed inside pci_resize_resource() instead.

Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Tested-by: Alex Bennée <alex.bennee@linaro.org> # AVA, AMD GPU
Link: https://patch.msgid.link/20251113162628.5946-11-ilpo.jarvinen@linux.intel.com
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c