summaryrefslogtreecommitdiff
path: root/include/drm
diff options
context:
space:
mode:
authorRob Clark <robdclark@gmail.com>2016-11-15 01:40:57 +0300
committerDaniel Vetter <daniel.vetter@ffwll.ch>2016-11-15 10:33:35 +0300
commit35cf03508d8466ecc5199c9d609e74e85bec785b (patch)
tree967ecc9746c8f8c3de8773d2efdadc12a1a5a836 /include/drm
parent6bfec6d94556683c91c937a20576118183af9e1d (diff)
downloadlinux-35cf03508d8466ecc5199c9d609e74e85bec785b.tar.xz
drm: don't let crtc_ww_class leak out
kbuild spotted this error, with drm/msm patches that add a new modeset-lock in the driver and driver built as a module: ERROR: "crtc_ww_class" [drivers/gpu/drm/msm/msm.ko] undefined! Really the only reason for crtc_ww_class not being internal to drm_modeset_lock.c is that drm_modeset_lock_init() was static-inline (for no particularly good reason). Fix that, and move crtc_ww_class into drm_modeset_lock.c. Signed-off-by: Rob Clark <robdclark@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1479163257-18703-1-git-send-email-robdclark@gmail.com
Diffstat (limited to 'include/drm')
-rw-r--r--include/drm/drm_modeset_lock.h12
1 files changed, 1 insertions, 11 deletions
diff --git a/include/drm/drm_modeset_lock.h b/include/drm/drm_modeset_lock.h
index c5576fbcb909..d918ce45ec2c 100644
--- a/include/drm/drm_modeset_lock.h
+++ b/include/drm/drm_modeset_lock.h
@@ -82,8 +82,6 @@ struct drm_modeset_lock {
struct list_head head;
};
-extern struct ww_class crtc_ww_class;
-
void drm_modeset_acquire_init(struct drm_modeset_acquire_ctx *ctx,
uint32_t flags);
void drm_modeset_acquire_fini(struct drm_modeset_acquire_ctx *ctx);
@@ -91,15 +89,7 @@ void drm_modeset_drop_locks(struct drm_modeset_acquire_ctx *ctx);
void drm_modeset_backoff(struct drm_modeset_acquire_ctx *ctx);
int drm_modeset_backoff_interruptible(struct drm_modeset_acquire_ctx *ctx);
-/**
- * drm_modeset_lock_init - initialize lock
- * @lock: lock to init
- */
-static inline void drm_modeset_lock_init(struct drm_modeset_lock *lock)
-{
- ww_mutex_init(&lock->mutex, &crtc_ww_class);
- INIT_LIST_HEAD(&lock->head);
-}
+void drm_modeset_lock_init(struct drm_modeset_lock *lock);
/**
* drm_modeset_lock_fini - cleanup lock