devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rob Clark <robdclark@gmail.com>
To: Chandan Uddaraju <chandanu@codeaurora.org>
Cc: freedreno <freedreno@lists.freedesktop.org>,
	linux-arm-msm <linux-arm-msm@vger.kernel.org>,
	"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" 
	<devicetree@vger.kernel.org>, Sean Paul <seanpaul@chromium.org>,
	Abhinav Kumar <abhinavk@codeaurora.org>,
	nganji@codeaurora.org, Jeykumar Sankaran <jsanka@codeaurora.org>,
	"Kristian H. Kristensen" <hoegsberg@google.com>,
	dri-devel <dri-devel@lists.freedesktop.org>
Subject: Re: [DPU PATCH v3 3/5] drm/msm/dp: add displayPort driver support
Date: Mon, 2 Dec 2019 08:48:58 -0800	[thread overview]
Message-ID: <CAF6AEGtHkPSx8xU+CdomDtOqLr-cC2bgfHngWWZzx=8STAsQtA@mail.gmail.com> (raw)
In-Reply-To: <0101016ec6df0d33-edb8acfc-a6f1-486e-a8db-38ec498951ed-000000@us-west-2.amazonses.com>

On Mon, Dec 2, 2019 at 5:48 AM Chandan Uddaraju <chandanu@codeaurora.org> wrote:
>
> Add the needed displayPort files to enable DP driver
> on msm target.
>
> "dp_display" module is the main module that calls into
> other sub-modules. "dp_drm" file represents the interface
> between DRM framework and DP driver.
>
> changes in v2:
> -- Update copyright markings on all relevant files.
> -- Change pr_err() to DRM_ERROR()
> -- Use APIs directly instead of function pointers.
> -- Use drm_display_mode structure to store link parameters in the driver.
> -- Use macros for register definitions instead of hardcoded values.
> -- Replace writel_relaxed/readl_relaxed with writel/readl
>    and remove memory barriers.
> -- Remove unnecessary NULL checks.
> -- Use drm helper functions for dpcd read/write.
> -- Use DRM_DEBUG_DP for debug msgs.
>
> changes in V3:
> -- Removed changes in dpu_io_util.[ch]
> -- Added locking around "is_connected" flag and removed atomic_set()
> -- Removed the argument validation checks in all the static functions
>    except initialization functions and few API calls across msm/dp files
> -- Removed hardcoded values for register reads/writes
> -- Removed vreg related generic structures.
> -- Added return values where ever necessary.
> -- Updated dp_ctrl_on function.
> -- Calling the ctrl specific catalog functions directly instead of
>    function pointers.
> -- Added seperate change that adds standard value in drm_dp_helper file.
> -- Added separate change in this list that is used to initialize
>    displayport in DPU driver.
> -- Added change to use drm_dp_get_adjust_request_voltage() function.
>
> Signed-off-by: Chandan Uddaraju <chandanu@codeaurora.org>
> ---

[snip]

> diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c
> index f96e142..29ac7d3 100644
> --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c
> +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c
> @@ -967,6 +967,9 @@ static void dpu_encoder_virt_mode_set(struct drm_encoder *drm_enc,
>
>         trace_dpu_enc_mode_set(DRMID(drm_enc));
>
> +       if (drm_enc->encoder_type == DRM_MODE_ENCODER_TMDS && priv->dp)
> +               msm_dp_display_mode_set(priv->dp, drm_enc, mode, adj_mode);
> +

for better or for worse, DSI and HDMI backends create an internal
drm_bridge object to avoid all of these shunts over from the encoder.
We might be still the only driver to do this, but IMHO it is better
than making each encoder know about each backend, so we might as well
stick with that.

(same goes for the other 'if (drm_enc->encoder_type == DRM_MODE_ENCODER_TMDS)'s)

BR,
-R


>         list_for_each_entry(conn_iter, connector_list, head)
>                 if (conn_iter->encoder == drm_enc)
>                         conn = conn_iter;

  parent reply	other threads:[~2019-12-02 16:49 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1575294437-6129-1-git-send-email-chandanu@codeaurora.org>
2019-12-02 13:47 ` [DPU PATCH v3 2/5] drm: add constant N value in helper file Chandan Uddaraju
2019-12-02 13:47 ` [DPU PATCH v3 1/5] dt-bindings: msm/dp: add bindings of DP/DP-PLL driver for Snapdragon 845 Chandan Uddaraju
2019-12-13 22:58   ` Rob Herring
2019-12-13 23:04   ` Jeffrey Hugo
2019-12-02 13:48 ` [DPU PATCH v3 3/5] drm/msm/dp: add displayPort driver support Chandan Uddaraju
2019-12-02 13:48 ` [DPU PATCH v3 5/5] drm/msm/dpu: add display port support in DPU Chandan Uddaraju
2019-12-02 13:48 ` [DPU PATCH v3 4/5] drm/msm/dp: add support for DP PLL driver Chandan Uddaraju
     [not found] ` <0101016ec6ddf2ce-8548e076-2347-49be-a9be-4d81a14ad8f7-000000@us-west-2.amazonses.com>
2019-12-02 14:13   ` [DPU PATCH v3 2/5] drm: add constant N value in helper file Jani Nikula
     [not found] ` <0101016ec6df0d33-edb8acfc-a6f1-486e-a8db-38ec498951ed-000000@us-west-2.amazonses.com>
2019-12-02 16:48   ` Rob Clark [this message]
     [not found]     ` <3130b7844837a8caaa10f9f4f5633eab@codeaurora.org>
2020-02-14  0:37       ` Re: [DPU PATCH v3 3/5] drm/msm/dp: add displayPort driver support chandanu
2019-12-02 18:59   ` Rob Clark
     [not found] ` <0101016ec6de9b5b-cd61a0a2-9ae4-4ca1-a3a4-0ad2e8783e20-000000@us-west-2.amazonses.com>
2020-02-27 23:41   ` [DPU PATCH v3 4/5] drm/msm/dp: add support for DP PLL driver Matthias Kaehlcke
     [not found] ` <0101016ec6df0e54-2af1f4a6-8f72-4799-89e0-0ff87b514eb2-000000@us-west-2.amazonses.com>
2020-02-27 21:54   ` [DPU PATCH v3 3/5] drm/msm/dp: add displayPort driver support Matthias Kaehlcke
2020-02-28  0:43     ` Matthias Kaehlcke
2020-02-28 21:49   ` Matthias Kaehlcke
     [not found]     ` <fe3f72c14d570d805996a889944fae35@codeaurora.org>
     [not found]       ` <BYAPR02MB5288D92EF7422BF5C86FC45BA9E70@BYAPR02MB5288.namprd02.prod.outlook.com>
2020-03-02 23:47         ` FW: " varar
2020-03-03 20:24           ` Matthias Kaehlcke

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='CAF6AEGtHkPSx8xU+CdomDtOqLr-cC2bgfHngWWZzx=8STAsQtA@mail.gmail.com' \
    --to=robdclark@gmail.com \
    --cc=abhinavk@codeaurora.org \
    --cc=chandanu@codeaurora.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=freedreno@lists.freedesktop.org \
    --cc=hoegsberg@google.com \
    --cc=jsanka@codeaurora.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=nganji@codeaurora.org \
    --cc=seanpaul@chromium.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).