From: "Pandiyan, Dhinakaran" <dhinakaran.pandiyan@intel.com>
To: "lyude@redhat.com" <lyude@redhat.com>
Cc: "dri-devel@lists.freedesktop.org"
<dri-devel@lists.freedesktop.org>,
"intel-gfx@lists.freedesktop.org"
<intel-gfx@lists.freedesktop.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"airlied@linux.ie" <airlied@linux.ie>
Subject: Re: [Intel-gfx] [PATCH v5 04/10] drm/dp_mst: Remove all evil duplicate state pointers
Date: Mon, 2 Apr 2018 23:23:45 +0000 [thread overview]
Message-ID: <1522712898.10101.49.camel@dk-H97M-D3H> (raw)
In-Reply-To: <20180402224800.16080-5-lyude@redhat.com>
On Mon, 2018-04-02 at 18:47 -0400, Lyude Paul wrote:
> There's no reason to track the atomic state three times. Unfortunately,
> this is currently what we're doing, and even worse is that there is only
> one actually correct state pointer: the one in mst_state->base.state.
> mgr->state never seems to be used, along with the one in
> mst_state->state.
>
Looks like the redundancy got introduced when struct drm_private_state
was added.
Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
> This confused me for over 4 hours until I realized there was no magic
> behind these pointers. So, let's save everyone else from the trouble.
>
> Signed-off-by: Lyude Paul <lyude@redhat.com>.
> Cc: Manasi Navare <manasi.d.navare@intel.com>
> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
> Signed-off-by: Lyude Paul <lyude@redhat.com>
> ---
> include/drm/drm_dp_mst_helper.h | 6 ------
> 1 file changed, 6 deletions(-)
>
> diff --git a/include/drm/drm_dp_mst_helper.h b/include/drm/drm_dp_mst_helper.h
> index 41a8f08da05d..035963fbcd9d 100644
> --- a/include/drm/drm_dp_mst_helper.h
> +++ b/include/drm/drm_dp_mst_helper.h
> @@ -409,7 +409,6 @@ struct drm_dp_payload {
> struct drm_dp_mst_topology_state {
> struct drm_private_state base;
> int avail_slots;
> - struct drm_atomic_state *state;
> struct drm_dp_mst_topology_mgr *mgr;
> };
>
> @@ -497,11 +496,6 @@ struct drm_dp_mst_topology_mgr {
> */
> int pbn_div;
>
> - /**
> - * @state: State information for topology manager
> - */
> - struct drm_dp_mst_topology_state *state;
> -
> /**
> * @funcs: Atomic helper callbacks
> */
next prev parent reply other threads:[~2018-04-02 23:23 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-04-02 22:47 [PATCH v5 00/10] Implement proper MST fallback retraining in i915 Lyude Paul
2018-04-02 22:47 ` [PATCH v5 01/10] drm/atomic: Print debug message on atomic check failure Lyude Paul
2018-04-02 22:47 ` [PATCH v5 02/10] drm/i915: Move DP modeset retry work into intel_dp Lyude Paul
2018-04-02 22:47 ` [PATCH v5 03/10] drm/dp_mst: Fix naming on drm_atomic_get_mst_topology_state() Lyude Paul
2018-04-02 22:47 ` [PATCH v5 04/10] drm/dp_mst: Remove all evil duplicate state pointers Lyude Paul
2018-04-02 23:23 ` Pandiyan, Dhinakaran [this message]
2018-04-02 22:47 ` [PATCH v5 05/10] drm/dp_mst: Make drm_dp_mst_topology_state subclassable Lyude Paul
2018-04-02 22:47 ` [PATCH v5 06/10] drm/dp_mst: Add reset_state callback to topology mgr Lyude Paul
2018-04-02 22:47 ` [PATCH v5 07/10] drm/i915: Only use one link bw config for MST topologies Lyude Paul
2018-04-02 22:47 ` [PATCH v5 08/10] drm/i915: Make intel_dp_mst_atomic_check() idempotent Lyude Paul
2018-04-02 22:47 ` [PATCH v5 09/10] drm/dp_mst: Add MST fallback retraining helpers Lyude Paul
2018-04-02 22:47 ` [PATCH v5 10/10] drm/i915: Implement proper fallback training for MST Lyude Paul
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=1522712898.10101.49.camel@dk-H97M-D3H \
--to=dhinakaran.pandiyan@intel.com \
--cc=airlied@linux.ie \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lyude@redhat.com \
/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
all inboxes | Powered by JetHome®