From: Francesco Dolcini <francesco@dolcini.it>
To: Andrzej Hajda <andrzej.hajda@intel.com>,
Neil Armstrong <neil.armstrong@linaro.org>,
Robert Foss <rfoss@kernel.org>,
Laurent Pinchart <Laurent.pinchart@ideasonboard.com>,
Jonas Karlman <jonas@kwiboo.se>,
Jernej Skrabec <jernej.skrabec@gmail.com>,
dri-devel@lists.freedesktop.org
Cc: Francesco Dolcini <francesco.dolcini@toradex.com>,
David Airlie <airlied@gmail.com>, Daniel Vetter <daniel@ffwll.ch>,
linux-kernel@vger.kernel.org
Subject: [PATCH v1 5/6] drm/bridge: tc358768: Add parallel data format cfg
Date: Thu, 30 Mar 2023 11:59:40 +0200 [thread overview]
Message-ID: <20230330095941.428122-6-francesco@dolcini.it> (raw)
In-Reply-To: <20230330095941.428122-1-francesco@dolcini.it>
From: Francesco Dolcini <francesco.dolcini@toradex.com>
Add configuration for parallel data format register, tc358768 supports
different mapping on the parallel input RGB interface, enable the
configuration for it.
Valid values, and the related meaning, are:
0 = R[7:0], G[7:0], B[7:0]
1 = R[1:0], G[1:0], B[1:0], R[7:2], G[7:2], B[7:2]
2 = 8’b0, R[4:0], G[5:0], B[4:0]
Use 0 by default, consistently with the HW default.
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
---
drivers/gpu/drm/bridge/tc358768.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/drivers/gpu/drm/bridge/tc358768.c b/drivers/gpu/drm/bridge/tc358768.c
index f4499ae7bee6..4462264274af 100644
--- a/drivers/gpu/drm/bridge/tc358768.c
+++ b/drivers/gpu/drm/bridge/tc358768.c
@@ -854,6 +854,11 @@ static void tc358768_bridge_pre_enable(struct drm_bridge *bridge)
if (mode->flags & DRM_MODE_FLAG_PHSYNC)
tc358768_update_bits(priv, TC358768_PP_MISC, BIT(0), BIT(0));
+ /* PDataF: Parallel Data Format */
+ val = 0;
+ of_property_read_u32(bridge->of_node, "toshiba,input-rgb-mode", &val);
+ tc358768_update_bits(priv, TC358768_CONFCTL, BIT(8) | BIT(9), val << 8);
+
/* Start DSI Tx */
tc358768_write(priv, TC358768_DSI_START, 0x1);
--
2.25.1
next prev parent reply other threads:[~2023-03-30 10:00 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-30 9:59 [PATCH v1 0/6] drm/bridge: tc358768: Improve parallel RGB input configuration Francesco Dolcini
2023-03-30 9:59 ` [PATCH v1 1/6] dt-bindings: display: bridge: toshiba,tc358768: Fix typo Francesco Dolcini
2023-03-31 8:41 ` Krzysztof Kozlowski
2023-03-30 9:59 ` [PATCH v1 2/6] dt-bindings: display: bridge: toshiba,tc358768: Add TC9594 Francesco Dolcini
2023-03-31 8:42 ` Krzysztof Kozlowski
2023-03-31 9:30 ` Francesco Dolcini
2023-03-31 9:33 ` Krzysztof Kozlowski
2023-03-30 9:59 ` [PATCH v1 3/6] dt-bindings: display: bridge: toshiba,tc358768: add parallel input mode Francesco Dolcini
2023-03-31 8:48 ` Krzysztof Kozlowski
2023-03-31 9:40 ` Francesco Dolcini
2023-04-03 21:01 ` Rob Herring
2023-04-03 21:10 ` Francesco Dolcini
2023-04-03 21:20 ` Francesco Dolcini
2023-04-14 8:42 ` Francesco Dolcini
2023-03-30 9:59 ` [PATCH v1 4/6] drm/bridge: tc358768: Add TC9594 Francesco Dolcini
2023-03-30 9:59 ` Francesco Dolcini [this message]
2023-03-30 9:59 ` [PATCH v1 6/6] drm/bridge: tc358768: Add atomic_get_input_bus_fmts() implementation Francesco Dolcini
2023-04-20 9:51 ` Francesco Dolcini
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=20230330095941.428122-6-francesco@dolcini.it \
--to=francesco@dolcini.it \
--cc=Laurent.pinchart@ideasonboard.com \
--cc=airlied@gmail.com \
--cc=andrzej.hajda@intel.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=francesco.dolcini@toradex.com \
--cc=jernej.skrabec@gmail.com \
--cc=jonas@kwiboo.se \
--cc=linux-kernel@vger.kernel.org \
--cc=neil.armstrong@linaro.org \
--cc=rfoss@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
all inboxes | Powered by JetHome®