Skip to contentSkip to conversation

drm: Include <asm/agp.h> iff CONFIG_AGP is set

PATCH In review Thomas Zimmermann 2 participants 2 messages May 10, 2021

Subsystems (2)
lore
Share & tools
lore

Thomas Zimmermann

author maintainer
#0 lore raw

PATCH 1/1 drm: Include <asm/agp.h> iff CONFIG_AGP is set

Platforms without AGP don't provide the AGP header. Only include it if CONFIG_AGP is set.

Fixes 04dfe19a5ed6 ("drm: Mark AGP implementation and ioctls as legacy")
Cc Thomas Zimmermann <[email protected]>
Cc Alex Deucher <[email protected]>
Cc Christian König <[email protected]>
Cc Maarten Lankhorst <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc David Airlie <[email protected]>
Cc Daniel Vetter <[email protected]>
Cc "Christian König" <[email protected]>
Cc Christophe JAILLET <[email protected]>
Cc Jason Yan <[email protected]>
Cc Lee Jones <[email protected]>
Cc Sam Ravnborg <[email protected]>
---
 drivers/gpu/drm/drm_agpsupport.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpu/drm/drm_agpsupport.c +2 -0
index 07c10443770e..a4ad6fd13abc 100644
@@ -35,7 +35,9 @@
 #include <linux/pci.h>
 #include <linux/slab.h>
 
+#if IS_ENABLED(CONFIG_AGP)
 #include <asm/agp.h>
+#endif
 
 #include <drm/drm_device.h>
 #include <drm/drm_drv.h>
Signature · 1 line
2.31.1
Reviewed-by on v1 1/1
#1 lore raw
Quoted 4 lines · Thomas Zimmermann

Platforms without AGP don't provide the AGP header. Only include it if CONFIG_AGP is set.

Quoted 15 lines
Fixes 04dfe19a5ed6 ("drm: Mark AGP implementation and ioctls as legacy")
Cc Thomas Zimmermann <[email protected]>
Cc Alex Deucher <[email protected]>
Cc Christian König <[email protected]>
Cc Maarten Lankhorst <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc David Airlie <[email protected]>
Cc Daniel Vetter <[email protected]>
Cc "Christian König" <[email protected]>
Cc Christophe JAILLET <[email protected]>
Cc Jason Yan <[email protected]>
Cc Lee Jones <[email protected]>
Cc Sam Ravnborg <[email protected]>
Quoted 21 lines
---
 drivers/gpu/drm/drm_agpsupport.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpu/drm/drm_agpsupport.c +2 -1
index 07c10443770e..a4ad6fd13abc 100644
@@ -35,7 +35,9 @@
 #include <linux/pci.h>
 #include <linux/slab.h>
 
+#if IS_ENABLED(CONFIG_AGP)
 #include <asm/agp.h>
+#endif
 
 #include <drm/drm_device.h>
 #include <drm/drm_drv.h>
--

2.31.1