All of lore.kernel.org
 help / color / mirror / Atom feed
From: Angelo Dureghello <angelo.dureghello@timesys.com>
To: alsa-devel@alsa-project.org, broonie@kernel.org, lgirdwood@gmail.com
Cc: ricard.wanderlof@axis.com,
	Angelo Dureghello <angelo.dureghello@timesys.com>
Subject: [RESEND 1/3] ASoC: ics43432: add CMM-4030D-261 support
Date: Sat, 21 Aug 2021 10:26:56 +0200	[thread overview]
Message-ID: <20210821082658.4147595-1-angelo.dureghello@timesys.com> (raw)

Despite minimal datasheet differences, the driver seems
perfectly compatible with CMM-4030D-261.

Tested CMM-4030D-261 to work with this changes:

/ {
        cmm4030d: cmm4030d {
                #sound-dai-cells = <0>;
                compatible = "cui,cmm-4030d-261";
        };

        sound_mic {
                compatible = "simple-audio-card";
                simple-audio-card,name = "i2s mem mic";
                simple-audio-card,format = "i2s";
                simple-audio-card,bitclock-master = <&sound_master>;
                simple-audio-card,frame-master = <&sound_master>;
                sound_master: simple-audio-card,cpu {
                        sound-dai = <&ssi2>;
                        system-clock-frequency = <2822400>;
                };
                simple-audio-card,codec {
                        sound-dai = <&cmm4030d>;
                };
        };
};

Audio has been captured and tested successfully by:

arecord -D "hw:1,0" -f S24_LE > test.wav
aplay test.wav

Signed-off-by: Angelo Dureghello <angelo.dureghello@timesys.com>
---
 sound/soc/codecs/Kconfig    | 2 +-
 sound/soc/codecs/ics43432.c | 4 +++-
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/sound/soc/codecs/Kconfig b/sound/soc/codecs/Kconfig
index db16071205ba..cd1976aae328 100644
--- a/sound/soc/codecs/Kconfig
+++ b/sound/soc/codecs/Kconfig
@@ -847,7 +847,7 @@ config SND_SOC_HDAC_HDA
 	select SND_HDA
 
 config SND_SOC_ICS43432
-	tristate
+	tristate "ICS43423 and compatible i2s microphones"
 
 config SND_SOC_INNO_RK3036
 	tristate "Inno codec driver for RK3036 SoC"
diff --git a/sound/soc/codecs/ics43432.c b/sound/soc/codecs/ics43432.c
index 47e749f03940..de4c8460ab3d 100644
--- a/sound/soc/codecs/ics43432.c
+++ b/sound/soc/codecs/ics43432.c
@@ -1,6 +1,7 @@
 // SPDX-License-Identifier: GPL-2.0-only
 /*
- * I2S MEMS microphone driver for InvenSense ICS-43432
+ * I2S MEMS microphone driver for InvenSense ICS-43432 and similar
+ * MEMS-based microphones.
  *
  * - Non configurable.
  * - I2S interface, 64 BCLs per frame, 32 bits per channel, 24 bit data
@@ -53,6 +54,7 @@ static int ics43432_probe(struct platform_device *pdev)
 #ifdef CONFIG_OF
 static const struct of_device_id ics43432_ids[] = {
 	{ .compatible = "invensense,ics43432", },
+	{ .compatible = "cui,cmm-4030d-261", },
 	{ }
 };
 MODULE_DEVICE_TABLE(of, ics43432_ids);
-- 
2.32.0


             reply	other threads:[~2021-08-21  8:30 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-21  8:26 Angelo Dureghello [this message]
2021-08-21  8:26 ` [RESEND 2/3] dt-bindings: add compatible vendor prefix for CUI Devices Angelo Dureghello
2021-08-23 11:16   ` Mark Brown
2021-08-21  8:26 ` [RESEND 3/3] ASoC: ics43432: add compatible " Angelo Dureghello
2021-08-23 11:16 ` [RESEND 1/3] ASoC: ics43432: add CMM-4030D-261 support Mark Brown
2021-08-23 17:37 ` Mark Brown
  -- strict thread matches above, loose matches on Subject: below --
2021-08-21  7:53 Angelo Dureghello

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=20210821082658.4147595-1-angelo.dureghello@timesys.com \
    --to=angelo.dureghello@timesys.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=ricard.wanderlof@axis.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.