From patchwork Mon Jun 24 12:11:16 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierre-Louis Bossart X-Patchwork-Id: 807066 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 77EB0C2BD09 for ; Mon, 24 Jun 2024 12:12:41 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 15CA1845; Mon, 24 Jun 2024 14:12:29 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 15CA1845 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1719231159; bh=eKR4UMvmeTLd+anS9f6YYfklV3EDalMCO5Nwb3ZoiP8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=h1bXfD0zGnUEJ/vtSRdkgW3KmQ469PwN/s3i2MDQOLl3F271ojYXu6Q4tvXFxHIkE YAE/0WsoVewlNjN1EDWlvfD0DlJtaGgWwsCp9KJDUXb3Qd4dh8cIGzbOzoqX0Vv4bE r8geaNpuPgQQNauYXGc79zgr7nvc83KLY+HpUqrE= Received: by alsa1.perex.cz (Postfix, from userid 50401) id 37C0EF805D6; Mon, 24 Jun 2024 14:11:49 +0200 (CEST) Received: from mailman-core.alsa-project.org (mailman-core.alsa-project.org [10.254.200.10]) by alsa1.perex.cz (Postfix) with ESMTP id 7C207F805E3; Mon, 24 Jun 2024 14:11:49 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id EFEBAF8049C; Mon, 24 Jun 2024 14:11:41 +0200 (CEST) Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 7077CF800E4 for ; Mon, 24 Jun 2024 14:11:37 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 7077CF800E4 Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key, unprotected) header.d=intel.com header.i=@intel.com header.a=rsa-sha256 header.s=Intel header.b=NeYlOgu1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1719231099; x=1750767099; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=eKR4UMvmeTLd+anS9f6YYfklV3EDalMCO5Nwb3ZoiP8=; b=NeYlOgu1QfSDIJ778V1xDrWkSpzrQzhLaqnJKl3DY0vzjBb7E58vtXfZ +bqahd3LOyWcikKabbnYgjcmAqMji58L6KizqlB/sKzbTGaAaxDHLnRF3 q5hWAVWRll8JpdW8Fz3eJ2M62i6cR8rzO/FOxrhhwm5gxKpbaN3jfx+DF XG4lkw8IG6+pS6iYj7yeRMxVaD6EoHqJ27xbdVjgvUERBfBTLZbPXLra1 F+NkzWcpbK2VdfbZgAvitA+JYwCeMZTzYeIpEJQSuwpzXGCwjunWKfzG5 zbhKzW4ATbFp2fWYP6LtNyYagIuMEu0k5jOz8a/b5kflXMi22lzgmAyrH Q==; X-CSE-ConnectionGUID: oT9l4uyMQ6uJpbHP8dN9cw== X-CSE-MsgGUID: KOriH+jES/SoPDQvrjZkfA== X-IronPort-AV: E=McAfee;i="6700,10204,11112"; a="15887537" X-IronPort-AV: E=Sophos;i="6.08,261,1712646000"; d="scan'208";a="15887537" Received: from fmviesa006.fm.intel.com ([10.60.135.146]) by fmvoesa112.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 Jun 2024 05:11:35 -0700 X-CSE-ConnectionGUID: emiwiWU7R6+8Vwj9YUQlFQ== X-CSE-MsgGUID: qbks1TvfTx6vbjaMDC8leg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,261,1712646000"; d="scan'208";a="43091208" Received: from ksztyber-mobl2.ger.corp.intel.com (HELO pbossart-mobl6.intel.com) ([10.245.246.230]) by fmviesa006-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 Jun 2024 05:11:34 -0700 From: Pierre-Louis Bossart To: linux-sound@vger.kernel.org Cc: alsa-devel@alsa-project.org, tiwai@suse.de, broonie@kernel.org, Pierre-Louis Bossart Subject: [PATCH 1/4] ASoC: Intel: sof_sdw: fix jack detection on ADL-N variant RVP Date: Mon, 24 Jun 2024 14:11:16 +0200 Message-ID: <20240624121119.91552-2-pierre-louis.bossart@linux.intel.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240624121119.91552-1-pierre-louis.bossart@linux.intel.com> References: <20240624121119.91552-1-pierre-louis.bossart@linux.intel.com> MIME-Version: 1.0 Message-ID-Hash: OORXQVCK25EYDTMT3TVV4H77XOE6AWMD X-Message-ID-Hash: OORXQVCK25EYDTMT3TVV4H77XOE6AWMD X-MailFrom: pierre-louis.bossart@linux.intel.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-alsa-devel.alsa-project.org-0; header-match-alsa-devel.alsa-project.org-1; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.9 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Experimental tests show that JD2_100K is required, otherwise the jack is detected always even with nothing plugged-in. To avoid matching with other known quirks the SKU information is used. Signed-off-by: Pierre-Louis Bossart --- sound/soc/intel/boards/sof_sdw.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/sound/soc/intel/boards/sof_sdw.c b/sound/soc/intel/boards/sof_sdw.c index b646b32dd311..89b92a061489 100644 --- a/sound/soc/intel/boards/sof_sdw.c +++ b/sound/soc/intel/boards/sof_sdw.c @@ -277,6 +277,15 @@ static const struct dmi_system_id sof_sdw_quirk_table[] = { SOF_BT_OFFLOAD_SSP(2) | SOF_SSP_BT_OFFLOAD_PRESENT), }, + { + .callback = sof_sdw_quirk_cb, + .matches = { + DMI_MATCH(DMI_BOARD_VENDOR, "Intel Corporation"), + DMI_MATCH(DMI_PRODUCT_SKU, "0000000000070000"), + }, + .driver_data = (void *)(SOF_SDW_TGL_HDMI | + RT711_JD2_100K), + }, { .callback = sof_sdw_quirk_cb, .matches = { From patchwork Mon Jun 24 12:11:17 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierre-Louis Bossart X-Patchwork-Id: 807297 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id EEBC4C2BD05 for ; Mon, 24 Jun 2024 12:12:52 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id E19D6844; Mon, 24 Jun 2024 14:12:40 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz E19D6844 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1719231170; bh=UFzKGxzmCvgpTCM7GovIF2X1aBmxmsmexFJMbXdSkmI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=VqPz/XdqNV3k7nOZTksmbXVJD13V1TotZYXnwpdIh5i1rgeyrOLsYOh8Ckli0PVsp dZpRjMUTvyfvq5zf871Am7r4sy5PSSG3gchnGCMprhu5qgAs0DnSqxbPaQOW+PsliS Dy8IP3Yk6nG6JM914mRaiQsqgKgtjX3zkDb4K8wI= Received: by alsa1.perex.cz (Postfix, from userid 50401) id E9374F805F2; Mon, 24 Jun 2024 14:11:52 +0200 (CEST) Received: from mailman-core.alsa-project.org (mailman-core.alsa-project.org [10.254.200.10]) by alsa1.perex.cz (Postfix) with ESMTP id 8C686F80608; Mon, 24 Jun 2024 14:11:52 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id C8FB9F8059F; Mon, 24 Jun 2024 14:11:44 +0200 (CEST) Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id EF5EEF80423 for ; Mon, 24 Jun 2024 14:11:38 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz EF5EEF80423 Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key, unprotected) header.d=intel.com header.i=@intel.com header.a=rsa-sha256 header.s=Intel header.b=gUkDHXwe DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1719231100; x=1750767100; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=UFzKGxzmCvgpTCM7GovIF2X1aBmxmsmexFJMbXdSkmI=; b=gUkDHXwerQoqYiW3UuviDa6wQXwnKTj6lR1rceDvt9RQKLOvYdkSh8LG s68crr92FIUdVYe1YDNS+DZ5ON9dYYtSYildt/U14XlqrBv0mXWupC0O3 oRyv3e3/fDrYbqIupa0vk3rfWaQt4loSQmd07B7SqwNaJhmMhYKm1zT0D CCTYhrgRtygWassc7xWHj5tHmZhsyKeRNfEf0x/SDXJlEQTFDzfR063Yn b3FreDudxKm5rGlsfxJzIRyf/FOXZGnrCtk08R7lHsMaVORRIuJVnRbY3 aLFJNjj/YDg9RzmcuxKl2bzgCW0lM/P9UZ/dSr+9d2rZLvqpaVPTD22T6 A==; X-CSE-ConnectionGUID: zh/sELayQRKkgDe2IhBxMQ== X-CSE-MsgGUID: 0Ape3q5NT9Kq4GAgBD8yug== X-IronPort-AV: E=McAfee;i="6700,10204,11112"; a="15887544" X-IronPort-AV: E=Sophos;i="6.08,261,1712646000"; d="scan'208";a="15887544" Received: from fmviesa006.fm.intel.com ([10.60.135.146]) by fmvoesa112.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 Jun 2024 05:11:38 -0700 X-CSE-ConnectionGUID: 7+mxtzNZRcKY16+NFKweew== X-CSE-MsgGUID: wq6mPcfyQme65JB5WAhfwQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,261,1712646000"; d="scan'208";a="43091217" Received: from ksztyber-mobl2.ger.corp.intel.com (HELO pbossart-mobl6.intel.com) ([10.245.246.230]) by fmviesa006-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 Jun 2024 05:11:36 -0700 From: Pierre-Louis Bossart To: linux-sound@vger.kernel.org Cc: alsa-devel@alsa-project.org, tiwai@suse.de, broonie@kernel.org, Brent Lu , Bard Liao , Pierre-Louis Bossart Subject: [PATCH 2/4] ASoC: Intel: maxim-common: add max_98373_get_tx_mask function Date: Mon, 24 Jun 2024 14:11:17 +0200 Message-ID: <20240624121119.91552-3-pierre-louis.bossart@linux.intel.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240624121119.91552-1-pierre-louis.bossart@linux.intel.com> References: <20240624121119.91552-1-pierre-louis.bossart@linux.intel.com> MIME-Version: 1.0 Message-ID-Hash: 7FEBCY2GPUMARS7CKBHZBSIOQ4EWWBZ5 X-Message-ID-Hash: 7FEBCY2GPUMARS7CKBHZBSIOQ4EWWBZ5 X-MailFrom: pierre-louis.bossart@linux.intel.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-alsa-devel.alsa-project.org-0; header-match-alsa-devel.alsa-project.org-1; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.9 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: Brent Lu Add a helper function max_98373_get_tx_mask() to get tx mask from max98373 ACPI device properties at runtime. Reviewed-by: Bard Liao Signed-off-by: Brent Lu Signed-off-by: Pierre-Louis Bossart --- sound/soc/intel/boards/sof_maxim_common.c | 56 +++++++++++++++++------ 1 file changed, 43 insertions(+), 13 deletions(-) diff --git a/sound/soc/intel/boards/sof_maxim_common.c b/sound/soc/intel/boards/sof_maxim_common.c index f965b172fa36..fcc3b95e57a4 100644 --- a/sound/soc/intel/boards/sof_maxim_common.c +++ b/sound/soc/intel/boards/sof_maxim_common.c @@ -77,19 +77,36 @@ static struct snd_soc_dai_link_component max_98373_components[] = { * According to the definition of 'DAI Sel Mux' mixer in max98373.c, rx mask * should choose two channels from TDM slots, the LSB of rx mask is left channel * and the other one is right channel. - * - * For tx mask, each codec requires two channels: one for V-sense and the other - * one for I-sense. Must match the device property "maxim,vmon-slot-no" and - * "maxim,imon-slot-no" in ACPI table. */ static const struct { - unsigned int tx; unsigned int rx; } max_98373_tdm_mask[] = { - {.tx = 0x03, .rx = 0x3}, - {.tx = 0x0c, .rx = 0x3}, + {.rx = 0x3}, + {.rx = 0x3}, }; +/* + * The tx mask indicates which channel(s) contains output IV-sense data and + * others should set to Hi-Z. Here we get the channel number from codec's ACPI + * device property "maxim,vmon-slot-no" and "maxim,imon-slot-no" to generate the + * mask. Refer to the max98373_slot_config() function in max98373.c codec driver. + */ +static unsigned int max_98373_get_tx_mask(struct device *dev) +{ + int vmon_slot; + int imon_slot; + + if (device_property_read_u32(dev, "maxim,vmon-slot-no", &vmon_slot)) + vmon_slot = 0; + + if (device_property_read_u32(dev, "maxim,imon-slot-no", &imon_slot)) + imon_slot = 1; + + dev_dbg(dev, "vmon_slot %d imon_slot %d\n", vmon_slot, imon_slot); + + return (0x1 << vmon_slot) | (0x1 << imon_slot); +} + static int max_98373_hw_params(struct snd_pcm_substream *substream, struct snd_pcm_hw_params *params) { @@ -98,6 +115,8 @@ static int max_98373_hw_params(struct snd_pcm_substream *substream, struct snd_soc_dai *codec_dai; int i; int tdm_slots; + unsigned int tx_mask; + unsigned int tx_mask_used = 0x0; int ret = 0; for_each_rtd_codec_dais(rtd, i, codec_dai) { @@ -117,13 +136,26 @@ static int max_98373_hw_params(struct snd_pcm_substream *substream, return -EINVAL; } + /* get the tx mask from ACPI device properties */ + tx_mask = max_98373_get_tx_mask(codec_dai->dev); + if (!tx_mask) + return -EINVAL; + + if (tx_mask & tx_mask_used) { + dev_err(codec_dai->dev, "invalid tx mask 0x%x, used 0x%x\n", + tx_mask, tx_mask_used); + return -EINVAL; + } + + tx_mask_used |= tx_mask; + /* * check if tdm slot number is too small for channel * allocation */ - if (fls(max_98373_tdm_mask[i].tx) > tdm_slots) { + if (fls(tx_mask) > tdm_slots) { dev_err(codec_dai->dev, "slot mismatch, tx %d slots %d\n", - fls(max_98373_tdm_mask[i].tx), tdm_slots); + fls(tx_mask), tdm_slots); return -EINVAL; } @@ -134,12 +166,10 @@ static int max_98373_hw_params(struct snd_pcm_substream *substream, } dev_dbg(codec_dai->dev, "set tdm slot: tx 0x%x rx 0x%x slots %d width %d\n", - max_98373_tdm_mask[i].tx, - max_98373_tdm_mask[i].rx, + tx_mask, max_98373_tdm_mask[i].rx, tdm_slots, params_width(params)); - ret = snd_soc_dai_set_tdm_slot(codec_dai, - max_98373_tdm_mask[i].tx, + ret = snd_soc_dai_set_tdm_slot(codec_dai, tx_mask, max_98373_tdm_mask[i].rx, tdm_slots, params_width(params)); From patchwork Mon Jun 24 12:11:18 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Pierre-Louis Bossart X-Patchwork-Id: 807065 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id AC829C2BD05 for ; Mon, 24 Jun 2024 12:13:13 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id E011E82A; Mon, 24 Jun 2024 14:13:01 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz E011E82A DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1719231191; bh=E4Fl9zHfo9CGU+x5houj6BkjHZoBUCL5ihfYUxwUujU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=UflcM7yDhVWm9Ugbrt7nR05NBV+L5mAMHtiJl8K5LixFShGYPq21z629EGjOoC5TB Q6ykFR3+8yS2Zb//QFsHZPgZ9a6gqkDzJoekdIwI7TDFFSkxJ7w3oH+O3seKN60npp 7gAMspdC/uzzm0fv7yWfN2YtPtE5PPSMK7hiQrL0= Received: by alsa1.perex.cz (Postfix, from userid 50401) id 98BA3F80620; Mon, 24 Jun 2024 14:11:55 +0200 (CEST) Received: from mailman-core.alsa-project.org (mailman-core.alsa-project.org [10.254.200.10]) by alsa1.perex.cz (Postfix) with ESMTP id 0F360F80637; Mon, 24 Jun 2024 14:11:55 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 87394F80423; Mon, 24 Jun 2024 14:11:47 +0200 (CEST) Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 6E339F80154 for ; Mon, 24 Jun 2024 14:11:42 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 6E339F80154 Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key, unprotected) header.d=intel.com header.i=@intel.com header.a=rsa-sha256 header.s=Intel header.b=cPgUye1N DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1719231103; x=1750767103; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=E4Fl9zHfo9CGU+x5houj6BkjHZoBUCL5ihfYUxwUujU=; b=cPgUye1NS5ILYtQ13DMfSSaQhAZ86rJDXN5GoRwU0WUCNzsBNuu9hJ4f bO0Ztx9Lp2DPdipQ4xCxwfm5IhGJ3UlzCBbZjAn3LubEu3pvZmfR9RIpR KeV6QtO00MQ/FmrEVuJnubUbjcu1F1wVwOuhfkXFDC62Ja8TbFug1vybb bJDiz0lmAGCxrCu8pCfIXKikiAZbWWFSFJa3gbvG1SpB9KHgax6eAIVYG ajX0lKz/JDHWAYfNw/J0AQm4eXU/Crzxr33nuiIC708fivwtpU7GkEF+B tncakUrb/nrcrwTK1KTx+IEaJMBWCm9pkr8jl/8JPxkHZz2Gl8yU3lMzE Q==; X-CSE-ConnectionGUID: 5CvsYMEKRTiZxlt3KWGj/w== X-CSE-MsgGUID: UfNM8TlIRymbqJCtmKFa/Q== X-IronPort-AV: E=McAfee;i="6700,10204,11112"; a="15887550" X-IronPort-AV: E=Sophos;i="6.08,261,1712646000"; d="scan'208";a="15887550" Received: from fmviesa006.fm.intel.com ([10.60.135.146]) by fmvoesa112.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 Jun 2024 05:11:40 -0700 X-CSE-ConnectionGUID: 91UDQNYqQ8musUgYCZJfmA== X-CSE-MsgGUID: y9Wh9RELQNuqNqAcb2zHew== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,261,1712646000"; d="scan'208";a="43091219" Received: from ksztyber-mobl2.ger.corp.intel.com (HELO pbossart-mobl6.intel.com) ([10.245.246.230]) by fmviesa006-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 Jun 2024 05:11:38 -0700 From: Pierre-Louis Bossart To: linux-sound@vger.kernel.org Cc: alsa-devel@alsa-project.org, tiwai@suse.de, broonie@kernel.org, Pierre-Louis Bossart , =?utf-8?q?P?= =?utf-8?q?=C3=A9ter_Ujfalusi?= , Bard Liao Subject: [PATCH 3/4] ASoC: Intel: sof_sdw: add quirk for Dell SKU 0B8C Date: Mon, 24 Jun 2024 14:11:18 +0200 Message-ID: <20240624121119.91552-4-pierre-louis.bossart@linux.intel.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240624121119.91552-1-pierre-louis.bossart@linux.intel.com> References: <20240624121119.91552-1-pierre-louis.bossart@linux.intel.com> MIME-Version: 1.0 Message-ID-Hash: ZXNFAMN77Y4NGDPD2UFDVUJYDY6UW3XT X-Message-ID-Hash: ZXNFAMN77Y4NGDPD2UFDVUJYDY6UW3XT X-MailFrom: pierre-louis.bossart@linux.intel.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-alsa-devel.alsa-project.org-0; header-match-alsa-devel.alsa-project.org-1; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.9 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Jack detection needs to rely on JD2, as most other Dell AlderLake-based devices. Closes: https://github.com/thesofproject/linux/issues/5021 Signed-off-by: Pierre-Louis Bossart Reviewed-by: Péter Ujfalusi Reviewed-by: Bard Liao --- sound/soc/intel/boards/sof_sdw.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/sound/soc/intel/boards/sof_sdw.c b/sound/soc/intel/boards/sof_sdw.c index 89b92a061489..e94849b84a6b 100644 --- a/sound/soc/intel/boards/sof_sdw.c +++ b/sound/soc/intel/boards/sof_sdw.c @@ -406,6 +406,15 @@ static const struct dmi_system_id sof_sdw_quirk_table[] = { /* No Jack */ .driver_data = (void *)SOF_SDW_TGL_HDMI, }, + { + .callback = sof_sdw_quirk_cb, + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc"), + DMI_EXACT_MATCH(DMI_PRODUCT_SKU, "0B8C"), + }, + .driver_data = (void *)(SOF_SDW_TGL_HDMI | + RT711_JD2), + }, { .callback = sof_sdw_quirk_cb, .matches = { From patchwork Mon Jun 24 12:11:19 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierre-Louis Bossart X-Patchwork-Id: 807296 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id CBD2FC2BD05 for ; Mon, 24 Jun 2024 12:13:30 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id E4A88D8; Mon, 24 Jun 2024 14:13:18 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz E4A88D8 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1719231208; bh=Dp+m3q2E7PgVso4OtZK0clbxLP/VF/JVrzwZvIK4P+Y=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=ZnKvFj6N3FyNQ7o3aBgC0xW9oTBfYh/w7jOB/Aw0Hniv7rOdwqOrhJ+h2WJpVcjri CQU3vwU1MHM7kIvNUlIUzExOFv/sYCJSH1R0bgCMwj1oHe1FkLhD5pQtQQ/qOSh75g NkyRT2WBnDG6NBCVQwvJavE6vbtRs6c8VjkB+7Hs= Received: by alsa1.perex.cz (Postfix, from userid 50401) id ED652F80656; Mon, 24 Jun 2024 14:11:57 +0200 (CEST) Received: from mailman-core.alsa-project.org (mailman-core.alsa-project.org [10.254.200.10]) by alsa1.perex.cz (Postfix) with ESMTP id 4CF25F80677; Mon, 24 Jun 2024 14:11:57 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 2049DF805D4; Mon, 24 Jun 2024 14:11:48 +0200 (CEST) Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 9D5CFF804F2 for ; Mon, 24 Jun 2024 14:11:43 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 9D5CFF804F2 Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key, unprotected) header.d=intel.com header.i=@intel.com header.a=rsa-sha256 header.s=Intel header.b=RvZwUb/w DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1719231104; x=1750767104; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=Dp+m3q2E7PgVso4OtZK0clbxLP/VF/JVrzwZvIK4P+Y=; b=RvZwUb/wFjnOFzvtUQh4eVeobJp+B/YHehLf9c0/Oe5zdsP+5SeKYwE2 oebTAyBkTi/zAkb8TJ9bFCDXy6oOUzRZAGy2XHd5N57YRwz9GevAF+4f1 PPxBhXB/mCNF2LYd1O5yauas/6qcEjeIMirzi7vBGwkUA11lVPEOeqkdv olHBhNI0Sg3BEKm2zKxEKieeEHmq3OlkQKD+OiIMxZPRcMkFYOEkBSmE6 PXF4SD511Qn6d87GLqSeul+baCDgDlXMKl4lffdIBiZoezNNKAdGfNJF6 GdsiQoDnFcCzuKSRYrxkeYTt1dS21NpXtaFD6wjJ+KRSHbggk6YtE6sZh Q==; X-CSE-ConnectionGUID: 6R//XlsvTkmkUlVAw36w8Q== X-CSE-MsgGUID: 4ovad9m0RR6Hl7e8/MDNFQ== X-IronPort-AV: E=McAfee;i="6700,10204,11112"; a="15887557" X-IronPort-AV: E=Sophos;i="6.08,261,1712646000"; d="scan'208";a="15887557" Received: from fmviesa006.fm.intel.com ([10.60.135.146]) by fmvoesa112.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 Jun 2024 05:11:43 -0700 X-CSE-ConnectionGUID: rWcG9NItTY6ZNe9Rn61Y2Q== X-CSE-MsgGUID: alK3MkPFQUWog/MnBtxX3Q== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,261,1712646000"; d="scan'208";a="43091222" Received: from ksztyber-mobl2.ger.corp.intel.com (HELO pbossart-mobl6.intel.com) ([10.245.246.230]) by fmviesa006-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 Jun 2024 05:11:41 -0700 From: Pierre-Louis Bossart To: linux-sound@vger.kernel.org Cc: alsa-devel@alsa-project.org, tiwai@suse.de, broonie@kernel.org, Bard Liao , Pierre-Louis Bossart Subject: [PATCH 4/4] ASoC: Intel: sof_sdw: select PINCTRL_CS42L43 and SPI_CS42L43 Date: Mon, 24 Jun 2024 14:11:19 +0200 Message-ID: <20240624121119.91552-5-pierre-louis.bossart@linux.intel.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240624121119.91552-1-pierre-louis.bossart@linux.intel.com> References: <20240624121119.91552-1-pierre-louis.bossart@linux.intel.com> MIME-Version: 1.0 Message-ID-Hash: HH7CEET4Y4PMPZQ3DXAWFEI6YMDZUTCL X-Message-ID-Hash: HH7CEET4Y4PMPZQ3DXAWFEI6YMDZUTCL X-MailFrom: pierre-louis.bossart@linux.intel.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-alsa-devel.alsa-project.org-0; header-match-alsa-devel.alsa-project.org-1; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.9 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: Bard Liao Cs42l43 bridge mode needs the two configurations. Signed-off-by: Bard Liao Signed-off-by: Pierre-Louis Bossart --- sound/soc/intel/boards/Kconfig | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sound/soc/intel/boards/Kconfig b/sound/soc/intel/boards/Kconfig index 4e0586034de4..f1faa5dd2a4f 100644 --- a/sound/soc/intel/boards/Kconfig +++ b/sound/soc/intel/boards/Kconfig @@ -677,6 +677,8 @@ config SND_SOC_INTEL_SOUNDWIRE_SOF_MACH select SND_SOC_CS42L43_SDW select MFD_CS42L43 select MFD_CS42L43_SDW + select PINCTRL_CS42L43 + select SPI_CS42L43 select SND_SOC_CS35L56_SPI select SND_SOC_CS35L56_SDW select SND_SOC_DMIC