From patchwork Fri Jul 14 20:24:50 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Amadeusz_S=C5=82awi=C5=84ski?= X-Patchwork-Id: 120463 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:a6b2:0:b0:3e4:2afc:c1 with SMTP id c18csp2476562vqm; Fri, 14 Jul 2023 05:44:00 -0700 (PDT) X-Google-Smtp-Source: APBJJlH7DeTZBBfodv4DMX3a+jcc3nKe2o7WO3ZWwWpBgTkqrZmlAnd6HRSWGNjY2bXg1dr3OxyH X-Received: by 2002:a05:6a00:2e14:b0:67a:8f2a:2cb2 with SMTP id fc20-20020a056a002e1400b0067a8f2a2cb2mr4685111pfb.20.1689338640596; Fri, 14 Jul 2023 05:44:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689338640; cv=none; d=google.com; s=arc-20160816; b=nPzLMAVe8v9mDwDLXPKV9fOkHpAN8TIs0GjKKWS0Jlz11ynzhrAqc/5EDyCZy9Kluy XYQCeXArJWKpTiNx7bEV+i/4MrJN+wF9hoYAcPwkEt8WVko7HliFT5wL62wvpDZkqZLE npOjH4U8ySmEOsl3ox76on8SkrVXg+CtbUddqJsgMU57KxNwe1kquH1bIfqmapy5UnaW 0C0pGILAL5Hm9GHdcuuVPjWL+njUB6cJh268enN4XF3vdZiLIO0/++G6jSDLqweMQRr5 DIhuk+GTTpyUTqJCyy4VcOXWZcksPA9eflLUgA0VnXEVWOV0s4uxdqqOscc3LeeXGjtA /Lhw== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=BDa1klv7tlfef/4uZTkHMc7Hm7ifysjHxnI3LxlnhSI=; fh=iLu8mJV3L09dzJN6VXkKj+SRT/C9p8fR4gJYErWu4bc=; b=WMUtpntDyz9PPJRJIYuNQSH65DcJW6W9c88InvgXCrM5S8wX+5DvYys4fLCNHdwY5C 3P9buQdMyNGB6ldNulBaLh/uxukeAv68VTeEQ3dkvdVnSs1KYzPNRkJCt4D5jS/chrrq 1pLnLD1f5BK79ze1scNKHBx5CE4d0xcPBF5mydYaQl5uyCHVjTDZc6YSumDTxzlSpEiy i1Dsd6OhM30uNkVs9iHKvqK65mG2vTsOsoKvEn4voKi+zixXuOcxOsjkF8A759NSU4Oi qMB1lYov1ChaZgSJg6/y801V6B+RWA6Z1djDZ58XZ8CkEY1f24P1Ng6tlpmojIc2O0K5 VkLw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=j8zYUjTg; 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 a5-20020a056a000c8500b006689f8a9047si1730341pfv.125.2023.07.14.05.43.47; Fri, 14 Jul 2023 05:44:00 -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=j8zYUjTg; 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 S235856AbjGNMYg (ORCPT + 99 others); Fri, 14 Jul 2023 08:24:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36500 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235775AbjGNMYX (ORCPT ); Fri, 14 Jul 2023 08:24:23 -0400 Received: from mga06.intel.com (mga06b.intel.com [134.134.136.31]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7CBFD35A1; Fri, 14 Jul 2023 05:24:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1689337445; x=1720873445; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=PBebvDAwGl69rhzohAaS7jNgIdCEGCL7ad9NEzcoAGA=; b=j8zYUjTgMjovl6YaX31IthybZHeqswBmtq2yuWNu7VxskONtD2upiJfM mQerXzlL+mt/X1DSNCYrC7uzWv54Q2jndJNL8EhO4VDG98i4H1dTxLhv8 gZGI7hxN8jyrS0EMMrDN847Qh+eXP53AlFKQSHSNg68fsIdzwXNkt8+4M uEANX0m4BT3NyjuAhRSBBiJX7BqCUobFIq3UlMN2EZqEiKMC4qKwNAJ8r oDe7exrPvAXTETJs5FaFOpFKo24OHWLrqhLwCNNhwOEg1ZU/KoXB8txoD pVYLl1ldgkRJ2MMXMnKBtaLBoz9+8rhgpCS1fXWju25Y2gkNG0sDM3Slh Q==; X-IronPort-AV: E=McAfee;i="6600,9927,10770"; a="429225856" X-IronPort-AV: E=Sophos;i="6.01,205,1684825200"; d="scan'208";a="429225856" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Jul 2023 05:24:05 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10770"; a="1053034934" X-IronPort-AV: E=Sophos;i="6.01,205,1684825200"; d="scan'208";a="1053034934" Received: from dev2 (HELO DEV2.igk.intel.com) ([10.237.148.94]) by fmsmga005.fm.intel.com with ESMTP; 14 Jul 2023 05:24:02 -0700 From: =?utf-8?q?Amadeusz_S=C5=82awi=C5=84ski?= To: Bjorn Helgaas , Mark Brown , Takashi Iwai Cc: alsa-devel@alsa-project.org, linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, Cezary Rojewski , Pierre-Louis Bossart , Kai Vehmanen , Andy Shevchenko , Hans de Goede , =?utf-8?q?Amadeusz_S=C5=82awi=C5=84ski?= , Andy Shevchenko Subject: [PATCH v3 08/15] ASoC: Intel: Skylake: Use global PCI match macro Date: Fri, 14 Jul 2023 22:24:50 +0200 Message-Id: <20230714202457.423866-9-amadeuszx.slawinski@linux.intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230714202457.423866-1-amadeuszx.slawinski@linux.intel.com> References: <20230714202457.423866-1-amadeuszx.slawinski@linux.intel.com> MIME-Version: 1.0 X-Spam-Status: No, score=-0.1 required=5.0 tests=BAYES_00,DATE_IN_FUTURE_06_12, DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF, RCVD_IN_DNSWL_BLOCKED,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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1771399954485732803 X-GMAIL-MSGID: 1771399954485732803 Instead of using local macro to match PCI device, use global one. As Apollolake is Broxton-P successor that made it to the market, be precise and use APL shortcut. IS_CFL() macro is dropped as it is unused. Acked-by: Mark Brown Reviewed-by: Andy Shevchenko Signed-off-by: Amadeusz Sławiński --- include/sound/hda_codec.h | 3 --- sound/soc/intel/skylake/skl-pcm.c | 3 ++- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/include/sound/hda_codec.h b/include/sound/hda_codec.h index bbb7805e85d8..5497dc9c396a 100644 --- a/include/sound/hda_codec.h +++ b/include/sound/hda_codec.h @@ -18,9 +18,6 @@ #include #include -#define IS_BXT(pci) ((pci)->vendor == 0x8086 && (pci)->device == 0x5a98) -#define IS_CFL(pci) ((pci)->vendor == 0x8086 && (pci)->device == 0xa348) - /* * Structures */ diff --git a/sound/soc/intel/skylake/skl-pcm.c b/sound/soc/intel/skylake/skl-pcm.c index a4209d88b0c6..ac3dc8c63c26 100644 --- a/sound/soc/intel/skylake/skl-pcm.c +++ b/sound/soc/intel/skylake/skl-pcm.c @@ -13,6 +13,7 @@ #include #include #include +#include #include #include #include "skl.h" @@ -152,7 +153,7 @@ int skl_pcm_host_dma_prepare(struct device *dev, struct skl_pipe_params *params) * The recommended SDxFMT programming sequence for BXT * platforms is to couple the stream before writing the format */ - if (IS_BXT(skl->pci)) { + if (HDA_CONTROLLER_IS_APL(skl->pci)) { snd_hdac_ext_stream_decouple(bus, stream, false); err = snd_hdac_stream_setup(hdac_stream(stream)); snd_hdac_ext_stream_decouple(bus, stream, true);