[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1472514096-10915-5-git-send-email-john.stultz@linaro.org>
Date: Mon, 29 Aug 2016 16:41:36 -0700
From: John Stultz <john.stultz@...aro.org>
To: lkml <linux-kernel@...r.kernel.org>
Cc: Andy Green <andy.green@...aro.org>,
David Airlie <airlied@...ux.ie>,
Archit Taneja <architt@...eaurora.org>,
Laurent Pinchart <laurent.pinchart@...asonboard.com>,
Wolfram Sang <wsa+renesas@...g-engineering.com>,
Srinivas Kandagatla <srinivas.kandagatla@...aro.org>,
Ville Syrjälä
<ville.syrjala@...ux.intel.com>,
Boris Brezillon <boris.brezillon@...e-electrons.com>,
Andy Green <andy@...mcat.com>,
Dave Long <dave.long@...aro.org>,
Guodong Xu <guodong.xu@...aro.org>,
Zhangfei Gao <zhangfei.gao@...aro.org>,
Mark Brown <broonie@...nel.org>,
Lars-Peter Clausen <lars@...afoo.de>,
Jose Abreu <joabreu@...opsys.com>,
dri-devel@...ts.freedesktop.org,
John Stultz <john.stultz@...aro.org>
Subject: [PATCH 4/4 v2] drm/bridge: adv7511: Initialize audio packet on adv7533
From: Andy Green <andy.green@...aro.org>
Set the initial audio packet settings to allow the audio
driver to work.
Cc: David Airlie <airlied@...ux.ie>
Cc: Archit Taneja <architt@...eaurora.org>
Cc: Laurent Pinchart <laurent.pinchart@...asonboard.com>
Cc: Wolfram Sang <wsa+renesas@...g-engineering.com>
Cc: Srinivas Kandagatla <srinivas.kandagatla@...aro.org>
Cc: "Ville Syrjälä" <ville.syrjala@...ux.intel.com>
Cc: Boris Brezillon <boris.brezillon@...e-electrons.com>
Cc: Andy Green <andy@...mcat.com>
Cc: Dave Long <dave.long@...aro.org>
Cc: Guodong Xu <guodong.xu@...aro.org>
Cc: Zhangfei Gao <zhangfei.gao@...aro.org>
Cc: Mark Brown <broonie@...nel.org>
Cc: Lars-Peter Clausen <lars@...afoo.de>
Cc: Jose Abreu <joabreu@...opsys.com>
Cc: dri-devel@...ts.freedesktop.org
Signed-off-by: Andy Green <andy.green@...aro.org>
[jstultz: Forward ported to mainline, changed to use register
names rather then hex values, and removed config values set by
audio driver.]
Signed-off-by: John Stultz <john.stultz@...aro.org>
---
drivers/gpu/drm/bridge/adv7511/adv7533.c | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
diff --git a/drivers/gpu/drm/bridge/adv7511/adv7533.c b/drivers/gpu/drm/bridge/adv7511/adv7533.c
index 6798ecf..cced7c9 100644
--- a/drivers/gpu/drm/bridge/adv7511/adv7533.c
+++ b/drivers/gpu/drm/bridge/adv7511/adv7533.c
@@ -104,6 +104,28 @@ void adv7533_dsi_power_on(struct adv7511 *adv)
/* disable test mode */
regmap_write(adv->regmap_cec, 0x55, 0x00);
+ /* hide Audio infoframe updates */
+ regmap_update_bits(adv->regmap, ADV7511_REG_INFOFRAME_UPDATE,
+ BIT(5), BIT(5));
+ /* enable N/CTS, enable Audio sample packets */
+ regmap_update_bits(adv->regmap, ADV7511_REG_PACKET_ENABLE1,
+ BIT(5), BIT(5));
+ /* enable N/CTS */
+ regmap_update_bits(adv->regmap, ADV7511_REG_PACKET_ENABLE1,
+ BIT(6), BIT(6));
+ /* not copyrighted */
+ regmap_update_bits(adv->regmap, ADV7511_REG_AUDIO_CFG1,
+ BIT(5), BIT(5));
+ /* enable audio infoframes */
+ regmap_update_bits(adv->regmap, ADV7511_REG_PACKET_ENABLE1,
+ BIT(3), BIT(3));
+ /* AV mute disable */
+ regmap_update_bits(adv->regmap, ADV7511_REG_GC(0),
+ BIT(7) | BIT(6), BIT(7));
+ /* use Audio infoframe updated info */
+ regmap_update_bits(adv->regmap, ADV7511_REG_GC(1),
+ BIT(5), 0);
+
regmap_register_patch(adv->regmap_cec, adv7533_cec_fixed_registers,
ARRAY_SIZE(adv7533_cec_fixed_registers));
}
--
1.9.1
Powered by blists - more mailing lists