Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp834228pxu; Wed, 6 Jan 2021 05:51:32 -0800 (PST) X-Google-Smtp-Source: ABdhPJycS6LEcGt21pmSXu7LF931T1dfs63jiN5Oof71M5NPsHrJPpy+p4+a3Jw2Wb8XtBOAwxPa X-Received: by 2002:a17:906:780c:: with SMTP id u12mr2863630ejm.125.1609941092559; Wed, 06 Jan 2021 05:51:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1609941092; cv=none; d=google.com; s=arc-20160816; b=p+OCzW7tx+Zlga37WsxiaD5Ks7UUZ0d3zy7aDKg2gDMD9esmA1Zq5MLNULYBrmWWte kvxrs3MzTfQkkgsXw5b6zupj2qnP2n4wQLZBdqR8j7SrYSht8dvmaWMBnlcShb6ZzsRa TWjaYZtvidVJDcEm4pxTTmr3ZSew6Yfo/3xOAe6gWChxOYogukRW5BI7iY2OYCvYc1kx ydOtnQwZX/5D+0uLlgJhGOwnEFk937TMQqOhk6gldAuDaU/dCnqJ2B5AfUOybk7j7ibw kczA7RDXzP5HOf4btGc/U3yqz9uvctPNYDnRdB1RMVgo3atyRRewrqvfTjNWNQBu2on5 DSUQ== 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=p0s3A6Ss7b6UyG59eYD5d2iA9IJeTLOC9YL5zqxWRX4=; b=0Tr4oIQtqMs0lDKT0zeLCNdJaLICATOHBejj2nRufMFDgNPmmWc8JZ8rlfpA41wFIO TdeYaa3obNXdGh/AB592tMBqapmcF394VovfRjHmWAj40lOr2Cok6/tR3gUS7yLq0gXv I4F7U0BmShV6KU6owpzDi15CnNfJeqKXkz2++zvFF3bCFp8ipIkAS/TXZ6Atbn9Dmbxj L8J7wyGAU6P7+/Z1DE2fYeHDa83SbbvAOEgZ3KSbtYLyO2srQFZ3LexwZWrRLwh4ygHC Vv5gtM3zyLmpKPqNBfyXHAWMvR16dhbS+bw0fePNgEliYVVZaeuJkoVdutNDtc4Gf5/B lzCg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ZGMA2yuU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a15si1020374edr.433.2021.01.06.05.51.06; Wed, 06 Jan 2021 05:51:32 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ZGMA2yuU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726951AbhAFNrP (ORCPT + 99 others); Wed, 6 Jan 2021 08:47:15 -0500 Received: from mail.kernel.org ([198.145.29.99]:50834 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726074AbhAFNrH (ORCPT ); Wed, 6 Jan 2021 08:47:07 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 7D26F22B40; Wed, 6 Jan 2021 13:46:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1609940786; bh=dk8pXxau3B7w7pPUwA0RrhUn2p0NPeGc5CfgVN0DmzQ=; h=From:To:Cc:Subject:Date:From; b=ZGMA2yuUlk3EsCi/TmoRfktBveZSgR6AWjg6xDPQXlUij7RfCRgx9e8sx58aHDA+3 kbiSLI4QrOEWdxlQY8yXgjziLtc1avxml8f5Nmdyh5AgmuxgCc+wm6iDw8B4CYGeqa HAacO9ZaH7lHyEIEbJ5e+PblRveWDce0x7EGc9fiYbgwLR2a9exe6UJDs43ZdZ6XOp +6T1M8agU/E85gddh1oArPrKBEUjtID41uWBOmNQ6j9zgjBolzgmqwTgAMJLRQe1c/ yevsMgzuU4EADGqOEUp45n48k6Y3HyTFqgETNjfc9EGEZBY7Of4cHPT6xsb/1IWKN9 xuSSRWQNhci/w== Received: by wens.tw (Postfix, from userid 1000) id 5155F5FB6B; Wed, 6 Jan 2021 21:46:24 +0800 (CST) From: Chen-Yu Tsai To: Shawn Lin , Lorenzo Pieralisi , Rob Herring , Bjorn Helgaas , Heiko Stuebner Cc: Chen-Yu Tsai , Robin Murphy , Johan Jonker , linux-pci@vger.kernel.org, linux-rockchip@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v3 0/4] arm64: rockchip: Fix PCIe ep-gpios requirement and Add Nanopi M4B Date: Wed, 6 Jan 2021 21:46:13 +0800 Message-Id: <20210106134617.391-1-wens@kernel.org> X-Mailer: git-send-email 2.29.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Chen-Yu Tsai Hi everyone, This is v3 of my Nanopi M4B series. Changes since v2 include: - Replaced dev_err() with dev_err_probe() for gpiod_get_optional() error - Added Reviewed-by tag from Robin Murphy for patch 3 Changes since v1 include: - Rewrite subject of patch 1 to match existing convention and reference 'ep-gpios' DT property instead of the 'ep_gpio' field This series mainly adds support for the new Nanopi M4B, which is a newer variant of the Nanopi M4. The differences against the original Nanopi M4 that are common with the other M4V2 revision include: - microphone header removed - power button added - recovery button added Additional changes specific to the M4B: - USB 3.0 hub removed; board now has 2x USB 3.0 type-A ports and 2x USB 2.0 ports - ADB toggle switch added; this changes the top USB 3.0 host port to a peripheral port - Type-C port no longer supports data or PD - WiFi/Bluetooth combo chip switched to AP6256, which supports BT 5.0 but only 1T1R (down from 2T2R) for WiFi While working on this, I found that for the M4 family, the PCIe reset pin (from the M.2 expansion board) was not wired to the SoC. Only the NanoPC T4 has this wired. This ended up in patches 1 and 3. Patch 1 makes ep_gpio in the Rockchip PCIe driver optional. This property is optional in the DT binding, so this just makes the driver adhere to the binding. Patch 2 adds a new compatible string for the new board. Patch 3 moves the ep-gpios property of the pcie controller from the common nanopi4.dtsi file to the nanopc-t4.dts file. Patch 4 adds a new device tree file for the new board. It includes the original device tree for the M4, and then lists the differences. Given that patch 3 would make PCIe unusable without patch 1, I suggest merging patch 1 through the PCI tree as a fix for 5.10, and the rest for 5.11 through the Rockchip tree. Please have a look. The changes are mostly trivial. Regards ChenYu Chen-Yu Tsai (4): PCI: rockchip: Make 'ep-gpios' DT property optional dt-bindings: arm: rockchip: Add FriendlyARM NanoPi M4B arm64: dts: rockchip: nanopi4: Move ep-gpios property to nanopc-t4 arm64: dts: rockchip: rk3399: Add NanoPi M4B .../devicetree/bindings/arm/rockchip.yaml | 1 + arch/arm64/boot/dts/rockchip/Makefile | 1 + .../boot/dts/rockchip/rk3399-nanopc-t4.dts | 1 + .../boot/dts/rockchip/rk3399-nanopi-m4b.dts | 52 +++++++++++++++++++ .../boot/dts/rockchip/rk3399-nanopi4.dtsi | 1 - drivers/pci/controller/pcie-rockchip.c | 5 +- 6 files changed, 58 insertions(+), 3 deletions(-) create mode 100644 arch/arm64/boot/dts/rockchip/rk3399-nanopi-m4b.dts -- 2.29.2