From patchwork Mon Dec 24 15:05:02 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: 10742317 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 1180E6C5 for ; Mon, 24 Dec 2018 15:23:05 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F329A28B78 for ; Mon, 24 Dec 2018 15:23:04 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E747328B7A; Mon, 24 Dec 2018 15:23:04 +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 78BC928B7B for ; Mon, 24 Dec 2018 15:23:02 +0000 (UTC) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 24750267AF4; Mon, 24 Dec 2018 16:05:14 +0100 (CET) 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 4703E267AED; Mon, 24 Dec 2018 16:05:12 +0100 (CET) Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by alsa0.perex.cz (Postfix) with ESMTP id 70A5F267A65 for ; Mon, 24 Dec 2018 16:05:09 +0100 (CET) Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id E059D58E51; Mon, 24 Dec 2018 15:05:07 +0000 (UTC) Received: from shalem.localdomain.com (ovpn-116-95.ams2.redhat.com [10.36.116.95]) by smtp.corp.redhat.com (Postfix) with ESMTP id E0788100190E; Mon, 24 Dec 2018 15:05:06 +0000 (UTC) From: Hans de Goede To: alsa-devel@alsa-project.org Date: Mon, 24 Dec 2018 16:05:02 +0100 Message-Id: <20181224150504.20845-2-hdegoede@redhat.com> In-Reply-To: <20181224150504.20845-1-hdegoede@redhat.com> References: <20181224150504.20845-1-hdegoede@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Mon, 24 Dec 2018 15:05:08 +0000 (UTC) Cc: Takashi Iwai , Hans de Goede , Pierre-Louis Bossart Subject: [alsa-devel] [PATCH 2/4] conf/ucm: bytcr-rt5651: Add support for a headset-mic on IN2 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: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP The first design with the headset-mic on IN2 rather then the default / reference-design IN3 has shown up. Add a new ucm/codecs/rt5651/IN2-HeadsetMic.conf snippet to deal with this and include this in the default non board-specific bytcr-rt5651.conf. Signed-off-by: Hans de Goede --- src/conf/ucm/bytcr-rt5651/HiFi.conf | 1 + src/conf/ucm/codecs/rt5651/IN1-InternalMic.conf | 1 + src/conf/ucm/codecs/rt5651/IN12-InternalMic.conf | 1 + .../{IN2-InternalMic.conf => IN2-HeadsetMic.conf} | 10 ++++++---- src/conf/ucm/codecs/rt5651/IN2-InternalMic.conf | 1 + src/conf/ucm/codecs/rt5651/IN3-HeadsetMic.conf | 3 ++- src/conf/ucm/codecs/rt5651/Makefile.am | 2 +- 7 files changed, 13 insertions(+), 6 deletions(-) copy src/conf/ucm/codecs/rt5651/{IN2-InternalMic.conf => IN2-HeadsetMic.conf} (73%) diff --git a/src/conf/ucm/bytcr-rt5651/HiFi.conf b/src/conf/ucm/bytcr-rt5651/HiFi.conf index fddd8a3c..37bb1d40 100644 --- a/src/conf/ucm/bytcr-rt5651/HiFi.conf +++ b/src/conf/ucm/bytcr-rt5651/HiFi.conf @@ -26,4 +26,5 @@ SectionVerb { + diff --git a/src/conf/ucm/codecs/rt5651/IN1-InternalMic.conf b/src/conf/ucm/codecs/rt5651/IN1-InternalMic.conf index b2ce17b6..5092809f 100644 --- a/src/conf/ucm/codecs/rt5651/IN1-InternalMic.conf +++ b/src/conf/ucm/codecs/rt5651/IN1-InternalMic.conf @@ -4,6 +4,7 @@ SectionDevice."InternalMic-IN1" { ConflictingDevice [ "InternalMic-IN2" "InternalMic-IN12" + "HeadsetMic-IN2" "HeadsetMic-IN3" ] diff --git a/src/conf/ucm/codecs/rt5651/IN12-InternalMic.conf b/src/conf/ucm/codecs/rt5651/IN12-InternalMic.conf index e8041912..c917e85e 100644 --- a/src/conf/ucm/codecs/rt5651/IN12-InternalMic.conf +++ b/src/conf/ucm/codecs/rt5651/IN12-InternalMic.conf @@ -4,6 +4,7 @@ SectionDevice."InternalMic-IN12" { ConflictingDevice [ "InternalMic-IN1" "InternalMic-IN2" + "HeadsetMic-IN2" "HeadsetMic-IN3" ] diff --git a/src/conf/ucm/codecs/rt5651/IN2-InternalMic.conf b/src/conf/ucm/codecs/rt5651/IN2-HeadsetMic.conf similarity index 73% copy from src/conf/ucm/codecs/rt5651/IN2-InternalMic.conf copy to src/conf/ucm/codecs/rt5651/IN2-HeadsetMic.conf index 048fcc95..b6dc0814 100644 --- a/src/conf/ucm/codecs/rt5651/IN2-InternalMic.conf +++ b/src/conf/ucm/codecs/rt5651/IN2-HeadsetMic.conf @@ -1,15 +1,16 @@ -SectionDevice."InternalMic-IN2" { - Comment "Internal Microphone on IN2" +SectionDevice."HeadsetMic-IN2" { + Comment "Headset Microphone on IN2" ConflictingDevice [ "InternalMic-IN1" + "InternalMic-IN2" "InternalMic-IN12" "HeadsetMic-IN3" ] EnableSequence [ cdev "hw:bytcrrt5651" - cset "name='Internal Mic Switch' on" + cset "name='Headset Mic Switch' on" cset "name='RECMIXL BST2 Switch' on" cset "name='RECMIXR BST2 Switch' on" cset "name='Stereo1 ADC MIXL ADC1 Switch' on" @@ -20,12 +21,13 @@ SectionDevice."InternalMic-IN2" { cdev "hw:bytcrrt5651" cset "name='Stereo1 ADC MIXL ADC1 Switch' off" cset "name='Stereo1 ADC MIXR ADC1 Switch' off" - cset "name='Internal Mic Switch' off" + cset "name='Headset Mic Switch' off" cset "name='RECMIXL BST2 Switch' off" cset "name='RECMIXR BST2 Switch' off" ] Value { CaptureChannels "2" + JackControl "Headset Mic Jack" } } diff --git a/src/conf/ucm/codecs/rt5651/IN2-InternalMic.conf b/src/conf/ucm/codecs/rt5651/IN2-InternalMic.conf index 048fcc95..bbb713c0 100644 --- a/src/conf/ucm/codecs/rt5651/IN2-InternalMic.conf +++ b/src/conf/ucm/codecs/rt5651/IN2-InternalMic.conf @@ -4,6 +4,7 @@ SectionDevice."InternalMic-IN2" { ConflictingDevice [ "InternalMic-IN1" "InternalMic-IN12" + "HeadsetMic-IN2" "HeadsetMic-IN3" ] diff --git a/src/conf/ucm/codecs/rt5651/IN3-HeadsetMic.conf b/src/conf/ucm/codecs/rt5651/IN3-HeadsetMic.conf index 712d14bb..48f3e463 100644 --- a/src/conf/ucm/codecs/rt5651/IN3-HeadsetMic.conf +++ b/src/conf/ucm/codecs/rt5651/IN3-HeadsetMic.conf @@ -1,10 +1,11 @@ SectionDevice."HeadsetMic-IN3" { - Comment "Headset Microphone" + Comment "Headset Microphone on IN3" ConflictingDevice [ "InternalMic-IN1" "InternalMic-IN2" "InternalMic-IN12" + "HeadsetMic-IN2" ] EnableSequence [ diff --git a/src/conf/ucm/codecs/rt5651/Makefile.am b/src/conf/ucm/codecs/rt5651/Makefile.am index a68bd7bb..889b4fd4 100644 --- a/src/conf/ucm/codecs/rt5651/Makefile.am +++ b/src/conf/ucm/codecs/rt5651/Makefile.am @@ -2,5 +2,5 @@ alsaconfigdir = @ALSA_CONFIG_DIR@ ucmdir = $(alsaconfigdir)/ucm/codecs/rt5651 ucm_DATA = EnableSeq.conf HeadPhones.conf HeadPhones-swapped.conf \ IN1-InternalMic.conf IN2-InternalMic.conf IN12-InternalMic.conf \ - IN3-HeadsetMic.conf Speaker.conf MonoSpeaker.conf + IN2-HeadsetMic.conf IN3-HeadsetMic.conf Speaker.conf MonoSpeaker.conf EXTRA_DIST = $(ucm_DATA)