From: Bogdan Togorean <bogdan.togorean@analog.com>
To: <a.hajda@samsung.com>
Cc: <Laurent.pinchart@ideasonboard.com>, <airlied@linux.ie>,
<daniel@ffwll.ch>, <sam@ravnborg.org>, <swinslow@gmail.com>,
<benjamin.gaignard@linaro.org>, <bogdan.togorean@analog.com>,
<tglx@linutronix.de>, <matt.redfearn@thinci.com>,
<dri-devel@lists.freedesktop.org>, <linux-kernel@vger.kernel.org>
Subject: [PATCH] drm: adv7511: Fix low refresh rate register for ADV7533/5
Date: Tue, 16 Jul 2019 16:10:05 +0300 [thread overview]
Message-ID: <20190716131005.761-1-bogdan.togorean@analog.com> (raw)
For ADV7533 and ADV7535 low refresh rate is selected using
bits [3:2] of 0x4a main register.
So depending on ADV model write 0xfb or 0x4a register.
Fixes: 9c8af882bf12: ("drm: Add adv7511 encoder driver")
Signed-off-by: Bogdan Togorean <bogdan.togorean@analog.com>
---
drivers/gpu/drm/bridge/adv7511/adv7511_drv.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/bridge/adv7511/adv7511_drv.c b/drivers/gpu/drm/bridge/adv7511/adv7511_drv.c
index f6d2681f6927..4508a304d23f 100644
--- a/drivers/gpu/drm/bridge/adv7511/adv7511_drv.c
+++ b/drivers/gpu/drm/bridge/adv7511/adv7511_drv.c
@@ -756,8 +756,13 @@ static void adv7511_mode_set(struct adv7511 *adv7511,
else
low_refresh_rate = ADV7511_LOW_REFRESH_RATE_NONE;
- regmap_update_bits(adv7511->regmap, 0xfb,
- 0x6, low_refresh_rate << 1);
+ if (adv7511->type == ADV7511)
+ regmap_update_bits(adv7511->regmap, 0xfb,
+ 0x6, low_refresh_rate << 1);
+ else
+ regmap_update_bits(adv7511->regmap, 0x4a,
+ 0xc, low_refresh_rate << 2);
+
regmap_update_bits(adv7511->regmap, 0x17,
0x60, (vsync_polarity << 6) | (hsync_polarity << 5));
--
2.22.0
next reply other threads:[~2019-07-16 13:12 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-16 13:10 Bogdan Togorean [this message]
2023-07-18 6:28 ` [PATCH V2] drm: adv7511: Fix low refresh rate register for ADV7533/5 Alexandru Ardelean
2023-07-18 7:03 ` Nuno Sá
2023-07-18 8:35 ` Alexandru Ardelean
2023-07-18 8:42 ` [PATCH v3] " Alexandru Ardelean
2023-07-18 8:49 ` Robert Foss
2023-07-18 11:45 ` Alexandru Ardelean
2023-07-18 12:21 ` Nuno Sá
2023-07-19 6:01 ` [PATCH v4] " Alexandru Ardelean
2023-07-20 7:30 ` Alexandru Ardelean
2023-07-20 7:44 ` Frieder Schrempf
2023-07-21 11:48 ` Robert Foss
2023-05-16 16:44 [PATCH] " Alexandru Ardelean
2023-07-13 20:08 ` Alexandru Ardelean
2023-07-13 20:19 ` Fabio Estevam
2023-07-14 7:51 ` Nuno Sá
2023-07-18 6:17 ` Alexandru Ardelean
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=20190716131005.761-1-bogdan.togorean@analog.com \
--to=bogdan.togorean@analog.com \
--cc=Laurent.pinchart@ideasonboard.com \
--cc=a.hajda@samsung.com \
--cc=airlied@linux.ie \
--cc=benjamin.gaignard@linaro.org \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-kernel@vger.kernel.org \
--cc=matt.redfearn@thinci.com \
--cc=sam@ravnborg.org \
--cc=swinslow@gmail.com \
--cc=tglx@linutronix.de \
/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).