From patchwork Mon Apr 15 08:11:35 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yoshihiro Shimoda X-Patchwork-Id: 1923631 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=2604:1380:4601:e00::3; helo=am.mirrors.kernel.org; envelope-from=linux-pci+bounces-6241-incoming=patchwork.ozlabs.org@vger.kernel.org; receiver=patchwork.ozlabs.org) Received: from am.mirrors.kernel.org (am.mirrors.kernel.org [IPv6:2604:1380:4601:e00::3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4VJ0Jj5YQsz1yZ2 for ; Mon, 15 Apr 2024 18:12:21 +1000 (AEST) Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 2BBC71F2415C for ; Mon, 15 Apr 2024 08:12:19 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 3FB0D3987D; Mon, 15 Apr 2024 08:11:50 +0000 (UTC) X-Original-To: linux-pci@vger.kernel.org Received: from relmlie6.idc.renesas.com (relmlor2.renesas.com [210.160.252.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8EF7037707; Mon, 15 Apr 2024 08:11:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=210.160.252.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713168710; cv=none; b=aygaDfspCGjq2vdyll3kr5WtuSmyJlnZF3v6M7usR/zSKsuGeZoa4le13nMPIEuhDygQnb2mKR0wW5thFX4YRzfeE7jGlMrTVDiYbFqOHF3j4MbWqhdi7cGQm6dswVeVgs+htdKZ7HoQpVyADwj4fcEnJuzj1jXfQtA3XO/Rm7I= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713168710; c=relaxed/simple; bh=QnwTI3KUpNqnytyL/ivdKToupG07AQRxxUXGQH05NMc=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=J9KVsalw2BLaIpHm25CH8oCLAPCiYVpM9f+y+aYRXKUN2ASQi8x5ZDO+cTRkfYaxDqgz1LHEtq0TinLh3SmKy7NUyy5ueYSZxvE/WX0UPgf69zAMSjOqr4RN/42f4IW63gP+XbnLQMz/tkKEsp0BGnuAZZ2Sw8BOy7B+ukaeA24= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=renesas.com; spf=pass smtp.mailfrom=renesas.com; arc=none smtp.client-ip=210.160.252.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=renesas.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=renesas.com X-IronPort-AV: E=Sophos;i="6.07,202,1708354800"; d="scan'208";a="205421250" Received: from unknown (HELO relmlir5.idc.renesas.com) ([10.200.68.151]) by relmlie6.idc.renesas.com with ESMTP; 15 Apr 2024 17:11:42 +0900 Received: from localhost.localdomain (unknown [10.166.13.99]) by relmlir5.idc.renesas.com (Postfix) with ESMTP id 2BD9B400BC1D; Mon, 15 Apr 2024 17:11:42 +0900 (JST) From: Yoshihiro Shimoda To: lpieralisi@kernel.org, kw@linux.com, robh@kernel.org, bhelgaas@google.com, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, jingoohan1@gmail.com, mani@kernel.org Cc: marek.vasut+renesas@gmail.com, linux-pci@vger.kernel.org, devicetree@vger.kernel.org, linux-renesas-soc@vger.kernel.org, Yoshihiro Shimoda , Manivannan Sadhasivam , Frank Li Subject: [PATCH v7 7/7] misc: pci_endpoint_test: Document a policy about adding pci_device_id Date: Mon, 15 Apr 2024 17:11:35 +0900 Message-Id: <20240415081135.3814373-8-yoshihiro.shimoda.uh@renesas.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20240415081135.3814373-1-yoshihiro.shimoda.uh@renesas.com> References: <20240415081135.3814373-1-yoshihiro.shimoda.uh@renesas.com> Precedence: bulk X-Mailing-List: linux-pci@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 To avoid becoming struct pci_device_id pci_endpoint_test_tbl longer and longer, document a policy. For example, if PCIe endpoint controller can configure vendor id and/or product id, you can reuse one of existing entries to test. Signed-off-by: Yoshihiro Shimoda Reviewed-by: Manivannan Sadhasivam Reviewed-by: Frank Li --- Cc: Frank Li --- drivers/misc/pci_endpoint_test.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/misc/pci_endpoint_test.c b/drivers/misc/pci_endpoint_test.c index c38a6083f0a7..727db13b6450 100644 --- a/drivers/misc/pci_endpoint_test.c +++ b/drivers/misc/pci_endpoint_test.c @@ -980,6 +980,7 @@ static const struct pci_endpoint_test_data j721e_data = { .irq_type = IRQ_TYPE_MSI, }; +/* Do not add a new entry if the controller can use existing VID:PID combinations */ static const struct pci_device_id pci_endpoint_test_tbl[] = { { PCI_DEVICE(PCI_VENDOR_ID_TI, PCI_DEVICE_ID_TI_DRA74x), .driver_data = (kernel_ulong_t)&default_data,