summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/drm_drv.c
diff options
context:
space:
mode:
authorGustavo Padovan <gustavo.padovan@collabora.co.uk>2015-08-13 23:06:39 +0300
committerDaniel Vetter <daniel.vetter@ffwll.ch>2015-09-08 14:45:46 +0300
commitbcfe0c0954f3336c44993e5ce444e09ad6087637 (patch)
tree2b834461c98b04ff8b9399db26b357f7d1b30005 /drivers/gpu/drm/drm_drv.c
parent73bf1b7be7aab60d7c651402441dd0b0b4991098 (diff)
downloadlinux-bcfe0c0954f3336c44993e5ce444e09ad6087637.tar.xz
drm: WARN_ON if a modeset driver uses legacy suspend/resume helpers
Legacy s/r hooks are only used for shadow-attaching drivers, warn when a KMS driver tries to use them. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/drm_drv.c')
-rw-r--r--drivers/gpu/drm/drm_drv.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/drm_drv.c b/drivers/gpu/drm/drm_drv.c
index 53d09a19f7e1..dc93c881f29d 100644
--- a/drivers/gpu/drm/drm_drv.c
+++ b/drivers/gpu/drm/drm_drv.c
@@ -566,6 +566,8 @@ struct drm_device *drm_dev_alloc(struct drm_driver *driver,
ret = drm_minor_alloc(dev, DRM_MINOR_CONTROL);
if (ret)
goto err_minors;
+
+ WARN_ON(driver->suspend || driver->resume);
}
if (drm_core_check_feature(dev, DRIVER_RENDER)) {