public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Maxime Ripard <maxime@cerno.tech>
To: Kevin Tang <kevin3.tang@gmail.com>
Cc: maarten.lankhorst@linux.intel.com, sean@poorly.run,
	airlied@linux.ie, daniel@ffwll.ch, robh+dt@kernel.org,
	mark.rutland@arm.com, pony1.wu@gmail.com, orsonzhai@gmail.com,
	zhang.lyra@gmail.com, linux-kernel@vger.kernel.org,
	dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org
Subject: Re: [PATCH v7 6/6] drm/sprd: add Unisoc's drm mipi dsi&dphy driver
Date: Fri, 3 Dec 2021 11:38:41 +0100	[thread overview]
Message-ID: <20211203103841.vkl3sjsbaohsviou@houat> (raw)
In-Reply-To: <20211025093418.20545-7-kevin3.tang@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1184 bytes --]

On Mon, Oct 25, 2021 at 05:34:18PM +0800, Kevin Tang wrote:
> @@ -618,9 +619,25 @@ static void sprd_crtc_mode_set_nofb(struct drm_crtc *crtc)
>  {
>  	struct sprd_dpu *dpu = to_sprd_crtc(crtc);
>  	struct drm_display_mode *mode = &crtc->state->adjusted_mode;
> +	struct drm_encoder *encoder;
> +	struct mipi_dsi_device *slave;
> +	struct sprd_dsi *dsi;
>  
>  	drm_display_mode_to_videomode(mode, &dpu->ctx.vm);
>  
> +	drm_for_each_encoder(encoder, crtc->dev) {
> +		if (encoder->crtc != crtc)
> +			continue;

encoder->crtc is deprecated. You should be using
encoder->drm_for_each_encoder_mask, using the encoder_mask in
encoder->drm_crtc_state.

> +static int sprd_dsi_probe(struct platform_device *pdev)
> +{
> +	struct device *dev = &pdev->dev;
> +	struct sprd_dsi *dsi;
> +
> +	dsi = devm_kzalloc(dev, sizeof(*dsi), GFP_KERNEL);
> +	if (!dsi)
> +		return -ENOMEM;
> +
> +	dev_set_drvdata(dev, dsi);
> +
> +	dsi->host.ops = &sprd_dsi_host_ops;
> +	dsi->host.dev = dev;
> +	mipi_dsi_host_register(&dsi->host);
> +
> +	return component_add(&pdev->dev, &dsi_component_ops);

component_add must be run in the mipi_dsi_host.attach hook.

Maxime

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

  reply	other threads:[~2021-12-03 10:38 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-25  9:34 [PATCH v7 0/6] Add Unisoc's drm kms module Kevin Tang
2021-10-25  9:34 ` [PATCH v7 1/6] dt-bindings: display: add Unisoc's drm master bindings Kevin Tang
2021-10-25  9:34 ` [PATCH v7 2/6] drm/sprd: add Unisoc's drm kms master Kevin Tang
2021-11-26 14:03   ` Maarten Lankhorst
2021-12-03  8:47     ` Kevin Tang
2021-10-25  9:34 ` [PATCH v7 3/6] dt-bindings: display: add Unisoc's dpu bindings Kevin Tang
2021-10-25  9:34 ` [PATCH v7 4/6] drm/sprd: add Unisoc's drm display controller driver Kevin Tang
2021-12-03 10:27   ` Maxime Ripard
2021-10-25  9:34 ` [PATCH v7 5/6] dt-bindings: display: add Unisoc's mipi dsi controller bindings Kevin Tang
2021-10-25  9:34 ` [PATCH v7 6/6] drm/sprd: add Unisoc's drm mipi dsi&dphy driver Kevin Tang
2021-12-03 10:38   ` Maxime Ripard [this message]
2021-12-03 12:34     ` Kevin Tang
2021-12-03 14:37       ` Maxime Ripard

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=20211203103841.vkl3sjsbaohsviou@houat \
    --to=maxime@cerno.tech \
    --cc=airlied@linux.ie \
    --cc=daniel@ffwll.ch \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=kevin3.tang@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mark.rutland@arm.com \
    --cc=orsonzhai@gmail.com \
    --cc=pony1.wu@gmail.com \
    --cc=robh+dt@kernel.org \
    --cc=sean@poorly.run \
    --cc=zhang.lyra@gmail.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