From patchwork Tue Feb 4 05:39:41 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bard Liao X-Patchwork-Id: 13958617 Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.10]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 22F181E7C3A for ; Tue, 4 Feb 2025 05:39:53 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.175.65.10 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738647595; cv=none; b=FahOXoV50EhJNKiVnNabNQRL9RNCVyV5sValx86hnFXTRkL6RSka3l+pDPERhi/OB3F3tg2Kw+7cJfVxVekd97xiHoRnAIEaSu6hV/fSPDkBSefHDjTzAL87FJ6LeiceN27W/u8Oug+vazW8WRVs4vdLtQX69OonNrD1jZWHcwE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738647595; c=relaxed/simple; bh=4qffLct1y6h2hVijnjdhzJIXVTTTLpp9zvXadDewTEc=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=B6NDkPzP0pqxVTnluAsQqFj/Kb/GCcKZxImWJZ1B0B0Qi4g/m+F//aSMnYrtBtemN1meDMdTkflURl2v2IfvBUIeLjF86mtGv95eFgC8V7TGvsRwfHBKI8UffvPfUIeuE4nLJTpP0XsjmRKPOah7eLvVHaVYcpZ9NW8rgL8s1N8= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=none smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=W8BwFgat; arc=none smtp.client-ip=198.175.65.10 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="W8BwFgat" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1738647594; x=1770183594; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=4qffLct1y6h2hVijnjdhzJIXVTTTLpp9zvXadDewTEc=; b=W8BwFgatnocYVlyw6jV/rpgzhMZNP0d+QTG6PlW4iCLolTrqQzRW2r3k Wv+jCAH0u1Yqze5PpzKSX+Ks3ikeDRJOF3TFkSldntacOE2aczzzs1uaJ 3K6DdYQRIjhSGywACCMA+CWm/pRUyB7nFzFhCUnf4oJKT8Pb7aSLUPA1D LjLNntp00ZM+E2zkATQaK9hxpq3UdB3lERnL8FJqp3e0b0i+9S4XIgTM3 6rwi9j7xL63xsJugo7X/PkoS4aNVpVJ47og6/JX8L0bo04PiWNxGlDzuy iA2xU4wgDWjHBtSLQBOLazI/3tg761kJLTZL/FHe76n1UORa/8Rpp53Hj Q==; X-CSE-ConnectionGUID: 0McEtC/xQPGLdBoW/uQw9g== X-CSE-MsgGUID: VD0tgfyUSfqj8xsaAGSxcA== X-IronPort-AV: E=McAfee;i="6700,10204,11335"; a="56590575" X-IronPort-AV: E=Sophos;i="6.13,257,1732608000"; d="scan'208";a="56590575" Received: from orviesa003.jf.intel.com ([10.64.159.143]) by orvoesa102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Feb 2025 21:39:53 -0800 X-CSE-ConnectionGUID: ORnkPxk9SKKWjISPp6fOgg== X-CSE-MsgGUID: //3nRUy5QIKl1tnhTRbAzg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.11,199,1725346800"; d="scan'208";a="115492007" Received: from iweiny-desk3.amr.corp.intel.com (HELO yungchua-desk.intel.com) ([10.124.223.111]) by ORVIESA003-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Feb 2025 21:39:52 -0800 From: Bard Liao To: broonie@kernel.org, tiwai@suse.de Cc: linux-sound@vger.kernel.org, pierre-louis.bossart@linux.dev, bard.liao@intel.com Subject: [PATCH 1/3] ASoC: Intel: sof_sdw: Add lookup of quirk using PCI subsystem ID Date: Tue, 4 Feb 2025 13:39:41 +0800 Message-ID: <20250204053943.93596-2-yung-chuan.liao@linux.intel.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20250204053943.93596-1-yung-chuan.liao@linux.intel.com> References: <20250204053943.93596-1-yung-chuan.liao@linux.intel.com> Precedence: bulk X-Mailing-List: linux-sound@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 From: Richard Fitzgerald Add lookup of PCI subsystem vendor:device ID to find a quirk. The subsystem ID (SSID) is part of the PCI specification to uniquely identify a particular system-specific implementation of a hardware device. Unlike DMI information, it identifies the sound hardware itself, rather than a specific model of PC. SSID can be more reliable and stable than DMI strings, and is preferred by some vendors as the way to identify the actual sound hardware. Signed-off-by: Richard Fitzgerald Reviewed-by: Liam Girdwood Signed-off-by: Bard Liao --- sound/soc/intel/boards/sof_sdw.c | 30 ++++++++++++++++++++++++------ 1 file changed, 24 insertions(+), 6 deletions(-) diff --git a/sound/soc/intel/boards/sof_sdw.c b/sound/soc/intel/boards/sof_sdw.c index b0d35fda7b17..381fae5943fe 100644 --- a/sound/soc/intel/boards/sof_sdw.c +++ b/sound/soc/intel/boards/sof_sdw.c @@ -13,6 +13,7 @@ #include #include #include +#include #include #include "sof_sdw_common.h" #include "../../codecs/rt711.h" @@ -751,6 +752,22 @@ static const struct dmi_system_id sof_sdw_quirk_table[] = { {} }; +static const struct snd_pci_quirk sof_sdw_ssid_quirk_table[] = { + {} +}; + +static void sof_sdw_check_ssid_quirk(const struct snd_soc_acpi_mach *mach) +{ + const struct snd_pci_quirk *quirk_entry; + + quirk_entry = snd_pci_quirk_lookup_id(mach->mach_params.subsystem_vendor, + mach->mach_params.subsystem_device, + sof_sdw_ssid_quirk_table); + + if (quirk_entry) + sof_sdw_quirk = quirk_entry->value; +} + static struct snd_soc_dai_link_component platform_component[] = { { /* name might be overridden during probe */ @@ -1278,6 +1295,13 @@ static int mc_probe(struct platform_device *pdev) snd_soc_card_set_drvdata(card, ctx); + if (mach->mach_params.subsystem_id_set) { + snd_soc_card_set_pci_ssid(card, + mach->mach_params.subsystem_vendor, + mach->mach_params.subsystem_device); + sof_sdw_check_ssid_quirk(mach); + } + dmi_check_system(sof_sdw_quirk_table); if (quirk_override != -1) { @@ -1293,12 +1317,6 @@ static int mc_probe(struct platform_device *pdev) for (i = 0; i < ctx->codec_info_list_count; i++) codec_info_list[i].amp_num = 0; - if (mach->mach_params.subsystem_id_set) { - snd_soc_card_set_pci_ssid(card, - mach->mach_params.subsystem_vendor, - mach->mach_params.subsystem_device); - } - ret = sof_card_dai_links_create(card); if (ret < 0) return ret; From patchwork Tue Feb 4 05:39:42 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bard Liao X-Patchwork-Id: 13958618 Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.10]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0AF8D1DE4C1 for ; Tue, 4 Feb 2025 05:39:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.175.65.10 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738647596; cv=none; b=XxzsEFmyYqNQhckEipqUVf3TRixkMa+GrDGHYmnI2ffwTWrBTj+lFabcleqLFSIqMPcvVNkcHYoFfm/ML0OrvPXH+D5ZQ6IqupMD3Gmg4aXlnXnGZiijGlMGxbccbKtwZyErSNxnOztCwq541GYCR+TMOtiB2Ap94XiXKIrzAL4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738647596; c=relaxed/simple; bh=X/cukQYC2KXWyOMbu7T3qboOnWBd0qUfGHJVJlYE0vw=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=XIhxZ1fhx4R/bQJu8NSZOu13IfPYkhyzpsa3pBou4TMeOh11DZfHN8wfIDTFw8tyoiEue22MReF5ENm0OfaUrhaiX/o0fNIoNH5FEmkoTWWuAFGxF1ZLaxuNFwTP9CQYUzeQEr6SNzKQHv3aEfRkyEBgN5auQcHofo4sWihY6SE= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=none smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=TiwNhp5O; arc=none smtp.client-ip=198.175.65.10 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="TiwNhp5O" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1738647595; x=1770183595; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=X/cukQYC2KXWyOMbu7T3qboOnWBd0qUfGHJVJlYE0vw=; b=TiwNhp5OKc9p03o4VUJbpH+cd1BXsM5H/GyQBnf1WJ438LRYB3mEeolo xP9Ip3lGoQjgl/49lTdgXdNh+7j+PXqJhWIB4FYQYzXHrD3cXRGmnSPtH ZJa2qasDiteQqWlp5G9MctsMiiS22MMnKcO+P9s+evKRcHYLyi7Buw3N7 QItMDTkVriBM1cxWAuClo4jB+6zorpRNk1oEGkn84XnPhHnv40cdYShsM rTuAlgVulfLkC4ISpVAZbVi/25l1eQVmsBU77ChTqRc+gvTAKXp+uo3eD PsNEDqZQhuzSgbBf7OWWEmI0oQItdd8edrAUBNZjghAuuK2gCGEs6USp+ Q==; X-CSE-ConnectionGUID: BR5g/PN9SOmmAI5BgFdChw== X-CSE-MsgGUID: LPoB2Th5SsSc6f58Lx0sKw== X-IronPort-AV: E=McAfee;i="6700,10204,11335"; a="56590580" X-IronPort-AV: E=Sophos;i="6.13,257,1732608000"; d="scan'208";a="56590580" Received: from orviesa003.jf.intel.com ([10.64.159.143]) by orvoesa102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Feb 2025 21:39:54 -0800 X-CSE-ConnectionGUID: nFdU4xdFRwK3rLYzci3AWA== X-CSE-MsgGUID: on/NUoF9SoqTn2YZdZixbA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.11,199,1725346800"; d="scan'208";a="115492011" Received: from iweiny-desk3.amr.corp.intel.com (HELO yungchua-desk.intel.com) ([10.124.223.111]) by ORVIESA003-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Feb 2025 21:39:53 -0800 From: Bard Liao To: broonie@kernel.org, tiwai@suse.de Cc: linux-sound@vger.kernel.org, pierre-louis.bossart@linux.dev, bard.liao@intel.com Subject: [PATCH 2/3] ASoC: Intel: sof_sdw: Add quirk for Asus Zenbook S14 Date: Tue, 4 Feb 2025 13:39:42 +0800 Message-ID: <20250204053943.93596-3-yung-chuan.liao@linux.intel.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20250204053943.93596-1-yung-chuan.liao@linux.intel.com> References: <20250204053943.93596-1-yung-chuan.liao@linux.intel.com> Precedence: bulk X-Mailing-List: linux-sound@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 From: Richard Fitzgerald Asus laptops with sound PCI subsystem ID 1043:1e13 have the DMICs connected to the host instead of the CS42L43 so need the SOC_SDW_CODEC_MIC quirk. Signed-off-by: Richard Fitzgerald Reviewed-by: Liam Girdwood Signed-off-by: Bard Liao --- sound/soc/intel/boards/sof_sdw.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sound/soc/intel/boards/sof_sdw.c b/sound/soc/intel/boards/sof_sdw.c index 381fae5943fe..683e15b459a1 100644 --- a/sound/soc/intel/boards/sof_sdw.c +++ b/sound/soc/intel/boards/sof_sdw.c @@ -753,6 +753,7 @@ static const struct dmi_system_id sof_sdw_quirk_table[] = { }; static const struct snd_pci_quirk sof_sdw_ssid_quirk_table[] = { + SND_PCI_QUIRK(0x1043, 0x1e13, "ASUS Zenbook S14", SOC_SDW_CODEC_MIC), {} }; From patchwork Tue Feb 4 05:39:43 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bard Liao X-Patchwork-Id: 13958619 Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.10]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 797051E7C3A for ; Tue, 4 Feb 2025 05:39:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.175.65.10 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738647598; cv=none; b=oIpFg4wwWStkrGW0yVlvJRJHiVvHfB3dVM0d/JKUaCIXMlUfYyq2KDEvg29HWZbRPiBF4qS2rUXSxZ6Y8Nu26TmH6d2uTxeZ7e3GGl54EqOtO1MaiBob+4/buLy7pQmpbpfMw+id6N+Mqvlb3Jknsah2/dL1L125sZ5kA9f8v5U= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738647598; c=relaxed/simple; bh=V68aFHKmJTEyNDmT0iG7Y2IokyW7sg28IsHKGtln5mk=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=T/PNzpOGo1dxnvvmU/cQ7YoLTiViQJ2fzV0UW0AvzONpYMfYPTwR5CA+qWUOTXHUMiVbiYcPCastd4BeeYvX5b4dMGNIXrX9gKEz6rh4ZVFLoXwe3Gxk4pXLZvB6MaEeW8a1CjpEVOuM7VKlDs/a97JJ7+/Jep3Sq5AYX4XWK1Q= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=none smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=VQBNM2YB; arc=none smtp.client-ip=198.175.65.10 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="VQBNM2YB" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1738647596; x=1770183596; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=V68aFHKmJTEyNDmT0iG7Y2IokyW7sg28IsHKGtln5mk=; b=VQBNM2YBvRL3w8kWjMzdxkh/MPtXBq9EU89YRYWjQgf92x9Bg8WWk51O fLCJ8fnZ/JwUTH/z59P8oy5oZhOIDYi8HQ/a1yEEE9v2dQeuaA8R6iCgX Rb06+B6AQqQApCqhZZCcOcXs2mIq8ZPwcqN2HTHga3BEvkG7JG1gFMCCs V4mnPuz5spWAFSFtDa1fRQW3+mtrbUWXGp4u4b1NUOjKdApaPAUZ/8Tj6 wBMeUBJFlmdHXwt3rFZ9Duuz3Nvf/DcmQq0Yzl2Bt1gtbvMqc7CUUL8O8 /0baA59ufCaaZj/xp7Mjn0k+qqBSm7esrtzX3P9yF+aoZlWscmVNMWoAZ w==; X-CSE-ConnectionGUID: CgHUDcy4Toq+EVC5epaAWw== X-CSE-MsgGUID: jn4SyYrRSK6yPUMdCDREGg== X-IronPort-AV: E=McAfee;i="6700,10204,11335"; a="56590586" X-IronPort-AV: E=Sophos;i="6.13,257,1732608000"; d="scan'208";a="56590586" Received: from orviesa003.jf.intel.com ([10.64.159.143]) by orvoesa102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Feb 2025 21:39:56 -0800 X-CSE-ConnectionGUID: ssZubloaS/isd08upbQk6Q== X-CSE-MsgGUID: p6RDvlAVTRSLCqI9glW0Og== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.11,199,1725346800"; d="scan'208";a="115492014" Received: from iweiny-desk3.amr.corp.intel.com (HELO yungchua-desk.intel.com) ([10.124.223.111]) by ORVIESA003-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Feb 2025 21:39:55 -0800 From: Bard Liao To: broonie@kernel.org, tiwai@suse.de Cc: linux-sound@vger.kernel.org, pierre-louis.bossart@linux.dev, bard.liao@intel.com Subject: [PATCH 3/3] ASoC: Intel: sof_sdw: Add support for Fatcat board with BT offload enabled in PTL platform Date: Tue, 4 Feb 2025 13:39:43 +0800 Message-ID: <20250204053943.93596-4-yung-chuan.liao@linux.intel.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20250204053943.93596-1-yung-chuan.liao@linux.intel.com> References: <20250204053943.93596-1-yung-chuan.liao@linux.intel.com> Precedence: bulk X-Mailing-List: linux-sound@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 From: Uday M Bhat This change adds an entry for fatcat boards in soundwire quirk table and also, enables BT offload for PTL RVP. Signed-off-by: Uday M Bhat Signed-off-by: Jairaj Arava Reviewed-by: Ranjani Sridharan Signed-off-by: Bard Liao --- sound/soc/intel/boards/sof_sdw.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/sound/soc/intel/boards/sof_sdw.c b/sound/soc/intel/boards/sof_sdw.c index 683e15b459a1..203b07d4d833 100644 --- a/sound/soc/intel/boards/sof_sdw.c +++ b/sound/soc/intel/boards/sof_sdw.c @@ -749,6 +749,16 @@ static const struct dmi_system_id sof_sdw_quirk_table[] = { }, .driver_data = (void *)(SOC_SDW_PCH_DMIC), }, + { + .callback = sof_sdw_quirk_cb, + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Google"), + DMI_MATCH(DMI_PRODUCT_NAME, "Fatcat"), + }, + .driver_data = (void *)(SOC_SDW_PCH_DMIC | + SOF_BT_OFFLOAD_SSP(2) | + SOF_SSP_BT_OFFLOAD_PRESENT), + }, {} };