vgaarb: make client interface config invariant.
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>
This commit is contained in:
		
					parent
					
						
							
								7fa07729e4
							
						
					
				
			
			
				commit
				
					
						7c329288d7
					
				
			
		
					 1 changed files with 10 additions and 1 deletions
				
			
		| 
						 | 
					@ -41,7 +41,7 @@
 | 
				
			||||||
 *     interrupts at any time.
 | 
					 *     interrupts at any time.
 | 
				
			||||||
 */
 | 
					 */
 | 
				
			||||||
extern void vga_set_legacy_decoding(struct pci_dev *pdev,
 | 
					extern void vga_set_legacy_decoding(struct pci_dev *pdev,
 | 
				
			||||||
									unsigned int decodes);
 | 
									    unsigned int decodes);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
/**
 | 
					/**
 | 
				
			||||||
 *     vga_get         - acquire & locks VGA resources
 | 
					 *     vga_get         - acquire & locks VGA resources
 | 
				
			||||||
| 
						 | 
					@ -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
 | 
					 * They driver will get a callback when VGA arbitration is first used
 | 
				
			||||||
 * by userspace since we some older X servers have issues.
 | 
					 * 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,
 | 
					int vga_client_register(struct pci_dev *pdev, void *cookie,
 | 
				
			||||||
			void (*irq_set_state)(void *cookie, bool state),
 | 
								void (*irq_set_state)(void *cookie, bool state),
 | 
				
			||||||
			unsigned int (*set_vga_decode)(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 */
 | 
					#endif /* LINUX_VGA_H */
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue