]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commitdiff
vgaarb: Keep adding VGA device in queue
authorAaron Ma <aaron.ma@canonical.com>
Tue, 22 Jan 2019 07:05:46 +0000 (15:05 +0800)
committerKhalid Elmously <khalid.elmously@canonical.com>
Wed, 6 Feb 2019 04:53:01 +0000 (04:53 +0000)
BugLink: https://bugs.launchpad.net/bugs/1812797
If failed to find the deivice owning the boot framebuffer,
try to use the first VGA device instead of the last one.

Usually the 1st device is integrated GPU who owns the boot framebuffer.

Signed-off-by: Aaron Ma <aaron.ma@canonical.com>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/1535739600-8842-2-git-send-email-aaron.ma@canonical.com
(cherry picked from commit 3d42f1ddc47a69c0ce155f9f30d764c4d689a5fa)
Signed-off-by: Aaron Ma <aaron.ma@canonical.com>
Acked-by: Stefan Bader <stefan.bader@canonical.com>
Acked-by: Seth Forshee <seth.forshee@canonical.com>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
drivers/gpu/vga/vgaarb.c

index 952227c3fef99a27078b0ebfc93ebd6937b62219..9a72757eed860e23ba59ecf231cc4c2fca7a7a10 100644 (file)
@@ -676,7 +676,7 @@ static bool vga_arbiter_add_pci_device(struct pci_dev *pdev)
        vga_arbiter_check_bridge_sharing(vgadev);
 
        /* Add to the list */
-       list_add(&vgadev->list, &vga_list);
+       list_add_tail(&vgadev->list, &vga_list);
        vga_count++;
        vgaarb_info(&pdev->dev, "VGA device added: decodes=%s,owns=%s,locks=%s\n",
                vga_iostate_to_str(vgadev->decodes),