From patchwork Mon Sep 23 18:59:18 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Frank Li X-Patchwork-Id: 13809947 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 4B2FBCF9C71 for ; Mon, 23 Sep 2024 19:07:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:MIME-Version:Cc:To: Content-Transfer-Encoding:Content-Type:Message-Id:Date:Subject:From:Reply-To: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=tSxCkGr2E+mSdyHcbfmNyRd4WlUmCAiViAAKc7v4Vyo=; b=UjKOGLJDC5lAo3FXizy9qIOr+5 1sdHMVnLQS15yP8cVnHLHrEO97C6VsgFrq/BJ8tqTCitxCK0AGgTsuR1pvnHnAi1btp4d51uC6+jT 4D5zjUD1tElQLtJ7YDifM+KjMY3MKJV3e5qxIr+sEu0vNnEkhP42NTLQ4Hg//U4NpGgl9KYL+Mb4X pR3eKLL1kBiDnF1bD7kNwJhswB9zU8LdUDPDVE/zF7yBVi5mtCOwyUuuP4NXCJx8U/fl3LoSkFZjF oldAQMFhTcZ2aH4Q+MEpBybuJcyuSw3qYmW3akiLKJTZcKcBRTlEwdBlarM+SQFCleryd50et7++b InI4WEnQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1ssoOo-00000000Kv8-2OW7; Mon, 23 Sep 2024 19:07:06 +0000 Received: from mail-northeuropeazlp170130004.outbound.protection.outlook.com ([2a01:111:f403:c200::4] helo=DUZPR83CU001.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1ssoI7-00000000J4j-1YuH for linux-arm-kernel@lists.infradead.org; Mon, 23 Sep 2024 19:00:13 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=xuw6Vs1srrTs1tvmEa4N/Z9Hhm/lg2z93BrMlnB4/4p+X6s4iiYgYm/1TnAU6IuNFi/eYjzUj7Ntfthbwi3AfJKpv89p44ZINZkiu+ODFtEGOUCQHTIPBj9RNA2Xi/ESmlcmJaK/R89MbnwVfaskmfi56/1KvHwqfxxRGJd+5vg7RJIOAEfThDsT+KfF6UUI3/JIAScoaHiT0G5iwKpvD2x4MnONNfsjaX93xwdBB0sgeViekhOkpZHRfeG7v9RcvzJ2lIuhipHT/KocDS1lkDa5IXvBDaEBIKS62gh1LXyzEt3KA+OPGd3liba6N7+ArGfBW6yY0ozgJrncpzI4MQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=tSxCkGr2E+mSdyHcbfmNyRd4WlUmCAiViAAKc7v4Vyo=; b=H5DQ49arBD2yT8opxU+TmaMoaf6dgQNaXcL8ZLVI2qPB7tIdlRQzO6HLof2T0beHQOzk5HPNBDJYdEkyK874+fectTt3W3Kc0VZ7u3X4mzleRspOcJSddk06oz8sPJSqR8ZWgKpD7w5LcidapFw0O3t4jGg6yHyEbL+rmDlYpRyZsBr+VHK8xZ7GWNlvl69n3qY+kYQy1dwURwG9LlvfpXveVklv+SQIVmQKubWR07eIwhmyz+O2tD2ZlGJ1kWpYjkV6LdFG2d6F70ZVDgKYdbNIDDJlwxvAAv3+WFs2cjpWszWrRp9DDFySv7Qn/DksPNQ20SKUwoG2f+TNo5Veng== 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=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=tSxCkGr2E+mSdyHcbfmNyRd4WlUmCAiViAAKc7v4Vyo=; b=YzaArdd/RBkRuob2WSzBbrQoJUkfbXDgQbjIAFzr6v77JBxTwZM6zIyE3vq1ZCvM1SCEeuBC0DoqiLTXyyO4vGoC7LFmpzT22Nw7bWY8LklNv41vHmK9vf7FEYNaMALp53cganzoVuWaEthc7mPO4NTheWqJaCJzthS6KruZ+2BFvoq1WRCGAfkylBaQg+XH10YanKmNAEtBaFwC35Sok+z42q1sxW2jktIv5jryuorTegG7sw2svVEwATBms4tIyKmP58+322VzCPozn13EIaejYrmqFASXzVCvGK0GZ2O6sibY+QHimkI5bahwJPTDQNV4Z/guWajwOf0VMT3UwA== 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 DU0PR04MB9562.eurprd04.prod.outlook.com (2603:10a6:10:321::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7982.24; Mon, 23 Sep 2024 19:00:03 +0000 Received: from PAXPR04MB9642.eurprd04.prod.outlook.com ([fe80::9126:a61e:341d:4b06]) by PAXPR04MB9642.eurprd04.prod.outlook.com ([fe80::9126:a61e:341d:4b06%4]) with mapi id 15.20.7982.022; Mon, 23 Sep 2024 19:00:02 +0000 From: Frank Li Subject: [PATCH v2 0/4] PCI: ep: dwc/imx6: Add bus address support for PCI endpoint devices Date: Mon, 23 Sep 2024 14:59:18 -0400 Message-Id: <20240923-pcie_ep_range-v2-0-78d2ea434d9f@nxp.com> X-B4-Tracking: v=1; b=H4sIAIa68WYC/13MQQ6CMBCF4auQWVszLSDUlfcwhEgZZRbSpjUNh vTu1iZuXP4zed8OgTxTgHO1g6fIge2aQx0qMMttfZDgOTcoVA1q2QtnmEZyoy/PxrSmpRqRpIa 8cZ7uvBXvOuReOLysfxc+yu/1J+k/KUqBYqpJzyfV9Th1l3VzR2OfMKSUPi7AyZ+oAAAA To: Lorenzo Pieralisi , =?utf-8?q?Krzysztof_Wilczy?= =?utf-8?q?=C5=84ski?= , Manivannan Sadhasivam , Rob Herring , Bjorn Helgaas , Krzysztof Kozlowski , Conor Dooley , Abraham I , Saravana Kannan , Jingoo Han , Gustavo Pimentel , Jesper Nilsson , Richard Zhu , Lucas Stach , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam Cc: linux-pci@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, linux-arm-kernel@lists.infradead.org, imx@lists.linux.dev, =?utf-8?q?Krzys?= =?utf-8?q?ztof_Wilczy=C5=84ski?= , Frank Li X-Mailer: b4 0.13-dev-e586c X-Developer-Signature: v=1; a=ed25519-sha256; t=1727117997; l=5552; i=Frank.Li@nxp.com; s=20240130; h=from:subject:message-id; bh=V15zXozfNWL6kp+8D/DbmD0EcKRgdTMQmrzAGNRr6iw=; b=zLj7AFge05IBbyBRDen5FYTZP3VjCHOVj0jGDmLAsimhBEqqJ5y5lceZMKBIw0vKcilsOXTZ3 Rg9PNqLlPaiCPO49msN3rVVJpqzYWWqLJ68e6k/qV/wO1OUKaCCaF5H X-Developer-Key: i=Frank.Li@nxp.com; a=ed25519; pk=I0L1sDUfPxpAkRvPKy7MdauTuSENRq+DnA+G4qcS94Q= X-ClientProxiedBy: SJ0PR13CA0065.namprd13.prod.outlook.com (2603:10b6:a03:2c4::10) To PAXPR04MB9642.eurprd04.prod.outlook.com (2603:10a6:102:240::14) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: PAXPR04MB9642:EE_|DU0PR04MB9562:EE_ X-MS-Office365-Filtering-Correlation-Id: bf24b445-ff66-4e09-7dde-08dcdc01ee27 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|376014|7416014|52116014|1800799024|366016|921020|38350700014; X-Microsoft-Antispam-Message-Info: =?utf-8?q?+Qi1/eAogegtJkufGP9C044kFz/gN9q?= =?utf-8?q?bkyPzkBeYM7TZUZ8j5r33zeFy5q3q5X6XtO8HWcwKEGjU0Q74Kmn5HvZqEVkJMX/q?= =?utf-8?q?5W4MPfJVRVIq9JR5HYWWdMCVAfU109oSr5lBYHTL+DSLclRuw56Q1E2lSX/sGI1Da?= =?utf-8?q?7HZdYdbPBpzSbKt9MgMk5za1Ngjylo7RfdW2HMwwItFRJECPSby6pLdSv6ZXrGoh4?= =?utf-8?q?78MpqohKqKQLxCRXFxYrrzYsnoMhg3PAgomusEWd4Eeb926hPB1i17uQLozHaS5+x?= =?utf-8?q?RYfGkwGUu5+ahJTOF/9VXrD+s5QmmDNwBmUWpUxpL0MZf68AeW+T6UExBjOSSH63v?= =?utf-8?q?6jrl8iPUabQfztpCJ1ISM19mB3ux1wTYCnsvuV11FvwqwCbMFXEqLKMq9n8aCMmoe?= =?utf-8?q?ysG4y6/4BtAO+CzX4CYCvJFOt4GgBl/TXtNZIFUGM850nRFTD9eqMj4mgUwWMjHn8?= =?utf-8?q?E93HjAqpYrbPdvM25rNLSuf3aIYIx47/GpIcqYw9woeli+ThMbY2lkvI9knaO1pJp?= =?utf-8?q?eR4ZI01fT1I7evhYRCrrIHBmMb93PT8egGOLk1lcP7127Dax3XQNFdNLfM/ZF7IY6?= =?utf-8?q?LdPk5GBSHjZCzIjiu/8nJw2/EtciFurUst/O4RYPRR0qYvM8F/5YR25eIZTUwNUHw?= =?utf-8?q?w1xQr7wjTrZ58qV9Ej0KtXIDo8yctp937zMQTcT+rSN8kVF5rflQkS3Ca7U6evG3p?= =?utf-8?q?TtKCngxnhBQeqKsuYR1B796mzWEbgfm16HWryLW+P5aEyH5BBcFSooOWhBppay+vB?= =?utf-8?q?4mWsYkaiWOQ6cF8b+3FGy0A1y+20W+QANVirmzLM3TOMmEVGOniEcOJsB/A3BRf2T?= =?utf-8?q?Fhugo+8PaK7tCjvtkakvIkC4sVs7dx9b82BhDPhOR+xFc5IbzjriRghAMcaIqVhla?= =?utf-8?q?Z5kdQtHxaD4o7ei6BpqPeW6sl9S6eca6CujVUClLRlMplcskKqhg7TEg5RSAmkci2?= =?utf-8?q?zn4qQy/hk3NkWaPZ/1E/XF6/KFq0E1rc1a+fbbHGKOfRYxOfZV5F4hG51wwat6n5r?= =?utf-8?q?3YBoDk4j03g4Dwr6hlrJqEG8crtfQwxutOzBS8nLBB0vVhwL0/gBYHxwmLH9TVHUK?= =?utf-8?q?X8n98X1UDEo9J4y+koMjzQCTB9K/r0ywwPy0LTr2ieFpbC+DfOTreWAKFR1k7nM9o?= =?utf-8?q?FhzsU/iD5tlpGlgF5e1WXYRwoNKQP0MVu65RTk2uQVPIB6RQQh2v7MmVR1Xu8D/m0?= =?utf-8?q?ZkKYLrHyUvwPg8oWcdpCv2gHT+rzbaXiL0QnXncWcV0gUKSOydbm7j9aIRsGcPJct?= =?utf-8?q?9FU3UOtaoA/BSIknzPEMv1+VNqO+DSoFGE/uxI+UC6LqxQuVJ/TsM49rPZCEDKAKx?= =?utf-8?q?UToCdhH4iiy2ZqnHrQu506bw3wCbOPzukMHYprsVkfNCaWSYzwqXmy8=3D?= 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:(13230040)(376014)(7416014)(52116014)(1800799024)(366016)(921020)(38350700014);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?iu2r36iqhNwVQnHdUNT8ZZjpFVd2?= =?utf-8?q?U756twC5bFzwo/jLUoTRFjjCLVcHqJuHMdjQJP2Q9IpmaeScFB8CYJ2zCZbXYpj8V?= =?utf-8?q?1rut3iJ9rY/TPuQqvRpNc6Pqj6Al+6tm/+95XK59b0MuzrvgtVoVQ1msRL1xVklv3?= =?utf-8?q?z6iybBW3Bbqi10+Vtily8JRkU5OjqBCb05Ux+mg+3CmIuUmax1PF0bh2XIGYai30T?= =?utf-8?q?kAuMcN77yjut4GxTOljOa+guetb4NOf6ylKvGYL4Qzco6aMEbHznsyBjGgqXP5L1W?= =?utf-8?q?bEZNrHvjx1e3S9D3qo8J+USqvgTscygBRFR1gR9MGfypk1AAGuMYDXRyFJ/b6NPog?= =?utf-8?q?L1JonZRsixzaa+YXKBCEYr8prNsWqKYl9u5e2brDaF1m2vvzSUGZLHoivwFMK2Dfe?= =?utf-8?q?LcafNx/6DfTzX+Da8IL9KNZw50NzEQB3h/mXvzPrSDoR33jvfyd6Y4WUFAohLQasW?= =?utf-8?q?6+sRfF8gyVeOUnvstVGBcEF1RRoWFi7yl7LfdsBdU+bU9n1WJxB9GstSiyZeUxJup?= =?utf-8?q?1DypumEJoxYIU2RsHaBIS2+iMVAP+h17Qb2rWHIpOWlNSigTsZZLyArBKB0PvxeDA?= =?utf-8?q?uqhGsX6d/3BfyqGomXMfHTXWRH3DiYmbDb/JjxA1JQPLruzY3EWv24+lVcIRh11ck?= =?utf-8?q?xy8wuPw9vP3ZlUpEZ1DjrmqIh8dj383Cs1hMwzIL8WocRzZFmeamMq8DRGcSF1jk1?= =?utf-8?q?SnUIH3kXLFBErFS256NbkyAUDmiEAo6EYcBwISBjOAeznoaR0E64B37SDPBHpDJcx?= =?utf-8?q?MfiGDpP+xQX6Kl/3Y2wX8cjIEP4PIT33KkzELsG7sIR+SGng17fOeTN43/eirTLGH?= =?utf-8?q?kAflt7r9TrI4Cig0C3H+uCV9C/9ckm57Z5G97JPbua2HzvZ0lcwl795oX44u9ZxLK?= =?utf-8?q?s1peWVP+CBOrfsGAv4OTlQ4znO68InyigsFD+6ky1HUE4+Rr8yO1f9ab8TF5raWdW?= =?utf-8?q?0eFL08s0nAnfnX9Qqqcg9oWXtcbCphQq786aYqjdKW38zST3AyWCRK0zrZi5SfyHd?= =?utf-8?q?crM2+XjyQgaxNojbXR3jKqZ7RvWWOL5cB/JzsVbc9O/xqU/xLFcqDusVAKsHQPbmZ?= =?utf-8?q?txy4xHc6E79Fvl0wYnokjvCMHbz+vLNpsEbTQRXXpw7LpGw0N/8Y6Y8bkQp28t4Fe?= =?utf-8?q?BS73wvsCSnk/uoGPu2IgticNimpd5GNlHS6S7HHFcRhElCXoLBaX7SV4Lc2LC+vIe?= =?utf-8?q?Gy9I2yDhKcEHQxAd7r1kD810I/qzrRMQOV68c5N60KnGDB0SqfCbydxsex8v0Xudv?= =?utf-8?q?UcHtkgbK6NkZfXfas39UAJriknheIXTgnAEgFi8/7XbSyv9sb6d/grMYr0uFAMoEB?= =?utf-8?q?ZVbZH9mD0L5yv7YsQqEGqb7Waf2IcYPrSfcMq9aqgo29TtLnxNsBXfHtwIDZDK67m?= =?utf-8?q?n/y6CdrGphykZurCrwfMDAwY+8AJ/jPiEBiAdFKQAUeTCchSVMrPKI3n7K5TRYO+F?= =?utf-8?q?1noHUL+5IZOLK1Vm1ja0lOQ6PjupoPXcnlPUePyks/VOKA3LyYFLuIS8=3D?= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: bf24b445-ff66-4e09-7dde-08dcdc01ee27 X-MS-Exchange-CrossTenant-AuthSource: PAXPR04MB9642.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Sep 2024 19:00:02.9440 (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: K3NW47eb770KnHLwTIuyilovlLUCrXy7Qj0EEukz0gPk/GIKDPDAJOCR3eBLAQBwc0OoF7QQ9kyGZ+o8iYqooA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DU0PR04MB9562 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240923_120011_646283_99E6B8B8 X-CRM114-Status: UNSURE ( 9.71 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Endpoint Root complex ┌───────┐ ┌─────────┐ ┌─────┐ │ EP │ │ │ ┌─────┐ │ │ │ Ctrl │ │ │ │ CPU │ │ DDR │ │ │ │ ┌────┐ │ └──┬──┘ │ │◄──────┼─ATU ◄─┼────────┼─┤BarN│◄─┼─────────┘ │ │ │ │ │ └────┘ │ Outbound Transfer └─────┘ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ Inbound Transfer │ │ │ │ ┌──▼──┐ ┌───────┐ │ │ │ ┌───────┼─────►│DDR │ │ │ outbound Transfer* │ │ │ └─────┘ ┌─────┐ │ Bus ┼─────►│ ATU ─┬────────┼─┘ │ │ │ │ Fabric│Bus │ │ PCI Addr │ │ CPU ├───►│ │Addr │ │ 0xA000_0000 │ │ │CPU │ │0x8000_0000 │ │ │ └─────┘Addr└───────┘ │ │ │ │ 0x7000_0000 └───────┘ └─────────┘ Add `bus_addr_base` to configure the outbound window address for CPU write. The BUS fabric generally passes the same address to the PCIe EP controller, but some BUS fabrics convert the address before sending it to the PCIe EP controller. Above diagram, CPU write data to outbound windows address 0x7000_0000, Bus fabric convert it to 0x8000_0000. ATU should use BUS address 0x8000_0000 as input address and convert to PCI address 0xA000_0000. Previously, `cpu_addr_fixup()` was used to handle address conversion. Now, the device tree provides this information, preferring a common method. bus@5f000000 { compatible = "simple-bus"; ranges = <0x5f000000 0x0 0x5f000000 0x21000000>, <0x80000000 0x0 0x70000000 0x10000000>; pcie-ep@5f010000 { reg = <0x5f010000 0x00010000>, <0x80000000 0x10000000>; reg-names = "dbi", "addr_space"; ... }; ... }; 'ranges' in bus@5f000000 descript how address convert from CPU address to BUS address. Use `of_property_read_reg()` to obtain the BUS address and set it to the ATU correctly, eliminating the need for vendor-specific cpu_addr_fixup(). The 1st patch implement above method in dwc common driver. The 2nd patch update imx6's binding doc to add fsl,imx8q-pcie-ep. The 3rd patch fix a pci-mx6's a bug The 4th patch enable pci ep function. The imx8q's dts is usptreaming, the pcie-ep part is below. hsio_subsys: bus@5f000000 { compatible = "simple-bus"; #address-cells = <1>; #size-cells = <1>; /* Only supports up to 32bits DMA, map all possible DDR as inbound ranges */ dma-ranges = <0x80000000 0 0x80000000 0x80000000>; ranges = <0x5f000000 0x0 0x5f000000 0x21000000>, <0x80000000 0x0 0x70000000 0x10000000>; pcieb_ep: pcie-ep@5f010000 { compatible = "fsl,imx8q-pcie-ep"; reg = <0x5f010000 0x00010000>, <0x80000000 0x10000000>; reg-names = "dbi", "addr_space"; num-lanes = <1>; interrupts = ; interrupt-names = "dma"; clocks = <&pcieb_lpcg IMX_LPCG_CLK_6>, <&pcieb_lpcg IMX_LPCG_CLK_4>, <&pcieb_lpcg IMX_LPCG_CLK_5>; clock-names = "dbi", "mstr", "slv"; power-domains = <&pd IMX_SC_R_PCIE_B>; fsl,max-link-speed = <3>; num-ib-windows = <6>; num-ob-windows = <6>; }; }; Signed-off-by: Frank Li --- Changes in v2: - Totally rewrite with difference method. 'range' should in bus node instead pcie-ep node because address convert happen at bus fabric. Needn't add 'range' property at pci-ep node. - Link to v1: https://lore.kernel.org/r/20240919-pcie_ep_range-v1-0-b3e9d62780b7@nxp.com --- Frank Li (4): PCI: dwc: ep: Add bus_addr_base for outbound window dt-bindings: PCI: fsl,imx6q-pcie-ep: Add compatible string fsl,imx8q-pcie-ep PCI: imx6: Pass correct sub mode when calling phy_set_mode_ext() PCI: imx6: Add i.MX8Q PCIe Endpoint (EP) support .../devicetree/bindings/pci/fsl,imx6q-pcie-ep.yaml | 38 +++++++++++++++++++++- drivers/pci/controller/dwc/pci-imx6.c | 24 +++++++++++++- drivers/pci/controller/dwc/pcie-designware-ep.c | 12 ++++++- drivers/pci/controller/dwc/pcie-designware.h | 1 + 4 files changed, 72 insertions(+), 3 deletions(-) --- base-commit: 4ed76e3b7438dd6e3d9b11d6a4cb853a350ec407 change-id: 20240918-pcie_ep_range-4c5c5e300e19 Best regards, --- Frank Li