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 phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 261D1C04A6A for ; Tue, 1 Aug 2023 21:28:27 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 5DC0986AE1; Tue, 1 Aug 2023 23:28:25 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=kwiboo.se Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=kwiboo.se header.i=@kwiboo.se header.b="YsUL/Pjo"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 6547B86C14; Tue, 1 Aug 2023 23:28:24 +0200 (CEST) Received: from wfbtzhsw.outbound-mail.sendgrid.net (wfbtzhsw.outbound-mail.sendgrid.net [159.183.224.105]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id C7D58867F7 for ; Tue, 1 Aug 2023 23:28:21 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=kwiboo.se Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=bounces+31435339-7456-u-boot=lists.denx.de@em2124.kwiboo.se DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kwiboo.se; h=from:subject:mime-version:to:cc:content-transfer-encoding: content-type:cc:content-type:from:subject:to; s=s1; bh=1ZLsCpJw4X2cjs4y/SUmf70uoq1/DcdNuepVv6OjaA4=; b=YsUL/PjoRYmSi7x/kCUcjUUJWuE4WRPBToL4egFOSCD9WrwmPAbocwd3vcCOTpkt9iw6 D9pSAJRaBdtVp5og3ffCuUkXBuKmFfmJ+ByibZvvZYB80iMBOdVbJtiMHEd5slVcVHCHDm 1ZkbVWeGsqkwudrzLl5Ks4J7CIu9C3sAJZpuSv54DbhOHmmgLD6ICpEjFg8cQq9R7nQXCK 2XmhdaCr5erexVMwRu7EuF9cnarVQL/uNcyGzgETv6SAlxeFpGTkznkVmvS3eWnnbQcmN7 YgrHYHQw/143Dl7/+4kz97THeRReokNWFYvHOvYuSDFtvMQY67dK4TkXvzLNI21g== Received: by filterdrecv-canary-59454c96cf-pff24 with SMTP id filterdrecv-canary-59454c96cf-pff24-1-64C97839-11 2023-08-01 21:25:13.557956383 +0000 UTC m=+7163356.574588259 Received: from bionic.localdomain (unknown) by geopod-ismtpd-4 (SG) with ESMTP id UD1iVDfoQta1XX7YgAZZnw Tue, 01 Aug 2023 21:25:13.178 +0000 (UTC) From: Jonas Karlman Subject: [PATCH 0/6] rockchip: rk3568: Fix use of PCIe bifurcation Date: Tue, 01 Aug 2023 21:25:13 +0000 (UTC) Message-ID: <20230801212511.2123575-1-jonas@kwiboo.se> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 X-SG-EID: =?us-ascii?Q?TdbjyGynYnRZWhH+7lKUQJL+ZxmxpowvO2O9SQF5CwCVrYgcwUXgU5DKUU3QxA?= =?us-ascii?Q?fZekEeQsTe+RrMu3cja6a0h0K5pFoMHcG3yDagL?= =?us-ascii?Q?zfEYmR6q2bMefeaKTV3iaMDQE5iFtOyW+=2FrbM5P?= =?us-ascii?Q?pqOUTYQdnLqjYbnuwXCtyis3nqbLgIMsStAY1Tk?= =?us-ascii?Q?TodnVK3uq6MOc3GPKOyJci+wkzWl39ehG21Z4ld?= =?us-ascii?Q?Idf11Fo9tRpXA3BOWt9P3YBcbz6gNsBzcsmSMC?= To: Kever Yang , Simon Glass , Philipp Tomsich Cc: Eugen Hristev , Jon Lin , u-boot@lists.denx.de, Jonas Karlman X-Entity-ID: P7KYpSJvGCELWjBME/J5tg== Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean This series add support for use of PCIe bifurcation on RK3568, and as a bonus support for the RK3588 PHY is also included. With PCIe bifurcation supported it is possible to enable PCIe on more RK3568 boards, e.g. on NanoPi R5C and NanoPi R5S. This series only include fixing the mini PCIe slot on Radxa E25. Most parts of this series was imported almost 1:1 from mainline linux. Patch 1 fixes configuration of number of lanes in pcie_dw_rockchip. Patch 2-3 refactor the snps-pcie3 phy driver. Patch 4 add bifurcation support for RK3568. Patch 5 add support for RK3588. Patch 6 enables the mini PCIe slot on Radxa E25. The RK3588 PHY part was tested on a ROCK 5B together with device tree files picked from Sebastian Reichel's rk3588 branch at [1]. Patches in this series is also aviliable at [2]. [1] https://git.kernel.org/pub/scm/linux/kernel/git/sre/linux-misc.git/tree/?h=rk3588 [2] https://github.com/Kwiboo/u-boot-rockchip/commits/rk35xx-pcie-bifurcation-v1 Jonas Karlman (6): pci: pcie_dw_rockchip: Configure number of lanes and link width speed phy: rockchip: snps-pcie3: Refactor to use clk_bulk API phy: rockchip: snps-pcie3: Refactor to use a phy_init ops phy: rockchip: snps-pcie3: Add bifurcation support for RK3568 phy: rockchip: snps-pcie3: Add support for RK3588 rockchip: rk3568-radxa-e25: Enable pcie3x1 node arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi | 11 +- configs/radxa-e25-rk3568_defconfig | 1 - drivers/pci/pcie_dw_rockchip.c | 58 ++++- .../phy/rockchip/phy-rockchip-snps-pcie3.c | 230 ++++++++++++++---- 4 files changed, 235 insertions(+), 65 deletions(-) -- 2.41.0