summaryrefslogtreecommitdiff
path: root/linux-core
diff options
context:
space:
mode:
authorMaarten Maathuis <madman2003@gmail.com>2008-07-20 14:58:46 +0200
committerMaarten Maathuis <madman2003@gmail.com>2008-07-20 14:58:46 +0200
commite51cd78cac24df15e32e23d8db73614524e6ff0d (patch)
treea47f0ef716476a9bbd1d762cbd7d3e4bbdc7475c /linux-core
parentf1e4785d4cf04b679948602ffbbef2043ce81ec0 (diff)
modesetting-101: Only store property value when set_property was successful.
Diffstat (limited to 'linux-core')
-rw-r--r--linux-core/drm_crtc.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/linux-core/drm_crtc.c b/linux-core/drm_crtc.c
index c984209a..91bff1f6 100644
--- a/linux-core/drm_crtc.c
+++ b/linux-core/drm_crtc.c
@@ -2184,12 +2184,12 @@ int drm_mode_connector_property_set_ioctl(struct drm_device *dev,
}
}
- /* store the property value */
- drm_connector_property_set_value(connector, property, out_resp->value);
-
if (connector->funcs->set_property)
ret = connector->funcs->set_property(connector, property, out_resp->value);
+ /* store the property value if succesful */
+ if (!ret)
+ drm_connector_property_set_value(connector, property, out_resp->value);
out:
mutex_unlock(&dev->mode_config.mutex);
return ret;