summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/drm_crtc.c
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2016-03-16 11:09:26 +1000
committerDave Airlie <airlied@redhat.com>2016-03-16 11:09:26 +1000
commit1a4be38a3a46898fee61b3ec1631d273dd66fcf2 (patch)
tree41b84d54c0fd5dfb9bfe628f04b8ad154056e02f /drivers/gpu/drm/drm_crtc.c
parentc51e034fedb002fcd0c012864d79d131cd629369 (diff)
parentc1f415c9acb5877c408d9311eb837d7d50636a68 (diff)
downloadop-kernel-dev-1a4be38a3a46898fee61b3ec1631d273dd66fcf2.zip
op-kernel-dev-1a4be38a3a46898fee61b3ec1631d273dd66fcf2.tar.gz
Merge tag 'topic/drm-misc-2016-03-14' of git://anongit.freedesktop.org/drm-intel into drm-next
* tag 'topic/drm-misc-2016-03-14' of git://anongit.freedesktop.org/drm-intel: (27 commits) drm: atomic helper: do not unreference error pointer drm/edid: Extract SADs properly from multiple audio data blocks drm: fix blob pointer check drm: introduce pipe color correction properties drm/atomic: Clean up update_connector_routing. drm/atomic: Clean up steal_encoder, v2. drm/atomic: Handle encoder assignment conflicts in a separate check, v3. drm/atomic: Handle encoder stealing from set_config better. drm/atomic: Always call steal_encoder, v2. drm/ast: removed optional dummy crtc mode_fixup function. drm/bochs: removed optional dummy crtc mode_fixup function. drm/fsl-dcu: removed optional dummy crtc mode_fixup function. drm/virtio: removed optional dummy crtc mode_fixup function. drm/nouveau/dispnv04: removed optional dummy crtc mode_fixup function. drm/atmel-hlcdc: remove optional dummy crtc mode_fixup function. drm/sti: removed optional dummy crtc mode_fixup function. drm/shmobile: removed optional dummy crtc mode_fixup function. drm/msm/mdp: removed optional dummy crtc mode_fixup function. drm/omapdrm: removed optional dummy crtc mode_fixup function. drm/rcar-du: removed optional dummy crtc mode_fixup function. ...
Diffstat (limited to 'drivers/gpu/drm/drm_crtc.c')
-rw-r--r--drivers/gpu/drm/drm_crtc.c39
1 files changed, 36 insertions, 3 deletions
diff --git a/drivers/gpu/drm/drm_crtc.c b/drivers/gpu/drm/drm_crtc.c
index 8451400..e08f962 100644
--- a/drivers/gpu/drm/drm_crtc.c
+++ b/drivers/gpu/drm/drm_crtc.c
@@ -430,9 +430,7 @@ EXPORT_SYMBOL(drm_framebuffer_init);
static void __drm_framebuffer_unregister(struct drm_device *dev,
struct drm_framebuffer *fb)
{
- mutex_lock(&dev->mode_config.idr_mutex);
- idr_remove(&dev->mode_config.crtc_idr, fb->base.id);
- mutex_unlock(&dev->mode_config.idr_mutex);
+ drm_mode_object_put(dev, &fb->base);
fb->base.id = 0;
}
@@ -1554,6 +1552,41 @@ static int drm_mode_create_standard_properties(struct drm_device *dev)
return -ENOMEM;
dev->mode_config.prop_mode_id = prop;
+ prop = drm_property_create(dev,
+ DRM_MODE_PROP_BLOB,
+ "DEGAMMA_LUT", 0);
+ if (!prop)
+ return -ENOMEM;
+ dev->mode_config.degamma_lut_property = prop;
+
+ prop = drm_property_create_range(dev,
+ DRM_MODE_PROP_IMMUTABLE,
+ "DEGAMMA_LUT_SIZE", 0, UINT_MAX);
+ if (!prop)
+ return -ENOMEM;
+ dev->mode_config.degamma_lut_size_property = prop;
+
+ prop = drm_property_create(dev,
+ DRM_MODE_PROP_BLOB,
+ "CTM", 0);
+ if (!prop)
+ return -ENOMEM;
+ dev->mode_config.ctm_property = prop;
+
+ prop = drm_property_create(dev,
+ DRM_MODE_PROP_BLOB,
+ "GAMMA_LUT", 0);
+ if (!prop)
+ return -ENOMEM;
+ dev->mode_config.gamma_lut_property = prop;
+
+ prop = drm_property_create_range(dev,
+ DRM_MODE_PROP_IMMUTABLE,
+ "GAMMA_LUT_SIZE", 0, UINT_MAX);
+ if (!prop)
+ return -ENOMEM;
+ dev->mode_config.gamma_lut_size_property = prop;
+
return 0;
}
OpenPOWER on IntegriCloud