vgaarb: Provide dummy default device functions
authorMatthew Garrett <mjg@redhat.com>
Thu, 3 May 2012 08:29:01 +0000 (09:29 +0100)
committerDave Airlie <airlied@redhat.com>
Thu, 3 May 2012 08:29:01 +0000 (09:29 +0100)
Add some stub functions for the case where CONFIG_VGA_ARB is disabled.

Signed-off-by: Matthew Garrett <mjg@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
include/linux/vgaarb.h

index 367ab18dccf7d2c9a97855557f51a6a7cd185d1c..0ee42d9acdc0f605dc0264b071834cb53dcd95e9 100644 (file)
@@ -183,8 +183,13 @@ extern void vga_put(struct pci_dev *pdev, unsigned int rsrc);
  */
 
 #ifndef __ARCH_HAS_VGA_DEFAULT_DEVICE
+#ifdef CONFIG_VGA_ARB
 extern struct pci_dev *vga_default_device(void);
 extern void vga_set_default_device(struct pci_dev *pdev);
+#else
+static inline struct pci_dev *vga_default_device(void) { return NULL; };
+static inline void vga_set_default_device(struct pci_dev *pdev) { };
+#endif
 #endif
 
 /**