Message ID | 20230726140848.2267568-1-brent.lu@intel.com |
---|---|
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:a985:0:b0:3e4:2afc:c1 with SMTP id t5csp213419vqo; Tue, 25 Jul 2023 23:39:51 -0700 (PDT) X-Google-Smtp-Source: APBJJlGvQdhg0zvPbYbvpvuHYMDcrMXWgBW+rkI9lVED+Mr5KO5SSBZc9dVjpX7Hm1TFIaFy1tpY X-Received: by 2002:a17:906:5183:b0:993:ea6b:edf6 with SMTP id y3-20020a170906518300b00993ea6bedf6mr910009ejk.0.1690353591493; Tue, 25 Jul 2023 23:39:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690353591; cv=none; d=google.com; s=arc-20160816; b=bmdcSwtPWA8zBmD5DkK68UTLppBotHo6zrOcIgOQcLSGRd1ygjQK0fv2Aluc6BhHlT F0rkelyYYmnlTTK0lkx4WuVc+QYJJl+9CdB4bCD0qbXINZSvXdHVjPpxS4OVR6qOOFYQ FJOJw5WBpuZ/BMQvDIMGyuE/9FvbZYvvd1Apw1JYiyzIX/g/CUvtylOrqLXv17k/wN7S aLBTk0iLgPvWpR6fvOYL4emHSQ0r3wJk62xmxExCic8iDWVomiH5SmShTb9lrNucsAKy GWfZSOx1DM9+hJKr7gt7KzXWO2WGyNdODVDbCybvupflEqqZAOlPZ2F/+Dc18zxoWfvt 6Ppg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=fSpROn9DU+0UNChvPEpYt7ZRPFEgqCj1WKea6/NwWdc=; fh=Lz5/hqROUpcBQKAp9YzBGY+SBeOpUnHmW51VPPw0uQw=; b=VluBPxSuwoxhuliG1AUvdsaiKuHs9JWY3bPXctvzwiz2lYPNRZ3/iN+Vg2jwHPMV+7 vOnBdsWI41tiW81cQksdlbYsD94qSm0KGGCv/JiPgYCKKGpQPZqZJvBGJtfvD2A2QJpg mpdIYaRjGcAHVEwcLK8j9U6xkGAcT1UdIpK5j44Mb4kUrtpwel6XFa4p+T/ZhW3mtxXN OwF8I1k9uHt0X08wfmfW4iN8+0f1MdhztH2xB5ls03sSthzk6Frhx/AR6UswpF+CG1T+ iL8Rk0zzjOMgtRMyZV0Hbu8Kid3bmi5/dW03U81andeJuRlldCC8K/+5jj7dyRnlk266 GVSg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=FUqkaIOL; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ks2-20020a170906f84200b0098cee0f8cfesi8802564ejb.969.2023.07.25.23.39.27; Tue, 25 Jul 2023 23:39:51 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=FUqkaIOL; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231912AbjGZGPV (ORCPT <rfc822;kloczko.tomasz@gmail.com> + 99 others); Wed, 26 Jul 2023 02:15:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46414 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231951AbjGZGPH (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Wed, 26 Jul 2023 02:15:07 -0400 Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F177410B for <linux-kernel@vger.kernel.org>; Tue, 25 Jul 2023 23:14:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1690352099; x=1721888099; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=js5eLjuH8dKH2vHgVoNL1hwwICaDvEgaMk24LXytU+c=; b=FUqkaIOLDSVVPm0P0sG14/AmeZH7JrzolAZ/YNOoz3NGU59bnlt75cRU szfymFtZElkKYRxJ5di/SlyY4LRLpy6aUZVZfJLE8tqsh63c5rzPZIzPs HF/u6Y5e8c1lvTNSM3iMqzseol00660jmwNELu4WHYs7bL6bHNGw1A72o 1Wk8jhUTC2kBWLfobm6vdAcPWaZBGptoP+4e0NxAQinW+8mJjQMzlyuwE Q62DUbtoUUIy8M4qmnB3VuWL96R3ZeEyN5NOThLSUfmqBG1XJC6Y5CIs9 bsAQm9zXj0TG+teejWF2uRMy0iuY42L3WZnTcMX1Cfvlb6GIgtXipiCWw A==; X-IronPort-AV: E=McAfee;i="6600,9927,10782"; a="367950236" X-IronPort-AV: E=Sophos;i="6.01,231,1684825200"; d="scan'208";a="367950236" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Jul 2023 23:14:59 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10782"; a="703606278" X-IronPort-AV: E=Sophos;i="6.01,231,1684825200"; d="scan'208";a="703606278" Received: from brentlu-desktop.itwn.intel.com ([10.5.252.92]) by orsmga006.jf.intel.com with ESMTP; 25 Jul 2023 23:14:54 -0700 From: Brent Lu <brent.lu@intel.com> To: alsa-devel@alsa-project.org Cc: Cezary Rojewski <cezary.rojewski@intel.com>, Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>, Liam Girdwood <liam.r.girdwood@linux.intel.com>, Peter Ujfalusi <peter.ujfalusi@linux.intel.com>, Bard Liao <yung-chuan.liao@linux.intel.com>, Ranjani Sridharan <ranjani.sridharan@linux.intel.com>, Kai Vehmanen <kai.vehmanen@linux.intel.com>, Mark Brown <broonie@kernel.org>, Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>, Brent Lu <brent.lu@intel.com>, linux-kernel@vger.kernel.org, Ajye Huang <ajye_huang@compal.corp-partner.google.com>, Yong Zhi <yong.zhi@intel.com>, Terry Cheong <htcheong@chromium.org>, Uday M Bhat <uday.m.bhat@intel.com>, Mac Chiang <mac.chiang@intel.com>, "Dharageswari . R" <dharageswari.r@intel.com>, Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>, ye xingchen <ye.xingchen@zte.com.cn>, Andy Shevchenko <andriy.shevchenko@linux.intel.com> Subject: [PATCH v2 0/2] Intel: sof_rt5682: remove quirk flag Date: Wed, 26 Jul 2023 22:08:46 +0800 Message-Id: <20230726140848.2267568-1-brent.lu@intel.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,DATE_IN_FUTURE_06_12, DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1772464207456013164 X-GMAIL-MSGID: 1772464207456013164 |
Series |
Intel: sof_rt5682: remove quirk flag
|
|
Message
Brent Lu
July 26, 2023, 2:08 p.m. UTC
We add a helper function to detect amplifier number according to device instance in ACPI table so the SOF_MAX98390_TWEETER_SPEAKER_PRESENT flag and a dmi quirk for 4-amplifier configuration could be safely removed. Also refactor the max_98390_hw_params() function to use an array to handle the TDM parameter. Amplifier number detection and TDM parameter are tested on two Chromebooks. One with 2 MAX98390 and one with 4 MAX98390 amplifier. V2 Changes: - fix some typos in cover letter - use for_each_acpi_dev_match() macro to simplify the codec - use 'unsign int' for codec number variable Brent Lu (2): ASoC: Intel: maxim-common: get codec number from ACPI ASoC: Intel: sof_rt5682: remove SOF_MAX98390_TWEETER_SPEAKER_PRESENT flag sound/soc/intel/boards/sof_maxim_common.c | 171 +++++++++++++--------- sound/soc/intel/boards/sof_maxim_common.h | 21 ++- sound/soc/intel/boards/sof_rt5682.c | 37 +---- 3 files changed, 112 insertions(+), 117 deletions(-)