summaryrefslogtreecommitdiff
path: root/linux-core/drm_drv.c
diff options
context:
space:
mode:
Diffstat (limited to 'linux-core/drm_drv.c')
-rw-r--r--linux-core/drm_drv.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/linux-core/drm_drv.c b/linux-core/drm_drv.c
index 3791d7a8..5337646f 100644
--- a/linux-core/drm_drv.c
+++ b/linux-core/drm_drv.c
@@ -424,10 +424,15 @@ static int DRM(takedown)( drm_device_t *dev )
*/
break;
case _DRM_SCATTER_GATHER:
+ /* Handle it, but do nothing, if HAVE_SG
+ * isn't defined.
+ */
+#if __HAVE_SG
if(dev->sg) {
DRM(sg_cleanup)(dev->sg);
dev->sg = NULL;
}
+#endif
break;
}
DRM(free)(map, sizeof(*map), DRM_MEM_MAPS);