search for: drm_atomic_get_crtc_st

Displaying 20 results from an estimated 49 matches for "drm_atomic_get_crtc_st".

2017 Feb 21
2
[PATCH 1/3] drm/atomic: Make disable_all helper fully disable the crtc.
...r_list_iter_get(dev, &conn_iter); - drm_for_each_connector_iter(conn, &conn_iter) { - struct drm_crtc *crtc = conn->state->crtc; - struct drm_crtc_state *crtc_state; - - if (!crtc || conn->dpms != DRM_MODE_DPMS_ON) - continue; - + drm_for_each_crtc(crtc, dev) { crtc_state = drm_atomic_get_crtc_state(state, crtc); if (IS_ERR(crtc_state)) { - err = PTR_ERR(crtc_state); + ret = PTR_ERR(crtc_state); goto free; } crtc_state->active = false; + + ret = drm_atomic_set_mode_prop_for_crtc(crtc_state, NULL); + if (ret < 0) + goto free; + + ret = drm_atomic_add_affected_pl...
2017 Jan 09
0
[PATCH 3/3] drm/atomic: Make disable_all helper fully disable the crtc.
...r_list_iter_get(dev, &conn_iter); - drm_for_each_connector_iter(conn, &conn_iter) { - struct drm_crtc *crtc = conn->state->crtc; - struct drm_crtc_state *crtc_state; - - if (!crtc || conn->dpms != DRM_MODE_DPMS_ON) - continue; - + drm_for_each_crtc(crtc, dev) { crtc_state = drm_atomic_get_crtc_state(state, crtc); if (IS_ERR(crtc_state)) { - err = PTR_ERR(crtc_state); + ret = PTR_ERR(crtc_state); goto free; } crtc_state->active = false; + + ret = drm_atomic_set_mode_prop_for_crtc(crtc_state, NULL); + if (ret < 0) + goto free; + + ret = drm_atomic_add_affected_pl...
2019 May 02
4
[PATCH v3 04/10] drm: Convert connector_helper_funcs->atomic_check to accept drm_atomic_state
...if (!conn_state->crtc) return 0; if (list_empty(&connector->modes)) { @@ -110,9 +112,9 @@ static int rcar_lvds_connector_atomic_check(struct drm_connector *connector, struct drm_display_mode, head); /* We're not allowed to modify the resolution. */ - crtc_state = drm_atomic_get_crtc_state(state->state, state->crtc); - if (IS_ERR(crtc_state)) - return PTR_ERR(crtc_state); + crtc_state = drm_atomic_get_crtc_state(state, conn_state->crtc); + if (!crtc_state) + return -EINVAL; if (crtc_state->mode.hdisplay != panel_mode->hdisplay || crtc_state->mode.vdis...
2017 Feb 23
0
[Intel-gfx] [PATCH 1/3] drm/atomic: Make disable_all helper fully disable the crtc.
...drm_for_each_connector_iter(conn, &conn_iter) { > - struct drm_crtc *crtc = conn->state->crtc; > - struct drm_crtc_state *crtc_state; > - > - if (!crtc || conn->dpms != DRM_MODE_DPMS_ON) > - continue; > - > + drm_for_each_crtc(crtc, dev) { > crtc_state = drm_atomic_get_crtc_state(state, crtc); > if (IS_ERR(crtc_state)) { > - err = PTR_ERR(crtc_state); > + ret = PTR_ERR(crtc_state); > goto free; > } > > crtc_state->active = false; > + > + ret = drm_atomic_set_mode_prop_for_crtc(crtc_state, NULL); > + if (ret < 0) &g...
2019 May 13
2
[PATCH v3 04/10] drm: Convert connector_helper_funcs->atomic_check to accept drm_atomic_state
...s)) { > > @@ -110,9 +112,9 @@ static int rcar_lvds_connector_atomic_check(struct drm_connector *connector, > > struct drm_display_mode, head); > > > > /* We're not allowed to modify the resolution. */ > > - crtc_state = drm_atomic_get_crtc_state(state->state, state->crtc); > > - if (IS_ERR(crtc_state)) > > - return PTR_ERR(crtc_state); > > + crtc_state = drm_atomic_get_crtc_state(state, conn_state->crtc); > > + if (!crtc_state) > > + return -EINVAL; > > &gt...
2019 Jun 11
1
[PATCH v5 04/11] drm: Convert connector_helper_funcs->atomic_check to accept drm_atomic_state
...if (!conn_state->crtc) return 0; if (list_empty(&connector->modes)) { @@ -110,9 +112,9 @@ static int rcar_lvds_connector_atomic_check(struct drm_connector *connector, struct drm_display_mode, head); /* We're not allowed to modify the resolution. */ - crtc_state = drm_atomic_get_crtc_state(state->state, state->crtc); - if (IS_ERR(crtc_state)) - return PTR_ERR(crtc_state); + crtc_state = drm_atomic_get_crtc_state(state, conn_state->crtc); + if (!crtc_state) + return -EINVAL; if (crtc_state->mode.hdisplay != panel_mode->hdisplay || crtc_state->mode.vdis...
2019 May 13
2
[PATCH v3 04/10] drm: Convert connector_helper_funcs->atomic_check to accept drm_atomic_state
...t_empty(&connector->modes)) { > > @@ -110,9 +112,9 @@ static int rcar_lvds_connector_atomic_check(struct drm_connector *connector, > > struct drm_display_mode, head); > > > > /* We're not allowed to modify the resolution. */ > > - crtc_state = drm_atomic_get_crtc_state(state->state, state->crtc); > > - if (IS_ERR(crtc_state)) > > - return PTR_ERR(crtc_state); > > + crtc_state = drm_atomic_get_crtc_state(state, conn_state->crtc); > > + if (!crtc_state) > > + return -EINVAL; > > > > if (crtc_state->mode...
2019 May 11
0
[PATCH v3 04/10] drm: Convert connector_helper_funcs->atomic_check to accept drm_atomic_state
...0; > > if (list_empty(&connector->modes)) { > @@ -110,9 +112,9 @@ static int rcar_lvds_connector_atomic_check(struct drm_connector *connector, > struct drm_display_mode, head); > > /* We're not allowed to modify the resolution. */ > - crtc_state = drm_atomic_get_crtc_state(state->state, state->crtc); > - if (IS_ERR(crtc_state)) > - return PTR_ERR(crtc_state); > + crtc_state = drm_atomic_get_crtc_state(state, conn_state->crtc); > + if (!crtc_state) > + return -EINVAL; > > if (crtc_state->mode.hdisplay != panel_mode->hdispla...
2019 May 08
0
[PATCH v4 04/11] drm: Convert connector_helper_funcs->atomic_check to accept drm_atomic_state
...if (!conn_state->crtc) return 0; if (list_empty(&connector->modes)) { @@ -110,9 +112,9 @@ static int rcar_lvds_connector_atomic_check(struct drm_connector *connector, struct drm_display_mode, head); /* We're not allowed to modify the resolution. */ - crtc_state = drm_atomic_get_crtc_state(state->state, state->crtc); - if (IS_ERR(crtc_state)) - return PTR_ERR(crtc_state); + crtc_state = drm_atomic_get_crtc_state(state, conn_state->crtc); + if (!crtc_state) + return -EINVAL; if (crtc_state->mode.hdisplay != panel_mode->hdisplay || crtc_state->mode.vdis...
2019 May 16
0
[PATCH v3 04/10] drm: Convert connector_helper_funcs->atomic_check to accept drm_atomic_state
...@@ -110,9 +112,9 @@ static int rcar_lvds_connector_atomic_check(struct drm_connector *connector, > >> struct drm_display_mode, head); > >> > >> /* We're not allowed to modify the resolution. */ > >> - crtc_state = drm_atomic_get_crtc_state(state->state, state->crtc); > >> - if (IS_ERR(crtc_state)) > >> - return PTR_ERR(crtc_state); > >> + crtc_state = drm_atomic_get_crtc_state(state, conn_state->crtc); > >> + if (!crtc_state) > >> + return -E...
2019 May 16
0
[PATCH v3 04/10] drm: Convert connector_helper_funcs->atomic_check to accept drm_atomic_state
...or->modes)) { > >> @@ -110,9 +112,9 @@ static int rcar_lvds_connector_atomic_check(struct drm_connector *connector, > >> struct drm_display_mode, head); > >> > >> /* We're not allowed to modify the resolution. */ > >> - crtc_state = drm_atomic_get_crtc_state(state->state, state->crtc); > >> - if (IS_ERR(crtc_state)) > >> - return PTR_ERR(crtc_state); > >> + crtc_state = drm_atomic_get_crtc_state(state, conn_state->crtc); > >> + if (!crtc_state) > >> + return -EINVAL; > >> > >&g...
2019 May 27
0
[PATCH] drm/virtio: add plane check
...static int virtio_gpu_plane_atomic_check(struct drm_plane *plane, struct drm_plane_state *state) { - return 0; + bool is_cursor = plane->type == DRM_PLANE_TYPE_CURSOR; + struct drm_crtc_state *crtc_state; + int ret; + + if (!state->fb | !state->crtc) + return 0; + + crtc_state = drm_atomic_get_crtc_state(state->state, state->crtc); + if (IS_ERR(crtc_state)) + return PTR_ERR(crtc_state); + + ret = drm_atomic_helper_check_plane_state(state, crtc_state, + DRM_PLANE_HELPER_NO_SCALING, + DRM_PLANE_HELPER_NO_SCALING, + is_cursor, true); + return ret; } sta...
2019 Dec 13
0
[PATCH 08/10] drm/virtio: plane_state->fb iff plane_state->crtc
...c +++ b/drivers/gpu/drm/virtio/virtgpu_plane.c @@ -88,7 +88,7 @@ static int virtio_gpu_plane_atomic_check(struct drm_plane *plane, struct drm_crtc_state *crtc_state; int ret; - if (!state->fb || !state->crtc) + if (!state->fb || WARN_ON(!state->crtc)) return 0; crtc_state = drm_atomic_get_crtc_state(state->state, state->crtc); -- 2.24.0
2017 Jan 17
4
[PATCH v2 0/3] Allow ASYNC flip with atomic helpers.
This series is a folow-up on https://patchwork.kernel.org/patch/9501787/ The first patch makes changes to atomic helpers to allow for drives with ASYNC flip support to use them. Patch 2 is to use this in AMDGPU/DC. Patch 3 is possible cleanup in nouveau/kms who seems to have to duplicate the helper as we did to support ASYNC flips. v2: Resend drm/atomic: Save flip flags in drm_plane_state
2017 Jan 17
0
[PATCH v2 3/3] drm/nouveau/kms/nv50: Switch to using atomic helper for flip.
...; - struct drm_atomic_state *state; - struct drm_plane_state *plane_state; - struct drm_crtc_state *crtc_state; - int ret = 0; - - state = drm_atomic_state_alloc(plane->dev); - if (!state) - return -ENOMEM; - - state->acquire_ctx = drm_modeset_legacy_acquire_ctx(crtc); -retry: - crtc_state = drm_atomic_get_crtc_state(state, crtc); - if (IS_ERR(crtc_state)) { - ret = PTR_ERR(crtc_state); - goto fail; - } - crtc_state->event = event; - - plane_state = drm_atomic_get_plane_state(state, plane); - if (IS_ERR(plane_state)) { - ret = PTR_ERR(plane_state); - goto fail; - } - - ret = drm_atomic_set_crtc_for_pl...
2017 Jul 25
2
[PATCH 4/8] drm: Nuke drm_atomic_helper_crtc_set_property
...*state; - struct drm_crtc_state *crtc_state; - int ret = 0; - - state = drm_atomic_state_alloc(crtc->dev); - if (!state) - return -ENOMEM; - - /* ->set_property is always called with all locks held. */ - state->acquire_ctx = crtc->dev->mode_config.acquire_ctx; -retry: - crtc_state = drm_atomic_get_crtc_state(state, crtc); - if (IS_ERR(crtc_state)) { - ret = PTR_ERR(crtc_state); - goto fail; - } - - ret = drm_atomic_crtc_set_property(crtc, crtc_state, - property, val); - if (ret) - goto fail; - - ret = drm_atomic_commit(state); -fail: - if (ret == -EDEADLK) - goto backoff; - - drm_atomic_state_...
2018 Sep 19
1
[PATCH v2 1/6] drm/dp_mst: Introduce drm_dp_mst_connector_atomic_check()
...[drm]] pid=12928, dev=0xe201, auth=1, DRM_IOCTL_MODE_SETPROPERTY [ 2908.638546] [drm:drm_atomic_state_init [drm]] Allocated atomic state 000000007155ba49 [ 2908.638553] [drm:drm_mode_object_get [drm]] OBJ ID: 114 (1) [ 2908.638560] [drm:drm_mode_object_get [drm]] OBJ ID: 108 (1) [ 2908.638568] [drm:drm_atomic_get_crtc_state [drm]] Added [CRTC:41:head-0] 0000000097a6396e state to 000000007155ba49 [ 2908.638575] [drm:drm_atomic_add_affected_connectors [drm]] Adding all current connectors for [CRTC:41:head-0] to 000000007155ba49 [ 2908.638582] [drm:drm_mode_object_get [drm]] OBJ ID: 82 (3) [ 2908.638589] [drm:drm_mode...
2017 Jan 29
7
[v3 PATCH 0/3] Allow ASYNC flip with atomic helpers.
This series is a folow-up on https://patchwork.kernel.org/patch/9501787/ The first patch makes changes to atomic helpers to allow for drives with ASYNC flip support to use them. Patch 2 is to use this in AMDGPU/DC. Patch 3 is possible cleanup in nouveau/kms who seems to have to duplicate the helper as we did to support ASYNC flips. v2: Resend drm/atomic: Save flip flags in drm_plane_state
2017 Jan 16
0
[PATCH 3/4] drm/amd/display: Switch to using atomic_helper for flip.
...lane_state; - struct drm_crtc_state *crtc_state; - int ret = 0; - - state = drm_atomic_state_alloc(plane->dev); - if (!state) - return -ENOMEM; - - ret = drm_crtc_vblank_get(crtc); - if (ret) - return ret; - - state->acquire_ctx = drm_modeset_legacy_acquire_ctx(crtc); -retry: - crtc_state = drm_atomic_get_crtc_state(state, crtc); - if (IS_ERR(crtc_state)) { - ret = PTR_ERR(crtc_state); - goto fail; - } - crtc_state->event = event; - - plane_state = drm_atomic_get_plane_state(state, plane); - if (IS_ERR(plane_state)) { - ret = PTR_ERR(plane_state); - goto fail; - } - - ret = drm_atomic_set_crtc_for_pl...
2019 May 16
1
[PATCH v3 04/10] drm: Convert connector_helper_funcs->atomic_check to accept drm_atomic_state
...112,9 @@ static int rcar_lvds_connector_atomic_check(struct drm_connector *connector, > > >> struct drm_display_mode, head); > > >> > > >> /* We're not allowed to modify the resolution. */ > > >> - crtc_state = drm_atomic_get_crtc_state(state->state, state->crtc); > > >> - if (IS_ERR(crtc_state)) > > >> - return PTR_ERR(crtc_state); > > >> + crtc_state = drm_atomic_get_crtc_state(state, conn_state->crtc); > > >> + if (!crtc_state) > > >> +...