Lekensteyn

add 3D controller support to vgaarb

May 19th, 2012
5,146
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. diff --git a/drivers/gpu/vga/vgaarb.c b/drivers/gpu/vga/vgaarb.c
  2. index 111d956..bd9a01f 100644
  3. --- a/drivers/gpu/vga/vgaarb.c
  4. +++ b/drivers/gpu/vga/vgaarb.c
  5. @@ -507,9 +507,11 @@ static bool vga_arbiter_add_pci_device(struct pci_dev *pdev)
  6.     struct pci_bus *bus;
  7.     struct pci_dev *bridge;
  8.     u16 cmd;
  9. +   int pci_class = pdev->class >> 8;
  10.  
  11.     /* Only deal with VGA class devices */
  12. -   if ((pdev->class >> 8) != PCI_CLASS_DISPLAY_VGA)
  13. +   if (pci_class != PCI_CLASS_DISPLAY_VGA &&
  14. +       pci_class != PCI_CLASS_DISPLAY_3D)
  15.         return false;
  16.  
  17.     /* Allocate structure */
RAW Paste Data