From patchwork Fri Jul 14 20:24:49 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: 120468 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:a6b2:0:b0:3e4:2afc:c1 with SMTP id c18csp2480928vqm; Fri, 14 Jul 2023 05:52:55 -0700 (PDT) X-Google-Smtp-Source: APBJJlE1DcNA/2h6OSi8DQPTO5SZ0JixdT44SQGDtOefCQmFbwgMAgsH8OWUpIJZu1pRgo05Akbs X-Received: by 2002:a17:90b:1c0e:b0:25d:eca9:1621 with SMTP id oc14-20020a17090b1c0e00b0025deca91621mr3130351pjb.6.1689339174889; Fri, 14 Jul 2023 05:52:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689339174; cv=none; d=google.com; s=arc-20160816; b=H8RBI8HlkHgNtyGGV4A4BJSjXdVcD2pLa9uhq/ohjSdPWqe1MpODx/WWYS6dE5l/yF /mR2o7C6ETZacUXxKSxVNNj/t/IUrLukfGLUpbtkQv1QlR0UF5hXUI7q+7pPqb/JA9V5 QC8fCIpQdHlNHwm6EouYAK21TTa9JTdRrjMbPk7d4MKiGHOZWhUkLNLiy0UKy7EAZH0x jzVYI49UHeKN8fH0TNUNFit72UrAUimJXo8wPz+maXY2ZK25Td7OlyzugFKAwJ45HGRd 0q92NHercKLkB8vB85M/xoi8kiqL/4mDu/Ykuxo8gNas0DFiZk/wGI/m6aOyRmy+svG1 YjTQ== 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=HnNraT+n59tWRuGhtPCCLta4t+AsCDQ/8UThe6XWFMA=; fh=iLu8mJV3L09dzJN6VXkKj+SRT/C9p8fR4gJYErWu4bc=; b=tiVtaJZcHsJqW5etx0p+FYBUbKHXWspINjub318ya9iJuL8kICz1LNFX3a96GFnQTf oC3KyXt/tv1UKiu5C4hpKxzbBatm7CfH1MVEU1pq8r4f/LGckEWMrXvP7sLrkbGXTm16 jrY2nqyz+jWf/5GjMxcNqmHdVdi9XkzRxXy7D652OYv84fUF/PGUlHtR36jkwRnJpTh3 joN53U8+B9aA1ZWGfN7iaoMvlCnunQ9QFCBBKyED99JEkB1v8vDh36uQZFDhhWsRm9t+ GzYHkZqHKlVJo2G7dLdOWXt6yCZ9mJZoK/qe6KiOJ1tjRtAYWxplVXRCj25BrEq9gKhh GosQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=Kk6KomRZ; 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 a21-20020a17090a481500b0026359084fd2si1167026pjh.69.2023.07.14.05.52.42; Fri, 14 Jul 2023 05:52:54 -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=Kk6KomRZ; 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 S235689AbjGNMYW (ORCPT + 99 others); Fri, 14 Jul 2023 08:24:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36390 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234925AbjGNMYP (ORCPT ); Fri, 14 Jul 2023 08:24:15 -0400 Received: from mga06.intel.com (mga06b.intel.com [134.134.136.31]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B46CA3A8E; Fri, 14 Jul 2023 05:24:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1689337442; x=1720873442; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=O2F310bFUrrtqJHibkMdzi90JDrvWOt0X9HXx8O2FCY=; b=Kk6KomRZYKGX6B0Ud968jSeEaIF+xC6Lfzuw106K6Qk8XqhPrNkLWG6J +AmOI+8QGeLNRdXsHD4wrpF88wxlB/+20e4deyTM3Qsvt+AlIkYZKEqZh 4ZtRbFtP4tSZjVY/TkQN2humuVeh6PwGl8EGaQHBgErUhfXn81ypoJ8hT LUZWCNgZeDaKdPcQYugR2XC6YRpkowqok/TcPkDY6d9XyXkGdCz40CsJJ VwfNXF0SFzle5QkIqSQMfTOGQEw0HPIi0HpwC/zuYSpvVKPXMKhFz4ZWD cvvmpvJz3Ljd97NiE3543zanT38+tLBPfBxmKNvYDMcaHwxCjYbNqSwg+ w==; X-IronPort-AV: E=McAfee;i="6600,9927,10770"; a="429225842" X-IronPort-AV: E=Sophos;i="6.01,205,1684825200"; d="scan'208";a="429225842" 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:02 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10770"; a="1053034912" X-IronPort-AV: E=Sophos;i="6.01,205,1684825200"; d="scan'208";a="1053034912" Received: from dev2 (HELO DEV2.igk.intel.com) ([10.237.148.94]) by fmsmga005.fm.intel.com with ESMTP; 14 Jul 2023 05:23:59 -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 07/15] ALSA: hda/i915: Use global PCI match macro Date: Fri, 14 Jul 2023 22:24:49 +0200 Message-Id: <20230714202457.423866-8-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: 1771399887600022390 X-GMAIL-MSGID: 1771400514509342108 Instead of using local macro to match PCI device, use global one. Reviewed-by: Andy Shevchenko Signed-off-by: Amadeusz Sławiński --- sound/hda/hdac_i915.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/sound/hda/hdac_i915.c b/sound/hda/hdac_i915.c index 161a9711cd63..2a451ff4fe6a 100644 --- a/sound/hda/hdac_i915.c +++ b/sound/hda/hdac_i915.c @@ -11,11 +11,6 @@ #include #include -#define IS_HSW_CONTROLLER(pci) (((pci)->device == 0x0a0c) || \ - ((pci)->device == 0x0c0c) || \ - ((pci)->device == 0x0d0c) || \ - ((pci)->device == 0x160c)) - /** * snd_hdac_i915_set_bclk - Reprogram BCLK for HSW/BDW * @bus: HDA core bus @@ -39,7 +34,7 @@ void snd_hdac_i915_set_bclk(struct hdac_bus *bus) if (!acomp || !acomp->ops || !acomp->ops->get_cdclk_freq) return; /* only for i915 binding */ - if (!IS_HSW_CONTROLLER(pci)) + if (!HDA_CONTROLLER_IS_HSW(pci)) return; /* only HSW/BDW */ cdclk_freq = acomp->ops->get_cdclk_freq(acomp->dev);