Revert "fbdev/radeon: use pci aperture helpers"

This reverts commit 6db53af154 which is
commit 9b539c4d1b921bc9c8c578d4d50f0a7e7874d384 upstream.

It breaks the Android ABI and can be brought back later in an abi-safe
way if needed.

Bug: 161946584
Change-Id: If14dd22c006f9d09857175a60c7f684409242515
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
This commit is contained in:
Greg Kroah-Hartman 2023-11-01 14:36:10 +00:00
parent 3e052a378b
commit c0584fbc45

View File

@ -2238,6 +2238,14 @@ static const struct bin_attribute edid2_attr = {
.read = radeon_show_edid2,
};
static int radeon_kick_out_firmware_fb(struct pci_dev *pdev)
{
resource_size_t base = pci_resource_start(pdev, 0);
resource_size_t size = pci_resource_len(pdev, 0);
return aperture_remove_conflicting_devices(base, size, false, KBUILD_MODNAME);
}
static int radeonfb_pci_register(struct pci_dev *pdev,
const struct pci_device_id *ent)
{
@ -2288,7 +2296,7 @@ static int radeonfb_pci_register(struct pci_dev *pdev,
rinfo->fb_base_phys = pci_resource_start (pdev, 0);
rinfo->mmio_base_phys = pci_resource_start (pdev, 2);
ret = aperture_remove_conflicting_pci_devices(pdev, KBUILD_MODNAME);
ret = radeon_kick_out_firmware_fb(pdev);
if (ret)
goto err_release_fb;