From patchwork Thu May 31 15:10:23 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans de Goede X-Patchwork-Id: 10441289 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 48C72603B5 for ; Thu, 31 May 2018 15:10:54 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 34E3328595 for ; Thu, 31 May 2018 15:10:54 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 29A702859A; Thu, 31 May 2018 15:10:54 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00, MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B0A5C28595 for ; Thu, 31 May 2018 15:10:52 +0000 (UTC) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 4FC72267932; Thu, 31 May 2018 17:10:40 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id 1D6FF267937; Thu, 31 May 2018 17:10:35 +0200 (CEST) Received: from mx1.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by alsa0.perex.cz (Postfix) with ESMTP id 70CDD267910 for ; Thu, 31 May 2018 17:10:31 +0200 (CEST) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id B3B05401EF10; Thu, 31 May 2018 15:10:30 +0000 (UTC) Received: from shalem.localdomain.com (ovpn-116-177.ams2.redhat.com [10.36.116.177]) by smtp.corp.redhat.com (Postfix) with ESMTP id E3323208C6C1; Thu, 31 May 2018 15:10:29 +0000 (UTC) From: Hans de Goede To: alsa-devel@alsa-project.org Date: Thu, 31 May 2018 17:10:23 +0200 Message-Id: <20180531151026.29521-3-hdegoede@redhat.com> In-Reply-To: <20180531151026.29521-1-hdegoede@redhat.com> References: <20180531151026.29521-1-hdegoede@redhat.com> X-Scanned-By: MIMEDefang 2.78 on 10.11.54.6 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.5]); Thu, 31 May 2018 15:10:30 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.5]); Thu, 31 May 2018 15:10:30 +0000 (UTC) for IP:'10.11.54.6' DOMAIN:'int-mx06.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'hdegoede@redhat.com' RCPT:'' Cc: Takashi Iwai , Hans de Goede , Pierre-Louis Bossart Subject: [alsa-devel] [PATCH 2/5] conf/ucm: bytcr-rt5640: Add long-name UCM profiles X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP With a recently merged kernel commit, the kernel now sets a long-name for bytcr-rt5640 boards which indicates if a single (mono) speaker or stereo speakers are used and wether dmic1, in1 or in3 is used for the internal mic (the headset mic sofar is always in2). This commit adds UCM profiles for bytcr-rt5640 boards using these new long-names, based on the generic bytcr-rt5640 profile. The added profiles have the unnecessary input / output options from the generic profile removed leaving only 2 input and 2 output options, which are automatically switched between by e.g. pulse based on jack-detect. Signed-off-by: Hans de Goede --- configure.ac | 6 +++++ src/conf/ucm/Makefile.am | 6 +++++ .../bytcr-rt5640-mono-spk-dmic1-mic/HiFi.conf | 26 +++++++++++++++++++ .../Makefile.am | 4 +++ .../bytcr-rt5640-mono-spk-dmic1-mic.conf | 8 ++++++ .../bytcr-rt5640-mono-spk-in1-mic/HiFi.conf | 26 +++++++++++++++++++ .../bytcr-rt5640-mono-spk-in1-mic/Makefile.am | 4 +++ .../bytcr-rt5640-mono-spk-in1-mic.conf | 8 ++++++ .../bytcr-rt5640-mono-spk-in3-mic/HiFi.conf | 26 +++++++++++++++++++ .../bytcr-rt5640-mono-spk-in3-mic/Makefile.am | 4 +++ .../bytcr-rt5640-mono-spk-in3-mic.conf | 8 ++++++ .../HiFi.conf | 26 +++++++++++++++++++ .../Makefile.am | 4 +++ .../bytcr-rt5640-stereo-spk-dmic1-mic.conf | 8 ++++++ .../bytcr-rt5640-stereo-spk-in1-mic/HiFi.conf | 26 +++++++++++++++++++ .../Makefile.am | 4 +++ .../bytcr-rt5640-stereo-spk-in1-mic.conf | 8 ++++++ .../bytcr-rt5640-stereo-spk-in3-mic/HiFi.conf | 26 +++++++++++++++++++ .../Makefile.am | 4 +++ .../bytcr-rt5640-stereo-spk-in3-mic.conf | 8 ++++++ 20 files changed, 240 insertions(+) create mode 100644 src/conf/ucm/bytcr-rt5640-mono-spk-dmic1-mic/HiFi.conf create mode 100644 src/conf/ucm/bytcr-rt5640-mono-spk-dmic1-mic/Makefile.am create mode 100644 src/conf/ucm/bytcr-rt5640-mono-spk-dmic1-mic/bytcr-rt5640-mono-spk-dmic1-mic.conf create mode 100644 src/conf/ucm/bytcr-rt5640-mono-spk-in1-mic/HiFi.conf create mode 100644 src/conf/ucm/bytcr-rt5640-mono-spk-in1-mic/Makefile.am create mode 100644 src/conf/ucm/bytcr-rt5640-mono-spk-in1-mic/bytcr-rt5640-mono-spk-in1-mic.conf create mode 100644 src/conf/ucm/bytcr-rt5640-mono-spk-in3-mic/HiFi.conf create mode 100644 src/conf/ucm/bytcr-rt5640-mono-spk-in3-mic/Makefile.am create mode 100644 src/conf/ucm/bytcr-rt5640-mono-spk-in3-mic/bytcr-rt5640-mono-spk-in3-mic.conf create mode 100644 src/conf/ucm/bytcr-rt5640-stereo-spk-dmic1-mic/HiFi.conf create mode 100644 src/conf/ucm/bytcr-rt5640-stereo-spk-dmic1-mic/Makefile.am create mode 100644 src/conf/ucm/bytcr-rt5640-stereo-spk-dmic1-mic/bytcr-rt5640-stereo-spk-dmic1-mic.conf create mode 100644 src/conf/ucm/bytcr-rt5640-stereo-spk-in1-mic/HiFi.conf create mode 100644 src/conf/ucm/bytcr-rt5640-stereo-spk-in1-mic/Makefile.am create mode 100644 src/conf/ucm/bytcr-rt5640-stereo-spk-in1-mic/bytcr-rt5640-stereo-spk-in1-mic.conf create mode 100644 src/conf/ucm/bytcr-rt5640-stereo-spk-in3-mic/HiFi.conf create mode 100644 src/conf/ucm/bytcr-rt5640-stereo-spk-in3-mic/Makefile.am create mode 100644 src/conf/ucm/bytcr-rt5640-stereo-spk-in3-mic/bytcr-rt5640-stereo-spk-in3-mic.conf diff --git a/configure.ac b/configure.ac index f6ee6ca8..57e0c354 100644 --- a/configure.ac +++ b/configure.ac @@ -722,6 +722,12 @@ AC_OUTPUT(Makefile doc/Makefile doc/pictures/Makefile doc/doxygen.cfg \ src/conf/ucm/broxton-rt298/Makefile \ src/conf/ucm/bytcr/Makefile \ src/conf/ucm/bytcr-rt5640/Makefile \ + src/conf/ucm/bytcr-rt5640-mono-spk-dmic1-mic/Makefile \ + src/conf/ucm/bytcr-rt5640-mono-spk-in1-mic/Makefile \ + src/conf/ucm/bytcr-rt5640-mono-spk-in3-mic/Makefile \ + src/conf/ucm/bytcr-rt5640-stereo-spk-dmic1-mic/Makefile \ + src/conf/ucm/bytcr-rt5640-stereo-spk-in1-mic/Makefile \ + src/conf/ucm/bytcr-rt5640-stereo-spk-in3-mic/Makefile \ src/conf/ucm/bytcr-rt5651/Makefile \ src/conf/ucm/chtrt5645/Makefile \ src/conf/ucm/chtrt5645-mono-speaker-analog-mic/Makefile \ diff --git a/src/conf/ucm/Makefile.am b/src/conf/ucm/Makefile.am index dc2d6857..a524921b 100644 --- a/src/conf/ucm/Makefile.am +++ b/src/conf/ucm/Makefile.am @@ -4,6 +4,12 @@ broadwell-rt286 \ broxton-rt298 \ bytcr \ bytcr-rt5640 \ +bytcr-rt5640-mono-spk-dmic1-mic \ +bytcr-rt5640-mono-spk-in1-mic \ +bytcr-rt5640-mono-spk-in3-mic \ +bytcr-rt5640-stereo-spk-dmic1-mic \ +bytcr-rt5640-stereo-spk-in1-mic \ +bytcr-rt5640-stereo-spk-in3-mic \ bytcr-rt5651 \ chtrt5645 \ chtrt5645-mono-speaker-analog-mic \ diff --git a/src/conf/ucm/bytcr-rt5640-mono-spk-dmic1-mic/HiFi.conf b/src/conf/ucm/bytcr-rt5640-mono-spk-dmic1-mic/HiFi.conf new file mode 100644 index 00000000..47ca04f0 --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-mono-spk-dmic1-mic/HiFi.conf @@ -0,0 +1,26 @@ +# Use case Configuration for bytcr-rt5640 + + + +SectionVerb { + EnableSequence [ + cdev "hw:bytcrrt5640" + + + + ] + + DisableSequence [ + ] + + Value { + PlaybackPCM "hw:bytcrrt5640" + CapturePCM "hw:bytcrrt5640" + } +} + + + + + + diff --git a/src/conf/ucm/bytcr-rt5640-mono-spk-dmic1-mic/Makefile.am b/src/conf/ucm/bytcr-rt5640-mono-spk-dmic1-mic/Makefile.am new file mode 100644 index 00000000..55ed3dbd --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-mono-spk-dmic1-mic/Makefile.am @@ -0,0 +1,4 @@ +alsaconfigdir = @ALSA_CONFIG_DIR@ +ucmdir = $(alsaconfigdir)/ucm/bytcr-rt5640-mono-spk-dmic1-mic +ucm_DATA = bytcr-rt5640-mono-spk-dmic1-mic.conf HiFi.conf +EXTRA_DIST = $(ucm_DATA) diff --git a/src/conf/ucm/bytcr-rt5640-mono-spk-dmic1-mic/bytcr-rt5640-mono-spk-dmic1-mic.conf b/src/conf/ucm/bytcr-rt5640-mono-spk-dmic1-mic/bytcr-rt5640-mono-spk-dmic1-mic.conf new file mode 100644 index 00000000..f5297e9e --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-mono-spk-dmic1-mic/bytcr-rt5640-mono-spk-dmic1-mic.conf @@ -0,0 +1,8 @@ +SectionUseCase."HiFi" { + File "../bytcr-rt5640-mono-spk-dmic1-mic/HiFi.conf" + Comment "Play HiFi quality Music" +} + +SectionDefaults [ + cdev "hw:bytcrrt5640" +] diff --git a/src/conf/ucm/bytcr-rt5640-mono-spk-in1-mic/HiFi.conf b/src/conf/ucm/bytcr-rt5640-mono-spk-in1-mic/HiFi.conf new file mode 100644 index 00000000..e280843d --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-mono-spk-in1-mic/HiFi.conf @@ -0,0 +1,26 @@ +# Use case Configuration for bytcr-rt5640 + + + +SectionVerb { + EnableSequence [ + cdev "hw:bytcrrt5640" + + + + ] + + DisableSequence [ + ] + + Value { + PlaybackPCM "hw:bytcrrt5640" + CapturePCM "hw:bytcrrt5640" + } +} + + + + + + diff --git a/src/conf/ucm/bytcr-rt5640-mono-spk-in1-mic/Makefile.am b/src/conf/ucm/bytcr-rt5640-mono-spk-in1-mic/Makefile.am new file mode 100644 index 00000000..d306cfcb --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-mono-spk-in1-mic/Makefile.am @@ -0,0 +1,4 @@ +alsaconfigdir = @ALSA_CONFIG_DIR@ +ucmdir = $(alsaconfigdir)/ucm/bytcr-rt5640-mono-spk-in1-mic +ucm_DATA = bytcr-rt5640-mono-spk-in1-mic.conf HiFi.conf +EXTRA_DIST = $(ucm_DATA) diff --git a/src/conf/ucm/bytcr-rt5640-mono-spk-in1-mic/bytcr-rt5640-mono-spk-in1-mic.conf b/src/conf/ucm/bytcr-rt5640-mono-spk-in1-mic/bytcr-rt5640-mono-spk-in1-mic.conf new file mode 100644 index 00000000..cdac03a1 --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-mono-spk-in1-mic/bytcr-rt5640-mono-spk-in1-mic.conf @@ -0,0 +1,8 @@ +SectionUseCase."HiFi" { + File "../bytcr-rt5640-mono-spk-in1-mic/HiFi.conf" + Comment "Play HiFi quality Music" +} + +SectionDefaults [ + cdev "hw:bytcrrt5640" +] diff --git a/src/conf/ucm/bytcr-rt5640-mono-spk-in3-mic/HiFi.conf b/src/conf/ucm/bytcr-rt5640-mono-spk-in3-mic/HiFi.conf new file mode 100644 index 00000000..511b7c98 --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-mono-spk-in3-mic/HiFi.conf @@ -0,0 +1,26 @@ +# Use case Configuration for bytcr-rt5640 + + + +SectionVerb { + EnableSequence [ + cdev "hw:bytcrrt5640" + + + + ] + + DisableSequence [ + ] + + Value { + PlaybackPCM "hw:bytcrrt5640" + CapturePCM "hw:bytcrrt5640" + } +} + + + + + + diff --git a/src/conf/ucm/bytcr-rt5640-mono-spk-in3-mic/Makefile.am b/src/conf/ucm/bytcr-rt5640-mono-spk-in3-mic/Makefile.am new file mode 100644 index 00000000..3f44a725 --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-mono-spk-in3-mic/Makefile.am @@ -0,0 +1,4 @@ +alsaconfigdir = @ALSA_CONFIG_DIR@ +ucmdir = $(alsaconfigdir)/ucm/bytcr-rt5640-mono-spk-in3-mic +ucm_DATA = bytcr-rt5640-mono-spk-in3-mic.conf HiFi.conf +EXTRA_DIST = $(ucm_DATA) diff --git a/src/conf/ucm/bytcr-rt5640-mono-spk-in3-mic/bytcr-rt5640-mono-spk-in3-mic.conf b/src/conf/ucm/bytcr-rt5640-mono-spk-in3-mic/bytcr-rt5640-mono-spk-in3-mic.conf new file mode 100644 index 00000000..15807363 --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-mono-spk-in3-mic/bytcr-rt5640-mono-spk-in3-mic.conf @@ -0,0 +1,8 @@ +SectionUseCase."HiFi" { + File "../bytcr-rt5640-mono-spk-in3-mic/HiFi.conf" + Comment "Play HiFi quality Music" +} + +SectionDefaults [ + cdev "hw:bytcrrt5640" +] diff --git a/src/conf/ucm/bytcr-rt5640-stereo-spk-dmic1-mic/HiFi.conf b/src/conf/ucm/bytcr-rt5640-stereo-spk-dmic1-mic/HiFi.conf new file mode 100644 index 00000000..8cf5cb7c --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-stereo-spk-dmic1-mic/HiFi.conf @@ -0,0 +1,26 @@ +# Use case Configuration for bytcr-rt5640 + + + +SectionVerb { + EnableSequence [ + cdev "hw:bytcrrt5640" + + + + ] + + DisableSequence [ + ] + + Value { + PlaybackPCM "hw:bytcrrt5640" + CapturePCM "hw:bytcrrt5640" + } +} + + + + + + diff --git a/src/conf/ucm/bytcr-rt5640-stereo-spk-dmic1-mic/Makefile.am b/src/conf/ucm/bytcr-rt5640-stereo-spk-dmic1-mic/Makefile.am new file mode 100644 index 00000000..acd1f0ef --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-stereo-spk-dmic1-mic/Makefile.am @@ -0,0 +1,4 @@ +alsaconfigdir = @ALSA_CONFIG_DIR@ +ucmdir = $(alsaconfigdir)/ucm/bytcr-rt5640-stereo-spk-dmic1-mic +ucm_DATA = bytcr-rt5640-stereo-spk-dmic1-mic.conf HiFi.conf +EXTRA_DIST = $(ucm_DATA) diff --git a/src/conf/ucm/bytcr-rt5640-stereo-spk-dmic1-mic/bytcr-rt5640-stereo-spk-dmic1-mic.conf b/src/conf/ucm/bytcr-rt5640-stereo-spk-dmic1-mic/bytcr-rt5640-stereo-spk-dmic1-mic.conf new file mode 100644 index 00000000..a84bf842 --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-stereo-spk-dmic1-mic/bytcr-rt5640-stereo-spk-dmic1-mic.conf @@ -0,0 +1,8 @@ +SectionUseCase."HiFi" { + File "../bytcr-rt5640-stereo-spk-dmic1-mic/HiFi.conf" + Comment "Play HiFi quality Music" +} + +SectionDefaults [ + cdev "hw:bytcrrt5640" +] diff --git a/src/conf/ucm/bytcr-rt5640-stereo-spk-in1-mic/HiFi.conf b/src/conf/ucm/bytcr-rt5640-stereo-spk-in1-mic/HiFi.conf new file mode 100644 index 00000000..a617ba19 --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-stereo-spk-in1-mic/HiFi.conf @@ -0,0 +1,26 @@ +# Use case Configuration for bytcr-rt5640 + + + +SectionVerb { + EnableSequence [ + cdev "hw:bytcrrt5640" + + + + ] + + DisableSequence [ + ] + + Value { + PlaybackPCM "hw:bytcrrt5640" + CapturePCM "hw:bytcrrt5640" + } +} + + + + + + diff --git a/src/conf/ucm/bytcr-rt5640-stereo-spk-in1-mic/Makefile.am b/src/conf/ucm/bytcr-rt5640-stereo-spk-in1-mic/Makefile.am new file mode 100644 index 00000000..f6f11fe8 --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-stereo-spk-in1-mic/Makefile.am @@ -0,0 +1,4 @@ +alsaconfigdir = @ALSA_CONFIG_DIR@ +ucmdir = $(alsaconfigdir)/ucm/bytcr-rt5640-stereo-spk-in1-mic +ucm_DATA = bytcr-rt5640-stereo-spk-in1-mic.conf HiFi.conf +EXTRA_DIST = $(ucm_DATA) diff --git a/src/conf/ucm/bytcr-rt5640-stereo-spk-in1-mic/bytcr-rt5640-stereo-spk-in1-mic.conf b/src/conf/ucm/bytcr-rt5640-stereo-spk-in1-mic/bytcr-rt5640-stereo-spk-in1-mic.conf new file mode 100644 index 00000000..e8231c17 --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-stereo-spk-in1-mic/bytcr-rt5640-stereo-spk-in1-mic.conf @@ -0,0 +1,8 @@ +SectionUseCase."HiFi" { + File "../bytcr-rt5640-stereo-spk-in1-mic/HiFi.conf" + Comment "Play HiFi quality Music" +} + +SectionDefaults [ + cdev "hw:bytcrrt5640" +] diff --git a/src/conf/ucm/bytcr-rt5640-stereo-spk-in3-mic/HiFi.conf b/src/conf/ucm/bytcr-rt5640-stereo-spk-in3-mic/HiFi.conf new file mode 100644 index 00000000..83b31795 --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-stereo-spk-in3-mic/HiFi.conf @@ -0,0 +1,26 @@ +# Use case Configuration for bytcr-rt5640 + + + +SectionVerb { + EnableSequence [ + cdev "hw:bytcrrt5640" + + + + ] + + DisableSequence [ + ] + + Value { + PlaybackPCM "hw:bytcrrt5640" + CapturePCM "hw:bytcrrt5640" + } +} + + + + + + diff --git a/src/conf/ucm/bytcr-rt5640-stereo-spk-in3-mic/Makefile.am b/src/conf/ucm/bytcr-rt5640-stereo-spk-in3-mic/Makefile.am new file mode 100644 index 00000000..bedd535d --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-stereo-spk-in3-mic/Makefile.am @@ -0,0 +1,4 @@ +alsaconfigdir = @ALSA_CONFIG_DIR@ +ucmdir = $(alsaconfigdir)/ucm/bytcr-rt5640-stereo-spk-in3-mic +ucm_DATA = bytcr-rt5640-stereo-spk-in3-mic.conf HiFi.conf +EXTRA_DIST = $(ucm_DATA) diff --git a/src/conf/ucm/bytcr-rt5640-stereo-spk-in3-mic/bytcr-rt5640-stereo-spk-in3-mic.conf b/src/conf/ucm/bytcr-rt5640-stereo-spk-in3-mic/bytcr-rt5640-stereo-spk-in3-mic.conf new file mode 100644 index 00000000..ba369dcf --- /dev/null +++ b/src/conf/ucm/bytcr-rt5640-stereo-spk-in3-mic/bytcr-rt5640-stereo-spk-in3-mic.conf @@ -0,0 +1,8 @@ +SectionUseCase."HiFi" { + File "../bytcr-rt5640-stereo-spk-in3-mic/HiFi.conf" + Comment "Play HiFi quality Music" +} + +SectionDefaults [ + cdev "hw:bytcrrt5640" +]