From: "Lankhorst, Maarten" <maarten.lankhorst@intel.com>
To: "intel-gfx@lists.freedesktop.org"
<intel-gfx@lists.freedesktop.org>,
"Pandiyan, Dhinakaran" <dhinakaran.pandiyan@intel.com>
Cc: "alexander.deucher@amd.com" <alexander.deucher@amd.com>,
"daniel.vetter@ffwll.ch" <daniel.vetter@ffwll.ch>,
"harry.wentland@amd.com" <harry.wentland@amd.com>,
"bskeggs@redhat.com" <bskeggs@redhat.com>,
"dri-devel@lists.freedesktop.org"
<dri-devel@lists.freedesktop.org>
Subject: Re: [PATCH v3 7/8] drm: Connector helper function to release resources
Date: Thu, 9 Feb 2017 09:01:09 +0000 [thread overview]
Message-ID: <1486630868.30626.17.camel@intel.com> (raw)
In-Reply-To: <1486622291-3524-8-git-send-email-dhinakaran.pandiyan@intel.com>
Dhinakaran Pandiyan schreef op wo 08-02-2017 om 22:38 [-0800]:
> Having a ->atomic_release callback is useful to release shared
> resources
> that get allocated in compute_config(). This function is expected to
> be
> called in the atomic_check() phase before new resources are acquired.
>
> v2: Moved the caller hunk to this patch (Daniel)
>
> Suggested-by: Daniel Vetter <daniel.vetter@ffwll.ch>
> Signed-off-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
> ---
> drivers/gpu/drm/drm_atomic_helper.c | 19 +++++++++++++++++++
> include/drm/drm_modeset_helper_vtables.h | 13 +++++++++++++
> 2 files changed, 32 insertions(+)
>
> diff --git a/drivers/gpu/drm/drm_atomic_helper.c
> b/drivers/gpu/drm/drm_atomic_helper.c
> index 8795088..92bd741 100644
> --- a/drivers/gpu/drm/drm_atomic_helper.c
> +++ b/drivers/gpu/drm/drm_atomic_helper.c
> @@ -576,6 +576,25 @@ drm_atomic_helper_check_modeset(struct
> drm_device *dev,
> }
> }
>
> + for_each_connector_in_state(state, connector,
> connector_state, i) {
> + const struct drm_connector_helper_funcs *conn_funcs;
> + struct drm_crtc_state *crtc_state;
> +
> + conn_funcs = connector->helper_private;
> + if (!conn_funcs->atomic_release)
> + continue;
> +
> + if (!connector->state->crtc)
> + continue;
> +
> + crtc_state =
> drm_atomic_get_existing_crtc_state(state, connector->state->crtc);
> +
> + if (crtc_state->connectors_changed ||
> + crtc_state->mode_changed ||
> + (crtc_state->active_changed && !crtc_state-
> >active))
> + conn_funcs->atomic_release(connector,
> connector_state);
> + }
Could we deal with the VCPI state separately in intel_modeset_checks,
like we do with dpll?
Maybe implementing the relevant VCPI state could be done as an atomic
helper function too, so other atomic drivers can just plug it in.
Not sure how doable this is, but if it's not too hard, then it's
probably cleaner :)
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2017-02-09 9:01 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-09 6:38 [PATCH v3 0/8] Adding driver-private objects to atomic state Dhinakaran Pandiyan
2017-02-09 6:38 ` [PATCH v3 1/8] drm/dp: Kill total_pbn and total_slots in struct drm_dp_mst_topology_mgr Dhinakaran Pandiyan
2017-02-09 6:38 ` [PATCH v3 2/8] drm/dp: Kill unused MST vcpi slot availability tracking Dhinakaran Pandiyan
2017-02-09 6:38 ` [PATCH v3 3/8] drm/dp: Split drm_dp_mst_allocate_vcpi Dhinakaran Pandiyan
2017-02-09 6:38 ` [PATCH v3 4/8] drm: Add driver-private objects to atomic state Dhinakaran Pandiyan
2017-02-09 8:08 ` Chris Wilson
2017-02-09 18:57 ` Pandiyan, Dhinakaran
2017-02-15 11:23 ` Archit Taneja
2017-02-16 0:13 ` Pandiyan, Dhinakaran
2017-02-17 10:07 ` Archit Taneja
2017-02-22 0:01 ` Pandiyan, Dhinakaran
2017-02-22 4:29 ` Archit Taneja
2017-02-22 21:10 ` Pandiyan, Dhinakaran
2017-02-26 19:57 ` Daniel Vetter
2017-02-27 18:51 ` Pandiyan, Dhinakaran
2017-03-02 22:31 ` Pandiyan, Dhinakaran
2017-02-09 6:38 ` [PATCH v3 5/8] drm/dp: Introduce MST topology state to track available link bandwidth Dhinakaran Pandiyan
2017-02-09 6:38 ` [PATCH v3 6/8] drm/dp: Add DP MST helpers to atomically find and release vcpi slots Dhinakaran Pandiyan
2017-02-09 6:38 ` [PATCH v3 7/8] drm: Connector helper function to release resources Dhinakaran Pandiyan
2017-02-09 9:01 ` Lankhorst, Maarten [this message]
2017-02-09 18:55 ` Pandiyan, Dhinakaran
2017-02-13 9:05 ` Lankhorst, Maarten
2017-02-13 21:26 ` Pandiyan, Dhinakaran
2017-02-13 22:48 ` Pandiyan, Dhinakaran
2017-02-20 9:40 ` Lankhorst, Maarten
2017-02-14 19:51 ` Daniel Vetter
2017-02-14 22:29 ` Pandiyan, Dhinakaran
2017-02-16 9:09 ` Lankhorst, Maarten
2017-02-24 0:52 ` Pandiyan, Dhinakaran
2017-02-26 20:00 ` [Intel-gfx] " Daniel Vetter
2017-02-27 7:42 ` Lankhorst, Maarten
2017-02-09 6:38 ` [PATCH v3 8/8] drm/dp: Track MST link bandwidth Dhinakaran Pandiyan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1486630868.30626.17.camel@intel.com \
--to=maarten.lankhorst@intel.com \
--cc=alexander.deucher@amd.com \
--cc=bskeggs@redhat.com \
--cc=daniel.vetter@ffwll.ch \
--cc=dhinakaran.pandiyan@intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=harry.wentland@amd.com \
--cc=intel-gfx@lists.freedesktop.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).