From: Bogdan Togorean <bogdan.togorean@analog.com>
To: <dri-devel@lists.freedesktop.org>
Cc: <airlied@linux.ie>, <daniel@ffwll.ch>, <narmstrong@baylibre.com>,
<a.hajda@samsung.com>, <Laurent.pinchart@ideasonboard.com>,
<jonas@kwiboo.se>, <jernej.skrabec@siol.net>,
<tglx@linutronix.de>, <alexios.zavras@intel.com>,
<linux-kernel@vger.kernel.org>,
Bogdan Togorean <bogdan.togorean@analog.com>
Subject: [RESEND PATCH 2/2] drm: bridge: adv7511: Extend list of audio sample rates
Date: Tue, 29 Oct 2019 10:30:37 +0200 [thread overview]
Message-ID: <20191029083035.21310-2-bogdan.togorean@analog.com> (raw)
In-Reply-To: <20191029083035.21310-1-bogdan.togorean@analog.com>
ADV7511 support sample rates up to 192kHz. CTS and N parameters should
be computed accordingly so this commit extend the list up to maximum
supported sample rate.
Signed-off-by: Bogdan Togorean <bogdan.togorean@analog.com>
---
drivers/gpu/drm/bridge/adv7511/adv7511_audio.c | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/drivers/gpu/drm/bridge/adv7511/adv7511_audio.c b/drivers/gpu/drm/bridge/adv7511/adv7511_audio.c
index 1e9b128d229b..13e8cee6e827 100644
--- a/drivers/gpu/drm/bridge/adv7511/adv7511_audio.c
+++ b/drivers/gpu/drm/bridge/adv7511/adv7511_audio.c
@@ -27,6 +27,18 @@ static void adv7511_calc_cts_n(unsigned int f_tmds, unsigned int fs,
case 48000:
*n = 6144;
break;
+ case 88200:
+ *n = 12544;
+ break;
+ case 96000:
+ *n = 12288;
+ break;
+ case 176400:
+ *n = 25088;
+ break;
+ case 192000:
+ *n = 24576;
+ break;
}
*cts = ((f_tmds * *n) / (128 * fs)) * 1000;
--
2.23.0
next prev parent reply other threads:[~2019-10-29 8:32 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-29 8:30 [RESEND PATCH 1/2] drm: bridge: adv7511: Enable SPDIF DAI Bogdan Togorean
2019-10-29 8:30 ` Bogdan Togorean [this message]
2019-11-12 13:34 Bogdan Togorean
2019-11-12 13:34 ` [RESEND PATCH 2/2] drm: bridge: adv7511: Extend list of audio sample rates Bogdan Togorean
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=20191029083035.21310-2-bogdan.togorean@analog.com \
--to=bogdan.togorean@analog.com \
--cc=Laurent.pinchart@ideasonboard.com \
--cc=a.hajda@samsung.com \
--cc=airlied@linux.ie \
--cc=alexios.zavras@intel.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=jernej.skrabec@siol.net \
--cc=jonas@kwiboo.se \
--cc=linux-kernel@vger.kernel.org \
--cc=narmstrong@baylibre.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).