diff options
author | Rob Clark <robdclark@gmail.com> | 2014-12-18 16:01:50 -0500 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2015-01-05 07:54:38 -0500 |
commit | 88a48e297b3a3bac6022c03babfb038f1a886cea (patch) | |
tree | 8b914276b0e77e447aa3de5f4d7cefc1597911b1 /include/drm/drmP.h | |
parent | 95cbf110756c21397946ded181cc5ea4ab568c11 (diff) |
drm: add atomic properties
Once a driver is using atomic helpers for modeset, the next step is to
switch over to atomic properties. To do this, make sure that any
modeset objects have their ->atomic_{get,set}_property() vfuncs suitably
populated if they have custom properties (you did already remember to
plug in atomic-helper func for the legacy ->set_property() vfuncs,
right?), and then set DRIVER_ATOMIC bit in driver_features flag.
A new cap is introduced, DRM_CLIENT_CAP_ATOMIC, for the purposes of
shielding legacy userspace from atomic properties. Mostly for the
benefit of legacy DDX drivers that do silly things like getting/setting
each property at startup (since some of the new atomic properties will
be able to trigger modeset).
Signed-off-by: Rob Clark <robdclark@gmail.com>
[danvet: Squash in fixup patch to check for DRM_MODE_PROP_ATOMIC
instaed of the CAP define when filtering properties. Reported by
Tvrtko Uruslin, acked by Rob.]
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'include/drm/drmP.h')
-rw-r--r-- | include/drm/drmP.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/drm/drmP.h b/include/drm/drmP.h index 8ba35c622e22..0f7115e988a0 100644 --- a/include/drm/drmP.h +++ b/include/drm/drmP.h | |||
@@ -143,6 +143,7 @@ void drm_err(const char *format, ...); | |||
143 | #define DRIVER_MODESET 0x2000 | 143 | #define DRIVER_MODESET 0x2000 |
144 | #define DRIVER_PRIME 0x4000 | 144 | #define DRIVER_PRIME 0x4000 |
145 | #define DRIVER_RENDER 0x8000 | 145 | #define DRIVER_RENDER 0x8000 |
146 | #define DRIVER_ATOMIC 0x10000 | ||
146 | 147 | ||
147 | /***********************************************************************/ | 148 | /***********************************************************************/ |
148 | /** \name Macros to make printk easier */ | 149 | /** \name Macros to make printk easier */ |
@@ -283,6 +284,8 @@ struct drm_file { | |||
283 | * in the plane list | 284 | * in the plane list |
284 | */ | 285 | */ |
285 | unsigned universal_planes:1; | 286 | unsigned universal_planes:1; |
287 | /* true if client understands atomic properties */ | ||
288 | unsigned atomic:1; | ||
286 | 289 | ||
287 | struct pid *pid; | 290 | struct pid *pid; |
288 | kuid_t uid; | 291 | kuid_t uid; |
@@ -950,6 +953,7 @@ extern void drm_master_put(struct drm_master **master); | |||
950 | extern void drm_put_dev(struct drm_device *dev); | 953 | extern void drm_put_dev(struct drm_device *dev); |
951 | extern void drm_unplug_dev(struct drm_device *dev); | 954 | extern void drm_unplug_dev(struct drm_device *dev); |
952 | extern unsigned int drm_debug; | 955 | extern unsigned int drm_debug; |
956 | extern bool drm_atomic; | ||
953 | 957 | ||
954 | /* Debugfs support */ | 958 | /* Debugfs support */ |
955 | #if defined(CONFIG_DEBUG_FS) | 959 | #if defined(CONFIG_DEBUG_FS) |