From mboxrd@z Thu Jan 1 00:00:00 1970 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 A80D6C004C0 for ; Sat, 21 Oct 2023 06:23: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: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=oyI95RO5WnhlgKYsHcNEMdduaojl62CgwedVnOHSswA=; b=O7ti4JoRNQrFFT Ix68P566XiMPN9Ih/v8cU7XedlAEC+OblD2Fr8sfXae3qH3rLitSs9ywmq1UqpGKppU1kSV5gVmhP t2JA+DZCFaHrSzGp4NYerL5Tx8uqhOZ0tvEGVMyELWX+rXtOtImqMnzMnaWk4fjIkgcXOeiyY/RKU sspSh8JBwMES+WATnDb9Ucj8H39W0iLVb4l+nR1xfY9Ni8E3zsQZyYebEjVF9kwVKHs2IvLJDvamP FWCIq8DscLd58bhuOXRn3g1C9cviQOzvchHEepOUYcZYhzIj6IMeKbbqhZGiYpsLHKY5oRvKDBZU8 a5gE7SJbbd74z0mIOGfA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qu5NZ-003YUi-1S; Sat, 21 Oct 2023 06:22:33 +0000 Received: from mail-lf1-x134.google.com ([2a00:1450:4864:20::134]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qu5NW-003YUB-0F for linux-arm-kernel@lists.infradead.org; Sat, 21 Oct 2023 06:22:31 +0000 Received: by mail-lf1-x134.google.com with SMTP id 2adb3069b0e04-507a62d4788so2372774e87.0 for ; Fri, 20 Oct 2023 23:22:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1697869347; x=1698474147; darn=lists.infradead.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=FntaMjejU2gWLtGj930Sn2rHR1aIlW/u+KSwKSv5jBk=; b=GfgQ7r8HlHRlpPJBjWaB2notQpokKc4REwENs8D1WYJxJ+hRoUrdEisp+ZZXJ/8Wxx PKyg0Rk8zHSrHhOxQ87mrlJkccD/JcKCH8RaUcx2N4tGXXx4JHk2CDZIlnnlqx7cEx8r MSVgFXpGVMfJ26Ecz427QYyynNPMc9cVZ7KV3mclReJKW7xjbFu99wLzAaL+jIdHgYsN 6gHhyVw0xdnTL66oXOtQShtik/Y4u+g/TyXgcVafifdRPw3QOIWSMKan0HxNPnzLG5b+ ucnoHf8GVxRENeAPYuGYeNXWOVLm8NUQdac+E/n4q1cYlmSooVnmViYJ+V2RRnKgdQd2 V6iA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697869347; x=1698474147; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=FntaMjejU2gWLtGj930Sn2rHR1aIlW/u+KSwKSv5jBk=; b=taN2Zd224A8F9Qmi1erylAou+yD56lPmtrwo/+yYmBgrgM4g4hBoOL4nBa61yrEwQy X4tKGI4xWGy9t5XjQIimzHRM32KF5DZ0oMX8MQ3XR/AHag2hmA/6htB7au6+DRaPgUWz elI+9LD0RsleR+DtaJxcQFAeaFx0c1th33LFJEn/Wc5FQnABbAIIQOoq4FlxBiFhH4gd AZZF9TRW6smoxtKKp+J/p101YGc36QHFJTOWKNKXBTD0czfdaiz+rYGpkukVF9G/vyLy NquYkigGC3gS74ypEJ0iv3HTAd7kNaXkUBaRmlsrcCEQeN78CQMaivN8h395JItPCnf7 RTgg== X-Gm-Message-State: AOJu0YxCDfs1rUjDu7fQzvLDLRMSVF4Vp0PRXZwUBqfgvv/qKyJvVnmN 043uzM6J0ks7+16BhqOuATo= X-Google-Smtp-Source: AGHT+IFwwgx+syyl+INCM/H6kE9LSAfqzllwehbz0yaDBzrpmgHWO634CFjbGGijLLq3UK+kIjHYxQ== X-Received: by 2002:ac2:4c0b:0:b0:506:8d2a:565a with SMTP id t11-20020ac24c0b000000b005068d2a565amr2574496lfq.69.1697869346720; Fri, 20 Oct 2023 23:22:26 -0700 (PDT) Received: from archlinux.localnet (82-149-12-148.dynamic.telemach.net. [82.149.12.148]) by smtp.gmail.com with ESMTPSA id w10-20020adfec4a000000b0032d2f09d991sm3064840wrn.33.2023.10.20.23.22.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 20 Oct 2023 23:22:26 -0700 (PDT) From: Jernej =?utf-8?B?xaBrcmFiZWM=?= To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Samuel Holland , Chen-Yu Tsai , Andre Przywara Cc: Marc Zyngier , Piotr Oniszczuk , linux-sunxi@lists.linux.dev, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org Subject: Re: [PATCH 2/2] arm64: dts: allwinner: h616: add Orange Pi Zero 2W support Date: Sat, 21 Oct 2023 08:22:24 +0200 Message-ID: <7582185.EvYhyI6sBW@archlinux> In-Reply-To: <20231020145706.705420-3-andre.przywara@arm.com> References: <20231020145706.705420-1-andre.przywara@arm.com> <20231020145706.705420-3-andre.przywara@arm.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20231020_232230_121914_51206CF6 X-CRM114-Status: GOOD ( 25.81 ) 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: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Friday, October 20, 2023 4:57:06 PM CEST Andre Przywara wrote: > The Orange Pi Zero 2W is a board based on the Allwinner H618 SoC. > It uses the RaspberryPi Zero form factor, with an optional expansion > board, connected via an FPC connector, to provide more connectors. > > The base board features: > - Allwinner H618 SoC (quad Cortex-A53 cores, with 1MB L2 cache) > - 1, 2 or 4GB of LPDDR4 DRAM > - SD card socket > - two USB-C sockets, one UFP, one DFP > - HDMI connector > - (yet unsupported) WiFi module > - 16 MiB SPI flash > - power supply via the UFP USB-C port > > The FPC connector provides access to two more USB host ports, Fast > Ethernet, some GPIOs, Audio Line out and the IR receiver pin. > > Signed-off-by: Andre Przywara I compared it to the schematic and all values looks good. Sadly, it missed merge window. Reviewed-by: Jernej Skrabec Best regards, Jernej > --- > .../allwinner/sun50i-h618-orangepi-zero2w.dts | 176 ++++++++++++++++++ > 1 file changed, 176 insertions(+) > create mode 100644 > arch/arm64/boot/dts/allwinner/sun50i-h618-orangepi-zero2w.dts > > diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h618-orangepi-zero2w.dts > b/arch/arm64/boot/dts/allwinner/sun50i-h618-orangepi-zero2w.dts new file > mode 100644 > index 0000000000000..21ca1977055d9 > --- /dev/null > +++ b/arch/arm64/boot/dts/allwinner/sun50i-h618-orangepi-zero2w.dts > @@ -0,0 +1,176 @@ > +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) > +/* > + * Copyright (C) 2023 Arm Ltd. > + */ > + > +/dts-v1/; > + > +#include "sun50i-h616.dtsi" > + > +#include > +#include > +#include > + > +/ { > + model = "OrangePi Zero 2W"; > + compatible = "xunlong,orangepi-zero2w", "allwinner,sun50i-h618"; > + > + aliases { > + serial0 = &uart0; > + }; > + > + chosen { > + stdout-path = "serial0:115200n8"; > + }; > + > + leds { > + compatible = "gpio-leds"; > + > + led-0 { > + function = LED_FUNCTION_STATUS; > + color = ; > + gpios = <&pio 2 13 GPIO_ACTIVE_HIGH>; /* PC13 */ > + }; > + }; > + > + reg_vcc5v: vcc5v { > + /* board wide 5V supply directly from the USB-C socket */ > + compatible = "regulator-fixed"; > + regulator-name = "vcc-5v"; > + regulator-min-microvolt = <5000000>; > + regulator-max-microvolt = <5000000>; > + regulator-always-on; > + }; > + > + reg_vcc3v3: vcc3v3 { > + /* SY8089 DC/DC converter */ > + compatible = "regulator-fixed"; > + regulator-name = "vcc-3v3"; > + regulator-min-microvolt = <3300000>; > + regulator-max-microvolt = <3300000>; > + vin-supply = <®_vcc5v>; > + regulator-always-on; > + }; > +}; > + > +&ehci1 { > + status = "okay"; > +}; > + > +/* USB 2 & 3 are on the FPC connector (or the exansion board) */ > + > +&mmc0 { > + cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; /* PF6 */ > + bus-width = <4>; > + vmmc-supply = <®_vcc3v3>; > + status = "okay"; > +}; > + > +&ohci1 { > + status = "okay"; > +}; > + > +&pio { > + vcc-pc-supply = <®_dldo1>; > + vcc-pf-supply = <®_dldo1>; /* internally via VCC-IO */ > + vcc-pg-supply = <®_aldo1>; > + vcc-ph-supply = <®_dldo1>; /* internally via VCC-IO */ > + vcc-pi-supply = <®_dldo1>; > +}; > + > +&r_i2c { > + status = "okay"; > + > + axp313: pmic@36 { > + compatible = "x-powers,axp313a"; > + reg = <0x36>; > + #interrupt-cells = <1>; > + interrupt-controller; > + interrupt-parent = <&pio>; > + interrupts = <2 9 IRQ_TYPE_LEVEL_LOW>; /* PC9 */ > + > + vin1-supply = <®_vcc5v>; > + vin2-supply = <®_vcc5v>; > + vin3-supply = <®_vcc5v>; > + > + regulators { > + /* Supplies VCC-PLL and DRAM */ > + reg_aldo1: aldo1 { > + regulator-always-on; > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <1800000>; > + regulator-name = "vcc1v8"; > + }; > + > + /* Supplies VCC-IO, so needs to be always on. */ > + reg_dldo1: dldo1 { > + regulator-always-on; > + regulator-min-microvolt = <3300000>; > + regulator-max-microvolt = <3300000>; > + regulator-name = "vcc3v3"; > + }; > + > + reg_dcdc1: dcdc1 { > + regulator-always-on; > + regulator-min-microvolt = <810000>; > + regulator-max-microvolt = <990000>; > + regulator-name = "vdd-gpu-sys"; > + }; > + > + reg_dcdc2: dcdc2 { > + regulator-always-on; > + regulator-min-microvolt = <810000>; > + regulator-max-microvolt = <1100000>; > + regulator-name = "vdd-cpu"; > + }; > + > + reg_dcdc3: dcdc3 { > + regulator-always-on; > + regulator-min-microvolt = <1100000>; > + regulator-max-microvolt = <1100000>; > + regulator-name = "vdd-dram"; > + }; > + }; > + }; > +}; > + > +&spi0 { > + status = "okay"; > + pinctrl-names = "default"; > + pinctrl-0 = <&spi0_pins>, <&spi0_cs0_pin>; > + > + flash@0 { > + #address-cells = <1>; > + #size-cells = <1>; > + compatible = "jedec,spi-nor"; > + reg = <0>; > + spi-max-frequency = <40000000>; > + }; > +}; > + > +&uart0 { > + pinctrl-names = "default"; > + pinctrl-0 = <&uart0_ph_pins>; > + status = "okay"; > +}; > + > +&usbotg { > + /* > + * PHY0 pins are connected to a USB-C socket, but a role switch > + * is not implemented: both CC pins are pulled to GND. > + * The VBUS pins power the device, so a fixed peripheral mode > + * is the best choice. > + * The board can be powered via GPIOs, in this case port0 *can* > + * act as a host (with a cable/adapter ignoring CC), as VBUS is > + * then provided by the GPIOs. Any user of this setup would > + * need to adjust the DT accordingly: dr_mode set to "host", > + * enabling OHCI0 and EHCI0. > + */ > + dr_mode = "peripheral"; > + status = "okay"; > +}; > + > +&usbphy { > + usb1_vbus-supply = <®_vcc5v>; > + status = "okay"; > +}; _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel