From: Dan Murphy <dmurphy@ti.com>
To: <lgirdwood@gmail.com>, <broonie@kernel.org>, <tiwai@suse.com>,
<robh+dt@kernel.org>
Cc: <devicetree@vger.kernel.org>, <camel.guo@axis.com>,
<alsa-devel@alsa-project.org>, <linux-kernel@vger.kernel.org>,
Dan Murphy <dmurphy@ti.com>
Subject: [PATCH 4/6] ASoC: tlv320adcx140: Add the config to configure Tx ASI output
Date: Tue, 15 Sep 2020 14:06:04 -0500 [thread overview]
Message-ID: <20200915190606.1744-4-dmurphy@ti.com> (raw)
In-Reply-To: <20200915190606.1744-1-dmurphy@ti.com>
Add code to allow the ASI Tx output to be placed into High-z mode
during unused ASI cycles. This allows for other devices that may be on
the bus to drive the ASI out. By default the 320adcx140 sends 0's for
unused cycles.
Signed-off-by: Dan Murphy <dmurphy@ti.com>
---
sound/soc/codecs/tlv320adcx140.c | 11 +++++++++++
sound/soc/codecs/tlv320adcx140.h | 1 +
2 files changed, 12 insertions(+)
diff --git a/sound/soc/codecs/tlv320adcx140.c b/sound/soc/codecs/tlv320adcx140.c
index 73d18e8002e4..7fa5c8682c51 100644
--- a/sound/soc/codecs/tlv320adcx140.c
+++ b/sound/soc/codecs/tlv320adcx140.c
@@ -839,6 +839,7 @@ static int adcx140_codec_probe(struct snd_soc_component *component)
u32 gpi_input_val = 0;
int i;
int ret;
+ bool tx_high_z;
ret = device_property_read_u32(adcx140->dev, "ti,mic-bias-source",
&bias_source);
@@ -930,6 +931,16 @@ static int adcx140_codec_probe(struct snd_soc_component *component)
if (ret)
dev_err(adcx140->dev, "setting MIC bias failed %d\n", ret);
+ tx_high_z = device_property_read_bool(adcx140->dev, "ti,asi-tx-drive");
+ if (tx_high_z) {
+ ret = regmap_update_bits(adcx140->regmap, ADCX140_ASI_CFG0,
+ ADCX140_TX_FILL, ADCX140_TX_FILL);
+ if (ret) {
+ dev_err(adcx140->dev, "Setting Tx drive failed %d\n", ret);
+ goto out;
+ }
+ }
+
adcx140_pwr_ctrl(adcx140, true);
out:
return ret;
diff --git a/sound/soc/codecs/tlv320adcx140.h b/sound/soc/codecs/tlv320adcx140.h
index 94c6d1fd2977..107bd7927d9c 100644
--- a/sound/soc/codecs/tlv320adcx140.h
+++ b/sound/soc/codecs/tlv320adcx140.h
@@ -146,5 +146,6 @@
#define ADCX140_GPO_CFG_MAX 4
#define ADCX140_GPO_DRV_MAX 5
+#define ADCX140_TX_FILL BIT(0)
#endif /* _TLV320ADCX140_ */
--
2.28.0
next prev parent reply other threads:[~2020-09-15 19:09 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-15 19:06 [PATCH 1/6] ASoC: tlv320adcx140: Idle the device while writing registers Dan Murphy
2020-09-15 19:06 ` [PATCH 2/6] ASoC: tlv320adcx140: Fix BCLK inversion for DSP modes Dan Murphy
2020-09-15 19:06 ` [PATCH 3/6] dt-bindings: tlv320adcx140: Add ASI Tx drive Dan Murphy
2020-09-15 19:06 ` Dan Murphy [this message]
2020-09-15 19:06 ` [PATCH 5/6] dt-bindings: tlv320adcx140: Add slot programming property Dan Murphy
2020-09-17 13:02 ` Mark Brown
2020-09-17 15:15 ` Dan Murphy
2020-09-17 15:56 ` Mark Brown
2020-09-15 19:06 ` [PATCH 6/6] ASoC: tlv320adcx140: Add channel slot programming Dan Murphy
2020-09-17 18:57 ` [PATCH 1/6] ASoC: tlv320adcx140: Idle the device while writing registers Mark Brown
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=20200915190606.1744-4-dmurphy@ti.com \
--to=dmurphy@ti.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=camel.guo@axis.com \
--cc=devicetree@vger.kernel.org \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=robh+dt@kernel.org \
--cc=tiwai@suse.com \
/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).