diff options
author | Alex Deucher <alexdeucher@gmail.com> | 2009-10-12 11:25:05 -0400 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2009-10-13 08:45:52 +1000 |
commit | fb06ca8f8c61dfd7cbfa2092756577ff78a26dcd (patch) | |
tree | 460ae7fd3c14008f9f683f95b196dd5f0cbeaffb /drivers/gpu/drm/radeon/radeon_connectors.c | |
parent | 39deb2d67515086f08a672e7574716ca0d3883a5 (diff) | |
download | lwn-fb06ca8f8c61dfd7cbfa2092756577ff78a26dcd.tar.gz lwn-fb06ca8f8c61dfd7cbfa2092756577ff78a26dcd.zip |
drm/radeon/kms: properly handle mode id with native mode changes
drm modes are objects with indentifiers. Make sure to preserve
the mode id when copying mode params.
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/radeon_connectors.c')
-rw-r--r-- | drivers/gpu/drm/radeon/radeon_connectors.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_connectors.c b/drivers/gpu/drm/radeon/radeon_connectors.c index 17d5659cff03..729207a1e83e 100644 --- a/drivers/gpu/drm/radeon/radeon_connectors.c +++ b/drivers/gpu/drm/radeon/radeon_connectors.c @@ -183,8 +183,7 @@ static struct drm_display_mode *radeon_fp_native_mode(struct drm_encoder *encode if (native_mode->hdisplay != 0 && native_mode->vdisplay != 0 && native_mode->clock != 0) { - mode = drm_mode_create(dev); - *mode = *native_mode; + mode = drm_mode_duplicate(dev, native_mode); mode->type = DRM_MODE_TYPE_PREFERRED | DRM_MODE_TYPE_DRIVER; drm_mode_set_name(mode); |