diff options
author | Dave Airlie <airlied@redhat.com> | 2014-06-05 00:01:29 -0400 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2014-07-07 21:39:04 -0400 |
commit | 2390cd11bfbe8d2b1b28c4e0f01fe7e122f7196d (patch) | |
tree | 4ad036c2d84d86465bde21bdce1ec66862660396 /drivers/gpu/drm/drm_crtc.c | |
parent | 40377ef2d9a3ddc8ba4aee11393fb207e82111e1 (diff) |
drm/crtc: add interface to reinitialise the legacy mode group
This can be called to update things after dynamic connectors/encoders
are created/deleted.
Reviewed-by: Todd Previte <tprevite@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/drm_crtc.c')
-rw-r--r-- | drivers/gpu/drm/drm_crtc.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/gpu/drm/drm_crtc.c b/drivers/gpu/drm/drm_crtc.c index 7db6251c38e7..f939b058953c 100644 --- a/drivers/gpu/drm/drm_crtc.c +++ b/drivers/gpu/drm/drm_crtc.c | |||
@@ -1513,6 +1513,15 @@ int drm_mode_group_init_legacy_group(struct drm_device *dev, | |||
1513 | } | 1513 | } |
1514 | EXPORT_SYMBOL(drm_mode_group_init_legacy_group); | 1514 | EXPORT_SYMBOL(drm_mode_group_init_legacy_group); |
1515 | 1515 | ||
1516 | void drm_reinit_primary_mode_group(struct drm_device *dev) | ||
1517 | { | ||
1518 | drm_modeset_lock_all(dev); | ||
1519 | drm_mode_group_destroy(&dev->primary->mode_group); | ||
1520 | drm_mode_group_init_legacy_group(dev, &dev->primary->mode_group); | ||
1521 | drm_modeset_unlock_all(dev); | ||
1522 | } | ||
1523 | EXPORT_SYMBOL(drm_reinit_primary_mode_group); | ||
1524 | |||
1516 | /** | 1525 | /** |
1517 | * drm_crtc_convert_to_umode - convert a drm_display_mode into a modeinfo | 1526 | * drm_crtc_convert_to_umode - convert a drm_display_mode into a modeinfo |
1518 | * @out: drm_mode_modeinfo struct to return to the user | 1527 | * @out: drm_mode_modeinfo struct to return to the user |