Skip to content

Commit

Permalink
vgaarb: make client interface config invariant.
Browse files Browse the repository at this point in the history
Fixes build when VGA_ARB is off.

Reported-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Dave Airlie <airlied@redhat.com>
  • Loading branch information
Ingo Molnar authored and Dave Airlie committed Sep 22, 2009
1 parent 7fa0772 commit 7c32928
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion include/linux/vgaarb.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
* interrupts at any time.
*/
extern void vga_set_legacy_decoding(struct pci_dev *pdev,
unsigned int decodes);
unsigned int decodes);

/**
* vga_get - acquire & locks VGA resources
Expand Down Expand Up @@ -193,8 +193,17 @@ static inline int vga_conflicts(struct pci_dev *p1, struct pci_dev *p2)
* They driver will get a callback when VGA arbitration is first used
* by userspace since we some older X servers have issues.
*/
#if defined(CONFIG_VGA_ARB)
int vga_client_register(struct pci_dev *pdev, void *cookie,
void (*irq_set_state)(void *cookie, bool state),
unsigned int (*set_vga_decode)(void *cookie, bool state));
#else
static inline int vga_client_register(struct pci_dev *pdev, void *cookie,
void (*irq_set_state)(void *cookie, bool state),
unsigned int (*set_vga_decode)(void *cookie, bool state))
{
return 0;
}
#endif

#endif /* LINUX_VGA_H */

0 comments on commit 7c32928

Please sign in to comment.