Message ID | 20230711125726.3509391-11-amadeuszx.slawinski@linux.intel.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:a6b2:0:b0:3e4:2afc:c1 with SMTP id c18csp485582vqm; Tue, 11 Jul 2023 06:38:33 -0700 (PDT) X-Google-Smtp-Source: APBJJlFmmNFRBBmQZneAXxKlknaP8cpHmHoYihr/E6O/uec45RqzmiE65kwhMzHfA/q9VFHWygtP X-Received: by 2002:a17:902:f551:b0:1b8:b382:f6be with SMTP id h17-20020a170902f55100b001b8b382f6bemr13843901plf.6.1689082713119; Tue, 11 Jul 2023 06:38:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689082713; cv=none; d=google.com; s=arc-20160816; b=ck+R3r5FpRzIHwYBF8AG/Sgo0VNVceursu9JqynC29joNW2SDzBLqI2/c+wuvc386C MhFyLRmPzQRrGuXCWhafmM9G+hvIw6Ayey5KXAmkIbM4huvSxBREZemZ0buVUgn6q8mJ 0sjBDQ1ddt2B96Kx8CuUP9eHYOH38lu9c2geZrbqYHvE0vAXf2eB/Dg3jvB8H/GoijAn w6DUKSkiID/XmZYkuf31wb8+ZQIPeArsXqVhlTWnu+C3uYFPvu6FEVZeXW844OL/wM4j QMfzPOepx36nnlgLeSdsWO84GY3/SReBmadOJZ8i93NPNB1Sn1AoiZvVtT1f/YsuFN0W yCIg== 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=bBvprODdVsEu620g1ei5Clab8hOtIcQu1LuNixi/Yh0=; fh=sKxO7Xj+YIOQJw2gBVYevujm0+5GA4/lF0Hs7SAhyQ0=; b=zpSIsZnvQwhCg2vs9bhtZwb+WIsdzZjiy/CIRUESDMSL4tXSfayxANabRHRcwyj5JG V38F/wB+DqU2/y4QMm/vQTaGLExA5lJ3w9ThT82qA1wndA62wjJQ1L67ygru0OeAJx+7 OA5es2Ns/VmQarz/DrGrBMvzbxtz56INvLkMtCb9aFKgeV2mC4rBiLYbJmIOWpasJnD7 5sGB9lMDsUlNMkjj9EuMeH1tYm5FW8DzxYB73m5a5YicrpRoWAjPgRQJyeLjMkV+Iv4I 48r+8iYEd7YLyQ8xjg2HS6qQCxCK3pD9VxtZ+I0cmnrJfp5QvI2uksy/I8IKK2dDQAb3 eTZA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=B84CQvdJ; 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 b5-20020a170902650500b001b8805f98e9si1591277plk.452.2023.07.11.06.38.19; Tue, 11 Jul 2023 06:38:33 -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=B84CQvdJ; 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 S232907AbjGKM7S (ORCPT <rfc822;gnulinuxfreebsd@gmail.com> + 99 others); Tue, 11 Jul 2023 08:59:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58938 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232837AbjGKM66 (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Tue, 11 Jul 2023 08:58:58 -0400 Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3540A19A1; Tue, 11 Jul 2023 05:58:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1689080323; x=1720616323; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=jV1GIWokmNHIgBtvVxwWSRd15jG/A88s8g/lUsd9Z1Q=; b=B84CQvdJu23NNGyyGvWbEFdfolI0ZagFPjmPhFxQ2D7c68XhcY/+AY1v CaD5EUadbNtNRAWGX9oVOYBIem8IlIRbziz6P5n+Mn64cTmTXgcLJagCf khSY70GxB1q7jFtjz56KJx1AG14hXQKyepP1EQsPyJJo//goAbHpXHUK4 Yg6dmMsZbuhgvTbec/YYZGO4weKCaGKXiF3yWrOTummQZb0Zme66ZUZMq 2UflnRv3uXJa0/A7vz9YablBzJqU0IATVbHPLP0h32LTR0zn0RFH1kTia b2qJSOj05Z2s+MqpPmp+gHe/rounQxKrGrlo/sne9YeUzifMUT3u5RUFI A==; X-IronPort-AV: E=McAfee;i="6600,9927,10768"; a="367187518" X-IronPort-AV: E=Sophos;i="6.01,196,1684825200"; d="scan'208";a="367187518" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Jul 2023 05:57:35 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10768"; a="834666761" X-IronPort-AV: E=Sophos;i="6.01,196,1684825200"; d="scan'208";a="834666761" Received: from dev2 (HELO DEV2.igk.intel.com) ([10.237.148.94]) by fmsmga002.fm.intel.com with ESMTP; 11 Jul 2023 05:57:32 -0700 From: =?utf-8?q?Amadeusz_S=C5=82awi=C5=84ski?= <amadeuszx.slawinski@linux.intel.com> To: Bjorn Helgaas <bhelgaas@google.com>, Mark Brown <broonie@kernel.org>, Takashi Iwai <tiwai@suse.com> Cc: alsa-devel@alsa-project.org, linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, Cezary Rojewski <cezary.rojewski@intel.com>, Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>, Kai Vehmanen <kai.vehmanen@linux.intel.com>, Andy Shevchenko <andriy.shevchenko@intel.com>, Hans de Goede <hdegoede@redhat.com>, =?utf-8?q?Amadeusz_S=C5=82awi=C5=84ski?= <amadeuszx.slawinski@linux.intel.com> Subject: [PATCH 10/13] ASoC: Intel: avs: Convert to PCI device IDs defines Date: Tue, 11 Jul 2023 14:57:23 +0200 Message-Id: <20230711125726.3509391-11-amadeuszx.slawinski@linux.intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230711125726.3509391-1-amadeuszx.slawinski@linux.intel.com> References: <20230711125726.3509391-1-amadeuszx.slawinski@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,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: 1771130852398277377 X-GMAIL-MSGID: 1771131595364639357 |
Series |
PCI: Define Intel PCI IDs and use them in drivers
|
|
Commit Message
Amadeusz Sławiński
July 11, 2023, 12:57 p.m. UTC
Use PCI device IDs from pci_ids.h header. Adjust AVS_MACH_ENTRY() macro, so device ID can be provided in short form. Acked-by: Mark Brown <broonie@kernel.org> Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> --- sound/soc/intel/avs/board_selection.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-)
Comments
On Tue, Jul 11, 2023 at 02:57:23PM +0200, Amadeusz Sławiński wrote: > Use PCI device IDs from pci_ids.h header. Adjust AVS_MACH_ENTRY() macro, > so device ID can be provided in short form. FWIW, Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> > Acked-by: Mark Brown <broonie@kernel.org> > Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> > --- > sound/soc/intel/avs/board_selection.c | 10 +++++----- > 1 file changed, 5 insertions(+), 5 deletions(-) > > diff --git a/sound/soc/intel/avs/board_selection.c b/sound/soc/intel/avs/board_selection.c > index 60f8fb0bff95..b32e02940e30 100644 > --- a/sound/soc/intel/avs/board_selection.c > +++ b/sound/soc/intel/avs/board_selection.c > @@ -263,14 +263,14 @@ struct avs_acpi_boards { > }; > > #define AVS_MACH_ENTRY(_id, _mach) \ > - { .id = (_id), .machs = (_mach), } > + { .id = PCI_DEVICE_ID_INTEL_##_id, .machs = (_mach), } > > /* supported I2S boards per platform */ > static const struct avs_acpi_boards i2s_boards[] = { > - AVS_MACH_ENTRY(0x9d70, avs_skl_i2s_machines), /* SKL */ > - AVS_MACH_ENTRY(0x9d71, avs_kbl_i2s_machines), /* KBL */ > - AVS_MACH_ENTRY(0x5a98, avs_apl_i2s_machines), /* APL */ > - AVS_MACH_ENTRY(0x3198, avs_gml_i2s_machines), /* GML */ > + AVS_MACH_ENTRY(HDA_SKL_LP, avs_skl_i2s_machines), > + AVS_MACH_ENTRY(HDA_KBL_LP, avs_kbl_i2s_machines), > + AVS_MACH_ENTRY(HDA_APL, avs_apl_i2s_machines), > + AVS_MACH_ENTRY(HDA_GML, avs_gml_i2s_machines), Maybe sort them by name? > {}, > }; > > -- > 2.34.1 >
On 7/11/2023 4:09 PM, Andy Shevchenko wrote: > On Tue, Jul 11, 2023 at 02:57:23PM +0200, Amadeusz Sławiński wrote: >> Use PCI device IDs from pci_ids.h header. Adjust AVS_MACH_ENTRY() macro, >> so device ID can be provided in short form. > > FWIW, > Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> > >> Acked-by: Mark Brown <broonie@kernel.org> >> Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> >> --- >> sound/soc/intel/avs/board_selection.c | 10 +++++----- >> 1 file changed, 5 insertions(+), 5 deletions(-) >> >> diff --git a/sound/soc/intel/avs/board_selection.c b/sound/soc/intel/avs/board_selection.c >> index 60f8fb0bff95..b32e02940e30 100644 >> --- a/sound/soc/intel/avs/board_selection.c >> +++ b/sound/soc/intel/avs/board_selection.c >> @@ -263,14 +263,14 @@ struct avs_acpi_boards { >> }; >> >> #define AVS_MACH_ENTRY(_id, _mach) \ >> - { .id = (_id), .machs = (_mach), } >> + { .id = PCI_DEVICE_ID_INTEL_##_id, .machs = (_mach), } >> >> /* supported I2S boards per platform */ >> static const struct avs_acpi_boards i2s_boards[] = { >> - AVS_MACH_ENTRY(0x9d70, avs_skl_i2s_machines), /* SKL */ >> - AVS_MACH_ENTRY(0x9d71, avs_kbl_i2s_machines), /* KBL */ >> - AVS_MACH_ENTRY(0x5a98, avs_apl_i2s_machines), /* APL */ >> - AVS_MACH_ENTRY(0x3198, avs_gml_i2s_machines), /* GML */ >> + AVS_MACH_ENTRY(HDA_SKL_LP, avs_skl_i2s_machines), >> + AVS_MACH_ENTRY(HDA_KBL_LP, avs_kbl_i2s_machines), >> + AVS_MACH_ENTRY(HDA_APL, avs_apl_i2s_machines), >> + AVS_MACH_ENTRY(HDA_GML, avs_gml_i2s_machines), > > Maybe sort them by name? They are sorted by generation.
diff --git a/sound/soc/intel/avs/board_selection.c b/sound/soc/intel/avs/board_selection.c index 60f8fb0bff95..b32e02940e30 100644 --- a/sound/soc/intel/avs/board_selection.c +++ b/sound/soc/intel/avs/board_selection.c @@ -263,14 +263,14 @@ struct avs_acpi_boards { }; #define AVS_MACH_ENTRY(_id, _mach) \ - { .id = (_id), .machs = (_mach), } + { .id = PCI_DEVICE_ID_INTEL_##_id, .machs = (_mach), } /* supported I2S boards per platform */ static const struct avs_acpi_boards i2s_boards[] = { - AVS_MACH_ENTRY(0x9d70, avs_skl_i2s_machines), /* SKL */ - AVS_MACH_ENTRY(0x9d71, avs_kbl_i2s_machines), /* KBL */ - AVS_MACH_ENTRY(0x5a98, avs_apl_i2s_machines), /* APL */ - AVS_MACH_ENTRY(0x3198, avs_gml_i2s_machines), /* GML */ + AVS_MACH_ENTRY(HDA_SKL_LP, avs_skl_i2s_machines), + AVS_MACH_ENTRY(HDA_KBL_LP, avs_kbl_i2s_machines), + AVS_MACH_ENTRY(HDA_APL, avs_apl_i2s_machines), + AVS_MACH_ENTRY(HDA_GML, avs_gml_i2s_machines), {}, };