All of lore.kernel.org
 help / color / mirror / Atom feed
From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>,
	Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>,
	Kieran Bingham <kbingham@kernel.org>,
	Simon Horman <horms@verge.net.au>,
	Linux-Renesas <linux-renesas-soc@vger.kernel.org>
Subject: Re: vsps and channel indices (was: Re: [PATCH v3 1/2] arm64: dts: renesas: r8a77980: add FCPVD/VSPD/DU/LVDS support)
Date: Wed, 29 Aug 2018 12:12:19 +0300	[thread overview]
Message-ID: <1722619.RLsez26Y98@avalon> (raw)
In-Reply-To: <CAMuHMdVqGBo4uXtzNeLyD4f3CKeQzmgdJNs4N2ZB7MDosU+t4w@mail.gmail.com>

Hi Geert,

On Tuesday, 28 August 2018 15:10:52 EEST Geert Uytterhoeven wrote:
> Hi Sergei, Laurent, Kieran,
> 
> On Wed, Jun 13, 2018 at 10:11 PM Sergei Shtylyov wrote:
> > Describe the interconnected FCPVD0, VSPD0, DU, and LVDS0 devices in the
> > R8A77980 device tree...
> > 
> > Based on the original (and large) patch by Vladimir Barinov.
> > 
> > Signed-off-by: Vladimir Barinov <vladimir.barinov@cogentembedded.com>
> > Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
> > Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > 
> > --- renesas.orig/arch/arm64/boot/dts/renesas/r8a77980.dtsi
> > +++ renesas/arch/arm64/boot/dts/renesas/r8a77980.dtsi
> > 
> > +               du: display@feb00000 {
> > +                       compatible = "renesas,du-r8a77980",
> > +                                    "renesas,du-r8a77970";
> > +                       reg = <0 0xfeb00000 0 0x80000>;
> > +                       interrupts = <GIC_SPI 256 IRQ_TYPE_LEVEL_HIGH>;
> > +                       clocks = <&cpg CPG_MOD 724>;
> > +                       clock-names = "du.0";
> > +                       power-domains = <&sysc R8A77980_PD_ALWAYS_ON>;
> > +                       resets = <&cpg 724>;
> > +                       vsps = <&vspd0>;
> 
> According to the bindings, the vsps property should also contain a
> channel index.
> 
> Laurent added the indices to r8a7795.dtsi, but r8a7795-es.dtsi overrides
> that with a version without the indices.
> Kieran included the indices when adding DU support for r8a77965 and
> r8a77995.
> 
> r8a7796.dtsi, r8a77970.dtsi, and r8a77980.dtsi lack the indices.
> 
> Commit fd57d77f9c649cf9 ("dt-bindings: display: rcar-du: Add a VSP channel
> index to the vsps DT property") says a backwards-compatibility mode can be
> implemented, but I fail to see how this can work, as rcar_du_vsps_init()
> will just return an error, which is propagated.
> 
> What am I missing?

We're missing a DT validator :-/

The vsps property shoould indeed contain indices. However, rcar_du_vsps_init() 
implements a backward-compatibility mode by checking the length of the 
property:

	cells = of_property_count_u32_elems(np, "vsps") / rcdu->num_crtcs - 1;

and using that as an argument to of_parse_phandle_with_fixed_args().

-- 
Regards,

Laurent Pinchart

  reply	other threads:[~2018-08-29 13:08 UTC|newest]

Thread overview: 48+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-13 20:09 [PATCH v3 0/2] Add R8A77980/Condor/V3HSK LVDS/HDMI support Sergei Shtylyov
2018-06-13 20:09 ` Sergei Shtylyov
2018-06-13 20:09 ` Sergei Shtylyov
2018-06-13 20:11 ` [PATCH v3 1/2] arm64: dts: renesas: r8a77980: add FCPVD/VSPD/DU/LVDS support Sergei Shtylyov
2018-06-13 20:11   ` Sergei Shtylyov
2018-06-13 20:11   ` Sergei Shtylyov
2018-06-14  7:23   ` Simon Horman
2018-06-14  7:23     ` Simon Horman
2018-06-14  7:23     ` Simon Horman
2018-08-28 12:10   ` vsps and channel indices (was: Re: [PATCH v3 1/2] arm64: dts: renesas: r8a77980: add FCPVD/VSPD/DU/LVDS support) Geert Uytterhoeven
2018-08-29  9:12     ` Laurent Pinchart [this message]
2018-08-30  8:03       ` Geert Uytterhoeven
2018-06-13 20:12 ` [PATCH v3 2/2] arm64: dts: renesas: condor/v3hsk: add DU/LVDS/HDMI support Sergei Shtylyov
2018-06-13 20:12   ` Sergei Shtylyov
2018-06-13 20:12   ` Sergei Shtylyov
2018-06-14  7:24   ` Simon Horman
2018-06-14  7:24     ` Simon Horman
2018-06-14  7:24     ` Simon Horman
2018-07-16  7:53     ` Simon Horman
2018-07-16  7:53       ` Simon Horman
2018-07-16  7:53       ` Simon Horman
2018-07-16  9:16       ` Ulrich Hecht
2018-07-16  9:16         ` Ulrich Hecht
2018-07-16  9:16         ` Ulrich Hecht
2018-08-13 11:14     ` Sergei Shtylyov
2018-08-13 11:14       ` Sergei Shtylyov
2018-08-13 11:14       ` Sergei Shtylyov
2018-08-13 15:19   ` Laurent Pinchart
2018-08-13 15:19     ` Laurent Pinchart
2018-08-13 15:19     ` Laurent Pinchart
2018-08-22  9:55     ` Simon Horman
2018-08-22  9:55       ` Simon Horman
2018-08-22  9:55       ` Simon Horman
2018-08-23 16:10       ` Sergei Shtylyov
2018-08-23 16:10         ` Sergei Shtylyov
2018-08-23 16:10         ` Sergei Shtylyov
2018-08-22 19:27     ` Sergei Shtylyov
2018-08-22 19:27       ` Sergei Shtylyov
2018-08-22 19:27       ` Sergei Shtylyov
2018-06-13 20:24 ` [PATCH v3 0/2] Add R8A77980/Condor/V3HSK LVDS/HDMI support Sergei Shtylyov
2018-06-13 20:24   ` Sergei Shtylyov
2018-06-13 20:24   ` Sergei Shtylyov
2018-08-23 16:59 ` [PATCH v4] arm64: dts: renesas: condor/v3hsk: add DU/LVDS/HDMI support Sergei Shtylyov
2018-08-23 16:59   ` Sergei Shtylyov
2018-08-23 16:59   ` Sergei Shtylyov
2018-08-27 12:35   ` Simon Horman
2018-08-27 12:35     ` Simon Horman
2018-08-27 12:35     ` Simon Horman

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=1722619.RLsez26Y98@avalon \
    --to=laurent.pinchart@ideasonboard.com \
    --cc=geert@linux-m68k.org \
    --cc=horms@verge.net.au \
    --cc=kbingham@kernel.org \
    --cc=laurent.pinchart+renesas@ideasonboard.com \
    --cc=linux-renesas-soc@vger.kernel.org \
    --cc=sergei.shtylyov@cogentembedded.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.