Merge tag 'drm-misc-next-2022-08-20-1' of git://anongit.freedesktop.org/drm/drm-misc...
[linux-block.git] / drivers / video / fbdev / arkfb.c
index a2a381631628efa28e97638da147b06455e58861..a317d9fe1d67de4864af27bc928126335e547e68 100644 (file)
@@ -11,6 +11,7 @@
  *  Code is based on s3fb
  */
 
+#include <linux/aperture.h>
 #include <linux/module.h>
 #include <linux/kernel.h>
 #include <linux/errno.h>
@@ -956,6 +957,10 @@ static int ark_pci_probe(struct pci_dev *dev, const struct pci_device_id *id)
        int rc;
        u8 regval;
 
+       rc = aperture_remove_conflicting_pci_devices(dev, "arkfb");
+       if (rc < 0)
+               return rc;
+
        /* Ignore secondary VGA device because there is no VGA arbitration */
        if (! svga_primary_device(dev)) {
                dev_info(&(dev->dev), "ignoring secondary device\n");