From patchwork Fri Jan 19 17:11:10 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Frank Li X-Patchwork-Id: 189616 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7301:2bc4:b0:101:a8e8:374 with SMTP id hx4csp1148784dyb; Fri, 19 Jan 2024 09:13:24 -0800 (PST) X-Google-Smtp-Source: AGHT+IGunf3JcMzGYtUxJ9HeCHmGaplLt16R76/MmGFLiTo2oiiv/7wb0iXD/L72xTMJsguQ54Vc X-Received: by 2002:ac8:5c45:0:b0:42a:4e8:e2cf with SMTP id j5-20020ac85c45000000b0042a04e8e2cfmr179265qtj.45.1705684403891; Fri, 19 Jan 2024 09:13:23 -0800 (PST) Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id g14-20020ac87f4e000000b0042a0cd7f952si6678928qtk.239.2024.01.19.09.13.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 19 Jan 2024 09:13:23 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-31399-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@nxp.com header.s=selector2 header.b=cWwVxj8I; arc=fail (signature failed); spf=pass (google.com: domain of linux-kernel+bounces-31399-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-31399-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com 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 ny.mirrors.kernel.org (Postfix) with ESMTPS id A0FF71C24CA1 for ; Fri, 19 Jan 2024 17:13:23 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 56AA756B67; Fri, 19 Jan 2024 17:12:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="cWwVxj8I" Received: from EUR05-AM6-obe.outbound.protection.outlook.com (mail-am6eur05on2064.outbound.protection.outlook.com [40.107.22.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3173656476; Fri, 19 Jan 2024 17:12:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.22.64 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705684328; cv=fail; b=Vm/Us+uZnrfT3z1aJx498tPznoAqSAggUeCs8O9818nbAs3M1qBdQn0BuO4WBaqEPEXUYGSS+EwxTP/RsamyQutajLzqYJthUwFggrCU3G+bDQfxhgLDXmGnXT7JQqXer/4hON99mSU0t/nMlNMw/4eUY3qfCDFt7H/0e1mFJnE= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705684328; c=relaxed/simple; bh=FNUfEU2NBJdh/n7ePbKkcWgC89DpajZR7gZ+IIFZvVU=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: Content-Type:MIME-Version; b=GdhvWShC0ZhqDISlD3wCLvd49bL8oIupVFjcAwEj1EEUjtj8bN+VUW1P4zELTwC6uS5qqVw4+C3OrGgHckTZpFe0gpQS81BBZLMj33B6ZgOCoOm9C6LFk/AHjkVg2qRs3F88vR+zVBcPbQExW+FhRr7mwInCsaY6KE2COHJcpFY= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com; spf=pass smtp.mailfrom=nxp.com; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b=cWwVxj8I; arc=fail smtp.client-ip=40.107.22.64 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=nxp.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=XvRlYIGOliRt8QJT8Xhkk5U22FJbRymvelptUXtJPis1/Dec4LSdl2dLDufoET+YF1uMKTr+rQV1tiExAG+kizJPBQrYi2ltqBctVn/QrDSM1uyXsxmNV+P+wyavmtrXiOJdjwk/8ptI2CPn5l3J2hg/1rsrvR4iZYENG53FXF1xcwIW7Pwk3wq3vGtypLZDOTxzwsn63u15fw8xNafTnDTcari4F63xQa/7nDgadaxDCRfpiFlcpS8bLiWN8gscz6t3OOLSbMppX/a6+dKw9CHRGDvrf+xJX6/jqNBG0lgP2trT79SqudYxp1w/72dIQCgs9Onvzhm9MRFQByV2AA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=ZoxR+TinRacNV4SkOVSqNvChWq7u+ai+t5XxaquMaNg=; b=IwNwQFvfPBk9Rys5KxHPftxgDzlJ1Xe1kjR+qE3syc6JNDYOyUji5MIZIH0FxQD4tbeAT7XlKqxh/AVT8F2GrSp6pWrHawP4HvtGC/v8MVqK5zh/NgbuQ40e66PRoe47Ws4fkQsPIbO3rcixVQ69qfMXgMtD1+XmAR+MhF3FDMk5M9QOsFVSpqyfgb3d7ImxTgDTET7QCFuiEHMnZhVaPh7aM6/zCGbsjqFvL0nHssAlJTYhzRk5Gi3ZRilDl+VTwPHJmuNErBVgeIUMIkzyLjCRKf/vtJYHa7RSHfWqyj72vWwo5bnNoF0ZYMOd5W3OJoXNRTlG1bldWKm1lRsjtQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ZoxR+TinRacNV4SkOVSqNvChWq7u+ai+t5XxaquMaNg=; b=cWwVxj8IXC6n43Itwf2FNzvhUSMSbYjnzA1dSt79bXePSX16qowUanX0s+QJ8UPzkDINXaD2e3NsENXNgJ8xp04IGNIG30mZl3BR0uEmAEFcCy8EJzqY5B0RdcRUsJ8h+D4gGNMfYE0OlRvwbXu2CYVFhJN/FIu/ey50xepadAg= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from PAXPR04MB9642.eurprd04.prod.outlook.com (2603:10a6:102:240::14) by PA4PR04MB9688.eurprd04.prod.outlook.com (2603:10a6:102:271::5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7202.24; Fri, 19 Jan 2024 17:12:04 +0000 Received: from PAXPR04MB9642.eurprd04.prod.outlook.com ([fe80::b8af:bfe5:dffd:59a9]) by PAXPR04MB9642.eurprd04.prod.outlook.com ([fe80::b8af:bfe5:dffd:59a9%4]) with mapi id 15.20.7202.020; Fri, 19 Jan 2024 17:12:04 +0000 From: Frank Li To: manivannan.sadhasivam@linaro.org Cc: Frank.Li@nxp.com, bhelgaas@google.com, conor+dt@kernel.org, devicetree@vger.kernel.org, festevam@gmail.com, helgaas@kernel.org, hongxing.zhu@nxp.com, imx@lists.linux.dev, kernel@pengutronix.de, krzysztof.kozlowski+dt@linaro.org, krzysztof.kozlowski@linaro.org, kw@linux.com, l.stach@pengutronix.de, linux-arm-kernel@lists.infradead.org, linux-imx@nxp.com, linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org, lpieralisi@kernel.org, robh@kernel.org, s.hauer@pengutronix.de, shawnguo@kernel.org Subject: [PATCH v9 04/16] dt-bindings: imx6q-pcie: Add linux,pci-domain as required for iMX8MQ Date: Fri, 19 Jan 2024 12:11:10 -0500 Message-Id: <20240119171122.3057511-5-Frank.Li@nxp.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240119171122.3057511-1-Frank.Li@nxp.com> References: <20240119171122.3057511-1-Frank.Li@nxp.com> X-ClientProxiedBy: BY5PR20CA0023.namprd20.prod.outlook.com (2603:10b6:a03:1f4::36) To PAXPR04MB9642.eurprd04.prod.outlook.com (2603:10a6:102:240::14) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: PAXPR04MB9642:EE_|PA4PR04MB9688:EE_ X-MS-Office365-Filtering-Correlation-Id: eba96308-f15d-4715-9e82-08dc1911c201 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Q6yUAmn/mmeVBiHZn8J9b10dovPZJKbyPCWdQ1eUnAcLDxu9MIPJGiU36Q+kgYXPyHsNb14a3fbruaSYYlZ8K3tmwyAdvV4lSjt4Hd/5Hud0MomO/DkSHfLAhyzMYCyH0P6Z55kwWAkjlDR2kUTQGD2h6q2X7vxf4w/a2iW+YJtugD3mVdYRXZ4b0anurJZs25DwVVEcGZHEuMbCHhFykTCicfiZS6swrJoJYN7o3zHrwaxyQ8cvHkGqLaMtUre89AR+78F3ur8r0qDIHYweSzR2/S4WpGwGShUloC8hf7yYkWob5UmR1OnXOfV4k/mcsPhjEbQI2ezLt4zp1AYGfB9+b1cYObTJg6hpJj84Qy/0SJYo7rdI6yOJ7Rl/41UILs25EkPsyTEfufLI6sEMQntXAE3x3TNeyWFnFo9bQnfwwaS7iZhM6kTbd1RKDWBx/3+64Z0q7eRnecVHPXQCohHDrIrOcrs4Nw64mbpJ9dEGfUC2iLw80TDYZgLzOI38h2yDtikZJ+7fAiJmiM0yHnLfSkVd6W0Bs+V/h37UoeNTN09ONsp0/m0Qev5lMu7bn95Bqb2M+ZoV4YUR+Luqgesneb9IUhLt9eWdQHbbRFUYcwVqmOoryG8S5lTsZ5258qAxLLGt1ZVqiaihU2gAkw== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PAXPR04MB9642.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(376002)(366004)(136003)(396003)(39860400002)(346002)(230922051799003)(1800799012)(186009)(451199024)(64100799003)(38100700002)(6666004)(41300700001)(6486002)(478600001)(6506007)(52116002)(26005)(83380400001)(2616005)(6512007)(86362001)(6916009)(316002)(2906002)(7416002)(36756003)(8936002)(4326008)(8676002)(66946007)(38350700005)(66556008)(66476007)(5660300002)(1076003)(32563001);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: JqhHZGE9wxfYfK+P3CtSfw8ocbw3Au9YlF5QpSVh3MmakmobI+wlCj25ZnLuCyvMjffKEP9//FVxkat8a5hYALeNK1WV4A02IHouyPlkrnRw5SAp3NQ0RTH6XMxAm/HRds8LV3aBgLzfJ1QbumxoywrQER3arY3MGiyjYqSoh7IKOsFwdgf644kfhrgd0aZ3xTZbzls4g0Pc7KTZlOlgrfIbPYdGobsiohjOm6cBNFUDm8855wCY6OTTjq/ju/CgoNFcp+r+5ZY1VMhqTFxpy7MR4mG2t0A1WUa989TJ/x4dQRhSAA1SrcbZ71sJMM83eBfyQpivfNbMo6QLSReLJk46SvASx99P5cHbYiVw35r0+J6zevD6766YuO71KksGP3jGsScAXtMhwAmomzv6qX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p6vD2qo9O2Bcn4/8ho23uyJshUazvc9Fni/nWRjoHzYweDS1sj8HB4ck92o0fPEM8xr8emrLTtkIkVOCpKTdIG0XW/LMauT1wSmbKYYJSHP7w= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: eba96308-f15d-4715-9e82-08dc1911c201 X-MS-Exchange-CrossTenant-AuthSource: PAXPR04MB9642.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Jan 2024 17:12:04.1627 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: TmNWKnRiyVp+RCZWXPXeGPonFoCuOs1IzRjXKX+6mTSOErcERvjvAMNXiIcgoCJp00fDmMeb75Pr6KcTW/axQQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: PA4PR04MB9688 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1788539729483411949 X-GMAIL-MSGID: 1788539729483411949 iMX8MQ have two pci controllers. Adds "linux,pci-domain" as required property for iMX8MQ to indicate pci controller index. This adjustment paves the way for eliminating the hardcoded check on the base register for acquiring the controller_id. ... if (dbi_base->start == IMX8MQ_PCIE2_BASE_ADDR) imx6_pcie->controller_id = 1; ... The controller_id is crucial and utilized for certain register bit positions. It must align precisely with the controller index in the SoC. An auto-incremented ID don't fit this case. The DTS or fuse configurations may deactivate specific PCI controllers. Reviewed-by: Rob Herring Signed-off-by: Frank Li --- Notes: Change from v8 to v9 - Add rob's review tag Change from v6 to v8 -none Change from v5 to v6 - rework commit message to explain why need required and why auto increase id not work Change from v4 to v5 - new patch at v5 .../bindings/pci/fsl,imx6q-pcie-common.yaml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/Documentation/devicetree/bindings/pci/fsl,imx6q-pcie-common.yaml b/Documentation/devicetree/bindings/pci/fsl,imx6q-pcie-common.yaml index d91b639ae7ae7..8f39b4e6e8491 100644 --- a/Documentation/devicetree/bindings/pci/fsl,imx6q-pcie-common.yaml +++ b/Documentation/devicetree/bindings/pci/fsl,imx6q-pcie-common.yaml @@ -265,6 +265,17 @@ allOf: - const: apps - const: turnoff + - if: + properties: + compatible: + contains: + enum: + - fsl,imx8mq-pcie + - fsl,imx8mq-pcie-ep + then: + required: + - linux,pci-domain + additionalProperties: true ...