mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-11-03 09:01:40 -05:00
Merge branch 'hotplug_mode_update' into 'master'
backend/drm: Add support for hotplug_mode_update connector property See merge request wlroots/wlroots!4891
This commit is contained in:
commit
de782370eb
3 changed files with 10 additions and 0 deletions
|
|
@ -1847,6 +1847,14 @@ void scan_drm_connectors(struct wlr_drm_backend *drm,
|
|||
drm_conn->connection != DRM_MODE_CONNECTED) {
|
||||
wlr_log(WLR_INFO, "'%s' disconnected", wlr_conn->name);
|
||||
disconnect_drm_connector(wlr_conn);
|
||||
} else if (wlr_conn->status == DRM_MODE_CONNECTED &&
|
||||
drm_conn->connection == DRM_MODE_CONNECTED
|
||||
&& wlr_conn->props.hotplug_mode_update > 0)
|
||||
{
|
||||
wlr_log(WLR_INFO, "'%s' reconnected", wlr_conn->name);
|
||||
disconnect_drm_connector(wlr_conn);
|
||||
connect_drm_connector(wlr_conn, drm_conn);
|
||||
new_outputs[new_outputs_len++] = wlr_conn;
|
||||
}
|
||||
|
||||
drmModeFreeConnector(drm_conn);
|
||||
|
|
|
|||
|
|
@ -28,6 +28,7 @@ static const struct prop_info connector_info[] = {
|
|||
{ "HDR_OUTPUT_METADATA", INDEX(hdr_output_metadata) },
|
||||
{ "PATH", INDEX(path) },
|
||||
{ "content type", INDEX(content_type) },
|
||||
{ "hotplug_mode_update", INDEX(hotplug_mode_update) },
|
||||
{ "link-status", INDEX(link_status) },
|
||||
{ "max bpc", INDEX(max_bpc) },
|
||||
{ "non-desktop", INDEX(non_desktop) },
|
||||
|
|
|
|||
|
|
@ -22,6 +22,7 @@ struct wlr_drm_connector_props {
|
|||
uint32_t panel_orientation; // not guaranteed to exist
|
||||
uint32_t content_type; // not guaranteed to exist
|
||||
uint32_t max_bpc; // not guaranteed to exist
|
||||
uint32_t hotplug_mode_update; // not guaranteed to exist, VMs only
|
||||
|
||||
// atomic-modesetting only
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue