From: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
To: Jacopo Mondi <jacopo+renesas@jmondi.org>,
Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>,
David Airlie <airlied@linux.ie>, Daniel Vetter <daniel@ffwll.ch>
Cc: "open list:DRM DRIVERS FOR RENESAS"
<dri-devel@lists.freedesktop.org>,
"open list:DRM DRIVERS FOR RENESAS"
<linux-renesas-soc@vger.kernel.org>,
open list <linux-kernel@vger.kernel.org>
Subject: RE: [PATCH] drm: rcar_lvds: Fix dual link mode operations
Date: Wed, 24 Jul 2019 08:10:22 +0000 [thread overview]
Message-ID: <TY1PR01MB1770980628C5914BC796C47FC0C60@TY1PR01MB1770.jpnprd01.prod.outlook.com> (raw)
In-Reply-To: <20190723165700.13124-1-jacopo+renesas@jmondi.org>
Hi Jacopo,
Thank you for your patch!
> From: linux-renesas-soc-owner@vger.kernel.org <linux-renesas-soc-owner@vger.kernel.org> On Behalf Of Jacopo Mondi
> Sent: 23 July 2019 17:57
> Subject: [PATCH] drm: rcar_lvds: Fix dual link mode operations
>
> The R-Car LVDS encoder units support dual-link operations by splitting
> the pixel output between the primary encoder and the companion one.
>
> In order for the primary encoder to succesfully control the companion's
> operations this should not fail at probe time and register itself its
> associated drm bridge so that the primary one can find it.
>
> Currently the companion encoder fails at probe time, causing the
> registration of the primary to fail preventing the whole DU unit to be
> registered correctly.
>
> Fixes: fa440d870358 ("drm: rcar-du: lvds: Add support for dual-link mode")
> Reported-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
> Signed-off-by: Jacopo Mondi <jacopo+renesas@jmondi.org>
Reviewed-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
Tested-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
>
> ---
> The "Fixes" tag refers to a patch currently part of the
> renesas-drivers-2019-07-09-v5.2 branch of Geert's renesas-drivers tree.
>
> drivers/gpu/drm/rcar-du/rcar_lvds.c | 31 +++++++++++++++++++++--------
> 1 file changed, 23 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/gpu/drm/rcar-du/rcar_lvds.c b/drivers/gpu/drm/rcar-du/rcar_lvds.c
> index bada7ee98544..8b015ba95895 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_lvds.c
> +++ b/drivers/gpu/drm/rcar-du/rcar_lvds.c
> @@ -767,14 +767,29 @@ static int rcar_lvds_parse_dt(struct rcar_lvds *lvds)
> of_node_put(remote_input);
> of_node_put(remote);
>
> - /*
> - * On D3/E3 the LVDS encoder provides a clock to the DU, which can be
> - * used for the DPAD output even when the LVDS output is not connected.
> - * Don't fail probe in that case as the DU will need the bridge to
> - * control the clock.
> - */
> - if (lvds->info->quirks & RCAR_LVDS_QUIRK_EXT_PLL)
> - return ret == -ENODEV ? 0 : ret;
> + switch (ret) {
> + case -ENODEV:
> + /*
> + * On D3/E3 the LVDS encoder provides a clock to the DU, which
> + * can be used for the DPAD output even when the LVDS output is
> + * not connected. Don't fail probe in that case as the DU will
> + * need the bridge to control the clock.
> + */
> + if (lvds->info->quirks & RCAR_LVDS_QUIRK_EXT_PLL)
> + ret = 0;
> + break;
> + case -ENXIO:
> + /*
> + * When the LVDS output is used in dual link mode, the
> + * companion encoder fails at
> + * 'rcar_lvds_parse_dt_companion()'. Don't fail probe in
> + * that case as the master encoder will need the companion's
> + * bridge to control its operations.
> + */
> + if (lvds->info->quirks & RCAR_LVDS_QUIRK_DUAL_LINK)
> + ret = 0;
> + break;
> + }
>
> return ret;
> }
> --
> 2.22.0
next prev parent reply other threads:[~2019-07-24 8:10 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-23 16:57 [PATCH] drm: rcar_lvds: Fix dual link mode operations Jacopo Mondi
2019-07-24 7:28 ` Geert Uytterhoeven
2019-07-24 8:37 ` Jacopo Mondi
2019-07-24 8:10 ` Fabrizio Castro [this message]
2019-08-01 15:11 ` Laurent Pinchart
2019-08-05 7:51 ` Jacopo Mondi
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=TY1PR01MB1770980628C5914BC796C47FC0C60@TY1PR01MB1770.jpnprd01.prod.outlook.com \
--to=fabrizio.castro@bp.renesas.com \
--cc=airlied@linux.ie \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=jacopo+renesas@jmondi.org \
--cc=kieran.bingham+renesas@ideasonboard.com \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-renesas-soc@vger.kernel.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).