Message ID | 20230628205135.517241-1-amadeuszx.slawinski@linux.intel.com |
---|---|
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp8913409vqr; Wed, 28 Jun 2023 06:10:33 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5LHH2n8p280fRke2TJnzTTo1go4k+UPcwXcpgzREy2lipmPcU6RKq8ISnS2ooQsK0hUlpl X-Received: by 2002:a17:906:51d9:b0:98d:7818:e51b with SMTP id v25-20020a17090651d900b0098d7818e51bmr14606551ejk.27.1687957833649; Wed, 28 Jun 2023 06:10:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687957833; cv=none; d=google.com; s=arc-20160816; b=ngJ6U2bzbdYkwGI62dt2rJ3C0Z/2KxLPjjJgUSRISJd7/+6Ip/0+LkaLC9+I4Rybam hBoqSNNGN1sOVNpOVs22I2jYYbR73iduBE5R1JgD+UCEBCt5Wj68HEouUjo7hPzu6I6b wtNomCWQZsTp3oJfgrLkC1RTE1GCepWjousxgn1bja10XDTlALjmM69hunBlz9qUolMV +/BIlJXK6cLrgGQBGWZLtptuSLdPVDyjgEQ4zX+HqMzXxklyNdXZGyAvvEac01mQyC9M JQbexMXwW2v8ItkW1K3xe/h6EWbbFxos4WLJqOWbQIMCrhdIWEYTRaLtxEHJOazgz4qG qv7w== 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=/rNp29PTO4bptIZhBUiQfFAI+gSqSDX0ylehR8YXXhI=; fh=4hmkLMGNpQ+PocmVypGauCnPZxjmrElQ8gsuUAuM8xE=; b=nXSq0kSKlo6Y+l+DgwuGRZZdY1y/gqqALSb79MTJMFoytgFEqbZGF0+Le8SGm4IgIn s7iWpTVH6RxYTu1dBfQ0Ax5/uLUrZqnpenoET4zzdrt2uyHq7gNdsnkvLOiwOzCfO528 xTlJ+fSsK+D9sIgrM4wlY+PxJelgfTPY8lzS/1Lfyn79MjwbD99uzCyRkb2b/0xPg9md vxqigixhJTj7Y6vfNGNdf/ZSipMx6SFcTAvBNgQRq5c0eaxlTxx/9zIPaAn8rticrUmy LEvQgp8GLm9KNgitYRKHGwq4l35145tmN67JcfFQgdGmWrQADRxtN8z9PD38yF8WDZja rCgQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=U4sNzAeJ; 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 z23-20020a1709064e1700b009827e17b069si5451560eju.1029.2023.06.28.06.10.09; Wed, 28 Jun 2023 06:10: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=U4sNzAeJ; 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 S230463AbjF1Muj (ORCPT <rfc822;adanhawthorn@gmail.com> + 99 others); Wed, 28 Jun 2023 08:50:39 -0400 Received: from mga14.intel.com ([192.55.52.115]:59110 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230324AbjF1MuU (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Wed, 28 Jun 2023 08:50:20 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1687956620; x=1719492620; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=FM06hAzUJYRZbdfF74LbkfHXkeBshKd+aj4zJ//1NoE=; b=U4sNzAeJUnHEFA6d+J84G1aXzy1p2HdRITlu6udaWH2BIvwwiIb6sqeb XGHezbe6t2+5Mw8vc6E3amO0Dj0aDtNcU70gPCVvw49Y+NoHISUeiLU+D j4+ZLRMWoIJQO+rWFnsZI70DcLKeDR7g/vtJUTpxdIaQyjewELglxUxz9 Fro7DAMapmoXzLbCCVYIhx3w1a+CvMeoCnwj29FK18P05pUD3hPDOcKZj XZ9xHC0f+NABC9WZPZfvxwawdqw2mbqiuoLy5rjLUzFc1HuLx9KgLvHKF HXI5UXeZSDobNLtyrbCkIJPZavsFSr79nvTKuIJATWCbu0xl6c2aYtjIo g==; X-IronPort-AV: E=McAfee;i="6600,9927,10754"; a="361875550" X-IronPort-AV: E=Sophos;i="6.01,165,1684825200"; d="scan'208";a="361875550" Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Jun 2023 05:50:19 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10754"; a="891035024" X-IronPort-AV: E=Sophos;i="6.01,165,1684825200"; d="scan'208";a="891035024" Received: from dev2 (HELO DEV2.igk.intel.com) ([10.237.148.94]) by orsmga005.jf.intel.com with ESMTP; 28 Jun 2023 05:50:15 -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>, =?utf-8?q?Amadeusz_S=C5=82aw?= =?utf-8?q?i=C5=84ski?= <amadeuszx.slawinski@linux.intel.com> Subject: [RFC PATCH 0/8] PCI: Define Intel PCI IDs and use them in drivers Date: Wed, 28 Jun 2023 22:51:27 +0200 Message-Id: <20230628205135.517241-1-amadeuszx.slawinski@linux.intel.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1769952072948056100?= X-GMAIL-MSGID: =?utf-8?q?1769952072948056100?= |
Series |
PCI: Define Intel PCI IDs and use them in drivers
|
|
Message
Amadeusz Sławiński
June 28, 2023, 8:51 p.m. UTC
PCI IDs for Intel HDA are duplicated across quite a few drivers, due to various configurations and historical reasons. Currently almost all uses of HDA PCI IDs have corresponding comment telling which platform it is. Additionally there are some inconsistencies between drivers about which ID corresponds to which device. Simplify things, by adding PCI IDs to global header and make use of them in drivers. This allows for removal of comments by having IDs themselves being self explanatory. Additionally it allows for removal of existing inconsistencies by having one source of truth. Amadeusz Sławiński (8): PCI: Add Intel Audio DSP devices to pci_ids.h ALSA: intel-dsp-config: Update PCI ID list ALSA: hda: Update PCI ID list ALSA: hda/i915: Update PCI IDs ASoC: Intel: avs: Update PCI ID list ASoC: Intel: avs: Update PCI ID list ASoC: Intel: Skylake: Update PCI ID list ASoC: SOF: Intel: Update PCI ID list include/linux/pci_ids.h | 44 ++++ sound/hda/hdac_i915.c | 8 +- sound/hda/intel-dsp-config.c | 119 +++++----- sound/pci/hda/hda_intel.c | 292 ++++++++++++------------- sound/soc/intel/avs/board_selection.c | 10 +- sound/soc/intel/avs/core.c | 16 +- sound/soc/intel/skylake/skl-messages.c | 16 +- sound/soc/intel/skylake/skl.c | 36 +-- sound/soc/sof/intel/pci-apl.c | 9 +- sound/soc/sof/intel/pci-cnl.c | 15 +- sound/soc/sof/intel/pci-icl.c | 12 +- sound/soc/sof/intel/pci-mtl.c | 3 +- sound/soc/sof/intel/pci-skl.c | 6 +- sound/soc/sof/intel/pci-tgl.c | 45 ++-- sound/soc/sof/intel/pci-tng.c | 3 +- 15 files changed, 311 insertions(+), 323 deletions(-)
Comments
On Wed, Jun 28, 2023 at 10:51:27PM +0200, Amadeusz Sławiński wrote: > PCI IDs for Intel HDA are duplicated across quite a few drivers, due to > various configurations and historical reasons. Currently almost all uses > of HDA PCI IDs have corresponding comment telling which platform it is. > Additionally there are some inconsistencies between drivers about which > ID corresponds to which device. Acked-by: Mark Brown <broonie@kernel.org>
On Wed, Jun 28, 2023 at 10:51:27PM +0200, Amadeusz Sławiński wrote: > PCI IDs for Intel HDA are duplicated across quite a few drivers, due to > various configurations and historical reasons. Currently almost all uses > of HDA PCI IDs have corresponding comment telling which platform it is. > Additionally there are some inconsistencies between drivers about which > ID corresponds to which device. > > Simplify things, by adding PCI IDs to global header and make use of them > in drivers. This allows for removal of comments by having IDs themselves > being self explanatory. Additionally it allows for removal of existing > inconsistencies by having one source of truth. I'm in favour of this series. It allows to use PCI_DEVICE_DATA() in many places. With that said, I think you can also add some more definitions to PCI IDs header for the sake of being able to use that macro.
On 6/28/23 16:49, Andy Shevchenko wrote: > On Wed, Jun 28, 2023 at 10:51:27PM +0200, Amadeusz Sławiński wrote: >> PCI IDs for Intel HDA are duplicated across quite a few drivers, due to >> various configurations and historical reasons. Currently almost all uses >> of HDA PCI IDs have corresponding comment telling which platform it is. >> Additionally there are some inconsistencies between drivers about which >> ID corresponds to which device. >> >> Simplify things, by adding PCI IDs to global header and make use of them >> in drivers. This allows for removal of comments by having IDs themselves >> being self explanatory. Additionally it allows for removal of existing >> inconsistencies by having one source of truth. > > I'm in favour of this series. It allows to use PCI_DEVICE_DATA() in many places. > With that said, I think you can also add some more definitions to PCI IDs header > for the sake of being able to use that macro. I don't have any objections on the change. The big open is how we add new definitions without a 3-way deadlock between PCI, sound and ASoC trees, and how those definitions can be added to the -stable trees. This isn't an hypothetical case, we have 2 pending submissions for LunarLake [1] and ArrowLake [2] which will be provided as soon as the merge window closes. It's not clear to me if Bjorn is ok to let those audio-specific PCI IDs go the audio trees, and how things would work between Mark and Takashi. [1] https://github.com/thesofproject/linux/pull/4425 [2] https://github.com/thesofproject/linux/pull/4437