Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

drm/xe: 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 xe driver.

Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Lucas De Marchi <lucas.demarchi@intel.com>
Link: https://patch.msgid.link/20251113162628.5946-9-ilpo.jarvinen@linux.intel.com

authored by

Ilpo Järvinen and committed by
Bjorn Helgaas
1a3c05b3 d787018e

-3
-3
drivers/gpu/drm/xe/xe_vram.c
··· 33 33 int bar_size = pci_rebar_bytes_to_size(size); 34 34 int ret; 35 35 36 - if (pci_resource_len(pdev, resno)) 37 - pci_release_resource(pdev, resno); 38 - 39 36 ret = pci_resize_resource(pdev, resno, bar_size, 0); 40 37 if (ret) { 41 38 drm_info(&xe->drm, "Failed to resize BAR%d to %dM (%pe). Consider enabling 'Resizable BAR' support in your BIOS\n",