Received: by 10.192.165.148 with SMTP id m20csp4430704imm; Tue, 24 Apr 2018 02:36:10 -0700 (PDT) X-Google-Smtp-Source: AIpwx4+WEXRqCWqXEcBoTa/RwM9SEwN5EKJdLxecwETzoewk738mjBfl/U8UF5x0VsSkg4WoooFJ X-Received: by 10.99.149.10 with SMTP id p10mr19543390pgd.217.1524562570343; Tue, 24 Apr 2018 02:36:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524562570; cv=none; d=google.com; s=arc-20160816; b=qsBylQbPiQbYNcplafEyAnUspQpkmRJ0oiFROVBwSOqH4vZ+7I4vvGWwpAUU1la45W pwGcbaT9hY5DdJdP3Bly9rAXaMq2hsPPt0mhTVdjYTQpm2dfoOX5lZ62wyqmtPlM23pB zLD8Hjv5tYdYsmwn3Va2P/w+2N2X5OFZJeZd96GNsiZ58OcHTI6sAq3njNlRFLMPohuQ DC3d/5kGQxTGzoEEwRj2rHco+7mH1coiaRRfRvq78GaVsA3OL4wNaTjEN4LosV2omWND NNztJUGHsEnNpAbdST0di+WUKKTKapjVBBFsFItGreFt394+pSS9pFvEtdR8xmxLVfqF 4zeA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=2F9A/6Vuqd7m1lcQhDmRK9+FVF2oktunCt+k8psWFOw=; b=lMY1znhXsc/XCl5d3zVk6e0ZgMfsW0gRj/bYz72jsVWEs0USUeyONnrH7Ybl4KFBdI 73138PxAkcgI+WthrfGiM77mKUBHFEmxffKW6M6KyoPDBQisXc+jas30Go0adKiiLsIb Ea5wJ1RSqnCk+0RwaackOUy/4wJk46jQZLhopundPmrM4RwyDj9OVLwW2OTIy5+0BT8X XisU49ok8GHhpheUvyAokSG5IyyO5Dok6UPorSQ6pkXzuEsY3C4IXB94GRp4tMLGkP8G zjSLSj8+MO2FXd1MOOMdbLxAWhttHJKDe40MGkRWO0xXlDAEzBuWphA9Os7QAw9ddMSq +MsA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=Bism4BES; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b19si9547159pfh.358.2018.04.24.02.35.56; Tue, 24 Apr 2018 02:36:10 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=Bism4BES; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755784AbeDXJVB (ORCPT + 99 others); Tue, 24 Apr 2018 05:21:01 -0400 Received: from mail-wr0-f196.google.com ([209.85.128.196]:35233 "EHLO mail-wr0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932259AbeDXJTo (ORCPT ); Tue, 24 Apr 2018 05:19:44 -0400 Received: by mail-wr0-f196.google.com with SMTP id w3-v6so48658793wrg.2 for ; Tue, 24 Apr 2018 02:19:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=2F9A/6Vuqd7m1lcQhDmRK9+FVF2oktunCt+k8psWFOw=; b=Bism4BESnPq4bFz6udp7KwN45UCtKbyXSI91D904UW1mBSXWnCSkg+MErGY9D/8E5x 8IonDJl2caIHWfzEGh+SnZmulb16pZe9FLgYJg7M0q5JpucNRxxWJzUQ4lZYnF5qFOLN R3Xdz+fh9TaxHavcfOKJ3RAgOVs6vdv7vIC6uHjMf+Q148Megdq0K24OIUnrYaycUIrY azP8U1MyVHFjS8QN9/fZHBXzln8Mb3EUTIxTP3ZVHYvV9A7iWZ7UcaCzU4JJHTZcprt0 jQ6luxoNECAkeBzpOVl+h/XsUvGN7+mLEg0Ty2ZGTPLBBqUzzVnjEVRn12XPj4XpfJaN G0Jg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=2F9A/6Vuqd7m1lcQhDmRK9+FVF2oktunCt+k8psWFOw=; b=rUk2RDVIAQKCtxHVuy74OH0A6hltkX8PzcoFd9SW2nsAHPSU4rx68qSqfGYKUpTYc8 dXqe/vJoB9jfbIUzCGSsFmczB1x+yg+JWO2SRPCXVJ5CpjRgL9CAQYd5HUcgy97Yh3mi FSpWpmukHRETKKORJTeF6xdlX35/9sfrKU4eLPkrIQBqzbLAZkpIqyoifAwmMSYUL7rt Njucwt72fawMbxvctc7kYiqhxuWLk06k2K1zIOnT9SWPfHIUjjSLIHdGS5YZEnRhcI2w 1utN9gOoPCUh8+R3JK6dcA987s1lgIX+D3qEbRQkYTgaczPB6GfGs5AZ9FereJ22qH8f V9Rg== X-Gm-Message-State: ALQs6tBccBhb58/VSjMMSaMQB5gplg4P2++9Ap3Z8mCKWStRWjnTUbFQ zrszQl6+ktmNw6eEyf9RSf1Z2Q== X-Received: by 2002:adf:9e06:: with SMTP id u6-v6mr20472364wre.142.1524561583196; Tue, 24 Apr 2018 02:19:43 -0700 (PDT) Received: from bender.baylibre.local ([90.63.244.31]) by smtp.gmail.com with ESMTPSA id s22sm11805525wma.45.2018.04.24.02.19.42 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 24 Apr 2018 02:19:42 -0700 (PDT) From: Neil Armstrong To: maxime.ripard@bootlin.com, wens@csie.org Cc: Neil Armstrong , clabbe@baylibre.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/2] ARM: dts: sun8i-h3-libretech-all-h3-cc: Move board definition to common dtsi Date: Tue, 24 Apr 2018 11:19:35 +0200 Message-Id: <1524561576-2201-2-git-send-email-narmstrong@baylibre.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1524561576-2201-1-git-send-email-narmstrong@baylibre.com> References: <1524561576-2201-1-git-send-email-narmstrong@baylibre.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Since the libretech-all-h3-cc can use either the H2+, H3 or H5, move the content of the dts file to a common dtsi file to be included by the H3 variant and in a following patch the H5 variant. By the way, update the SPDX licence tag position. Suggested-by: Corentin Labbe Signed-off-by: Neil Armstrong --- arch/arm/boot/dts/sun8i-h3-libretech-all-h3-cc.dts | 209 +------------------- arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi | 211 +++++++++++++++++++++ 2 files changed, 213 insertions(+), 207 deletions(-) create mode 100644 arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi diff --git a/arch/arm/boot/dts/sun8i-h3-libretech-all-h3-cc.dts b/arch/arm/boot/dts/sun8i-h3-libretech-all-h3-cc.dts index b20a710..50f2fb3 100644 --- a/arch/arm/boot/dts/sun8i-h3-libretech-all-h3-cc.dts +++ b/arch/arm/boot/dts/sun8i-h3-libretech-all-h3-cc.dts @@ -1,218 +1,13 @@ +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) /* * Copyright (C) 2017 Chen-Yu Tsai - * - * SPDX-License-Identifier: (GPL-2.0+ OR MIT) */ /dts-v1/; #include "sun8i-h3.dtsi" - -#include -#include +#include "sunxi-libretech-all-h3-cc.dtsi" / { model = "Libre Computer Board ALL-H3-CC H3"; compatible = "libretech,all-h3-cc-h3", "allwinner,sun8i-h3"; - - aliases { - ethernet0 = &emac; - serial0 = &uart0; - }; - - chosen { - stdout-path = "serial0:115200n8"; - }; - - connector { - compatible = "hdmi-connector"; - type = "a"; - - port { - hdmi_con_in: endpoint { - remote-endpoint = <&hdmi_out_con>; - }; - }; - }; - - leds { - compatible = "gpio-leds"; - - pwr_led { - label = "librecomputer:green:pwr"; - gpios = <&r_pio 0 10 GPIO_ACTIVE_HIGH>; /* PL10 */ - default-state = "on"; - }; - - status_led { - label = "librecomputer:blue:status"; - gpios = <&pio 0 7 GPIO_ACTIVE_HIGH>; /* PA7 */ - }; - }; - - gpio_keys { - compatible = "gpio-keys"; - - power { - label = "power"; - linux,code = ; - gpios = <&r_pio 0 2 GPIO_ACTIVE_LOW>; /* PL2 */ - }; - }; - - reg_vcc1v2: vcc1v2 { - compatible = "regulator-fixed"; - regulator-name = "vcc1v2"; - regulator-min-microvolt = <3300000>; - regulator-max-microvolt = <3300000>; - regulator-always-on; - regulator-boot-on; - vin-supply = <®_vcc5v0>; - gpio = <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */ - enable-active-high; - }; - - reg_vcc3v3: vcc3v3 { - compatible = "regulator-fixed"; - regulator-name = "vcc3v3"; - regulator-min-microvolt = <3300000>; - regulator-max-microvolt = <3300000>; - vin-supply = <®_vcc5v0>; - }; - - /* This represents the board's 5V input */ - reg_vcc5v0: vcc5v0 { - compatible = "regulator-fixed"; - regulator-name = "vcc5v0"; - regulator-min-microvolt = <5000000>; - regulator-max-microvolt = <5000000>; - }; - - reg_vcc_dram: vcc-dram { - compatible = "regulator-fixed"; - regulator-name = "vcc-dram"; - regulator-min-microvolt = <1500000>; - regulator-max-microvolt = <1500000>; - regulator-always-on; - regulator-boot-on; - vin-supply = <®_vcc5v0>; - gpio = <&r_pio 0 9 GPIO_ACTIVE_HIGH>; /* PL9 */ - enable-active-high; - }; - - reg_vcc_io: vcc-io { - compatible = "regulator-fixed"; - regulator-name = "vcc-io"; - regulator-min-microvolt = <3300000>; - regulator-max-microvolt = <3300000>; - regulator-always-on; - regulator-boot-on; - vin-supply = <®_vcc3v3>; - gpio = <&r_pio 0 5 GPIO_ACTIVE_LOW>; /* PL5 */ - }; - - reg_vdd_cpux: vdd-cpux { - compatible = "regulator-fixed"; - regulator-name = "vdd-cpux"; - regulator-min-microvolt = <3300000>; - regulator-max-microvolt = <3300000>; - regulator-always-on; - regulator-boot-on; - vin-supply = <®_vcc5v0>; - gpio = <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */ - enable-active-high; - }; -}; - -&codec { - allwinner,audio-routing = - "Line Out", "LINEOUT", - "MIC1", "Mic", - "Mic", "MBIAS"; - status = "okay"; -}; - -&de { - status = "okay"; -}; - -&ehci0 { - status = "okay"; -}; - -&ehci1 { - status = "okay"; -}; - -&ehci2 { - status = "okay"; -}; - -&ehci3 { - status = "okay"; -}; - -&emac { - phy-handle = <&int_mii_phy>; - phy-mode = "mii"; - allwinner,leds-active-low; - status = "okay"; -}; - -&hdmi { - status = "okay"; -}; - -&hdmi_out { - hdmi_out_con: endpoint { - remote-endpoint = <&hdmi_con_in>; - }; -}; - -&ir { - pinctrl-names = "default"; - pinctrl-0 = <&ir_pins_a>; - status = "okay"; -}; - -&mmc0 { - vmmc-supply = <®_vcc_io>; - bus-width = <4>; - cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; /* PF6 */ - status = "okay"; -}; - -&ohci0 { - status = "okay"; -}; - -&ohci1 { - status = "okay"; -}; - -&ohci2 { - status = "okay"; -}; - -&ohci3 { - status = "okay"; -}; - -&uart0 { - pinctrl-names = "default"; - pinctrl-0 = <&uart0_pins_a>; - status = "okay"; -}; - -&usb_otg { - dr_mode = "host"; - status = "okay"; -}; - -&usbphy { - /* VBUS on USB ports are always on */ - usb0_vbus-supply = <®_vcc5v0>; - usb1_vbus-supply = <®_vcc5v0>; - usb2_vbus-supply = <®_vcc5v0>; - usb3_vbus-supply = <®_vcc5v0>; - status = "okay"; }; diff --git a/arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi b/arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi new file mode 100644 index 0000000..ff42c16 --- /dev/null +++ b/arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi @@ -0,0 +1,211 @@ +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) +/* + * Copyright (C) 2017 Chen-Yu Tsai + */ + +#include +#include + +/ { + aliases { + ethernet0 = &emac; + serial0 = &uart0; + }; + + chosen { + stdout-path = "serial0:115200n8"; + }; + + connector { + compatible = "hdmi-connector"; + type = "a"; + + port { + hdmi_con_in: endpoint { + remote-endpoint = <&hdmi_out_con>; + }; + }; + }; + + leds { + compatible = "gpio-leds"; + + pwr_led { + label = "librecomputer:green:pwr"; + gpios = <&r_pio 0 10 GPIO_ACTIVE_HIGH>; /* PL10 */ + default-state = "on"; + }; + + status_led { + label = "librecomputer:blue:status"; + gpios = <&pio 0 7 GPIO_ACTIVE_HIGH>; /* PA7 */ + }; + }; + + gpio_keys { + compatible = "gpio-keys"; + + power { + label = "power"; + linux,code = ; + gpios = <&r_pio 0 2 GPIO_ACTIVE_LOW>; /* PL2 */ + }; + }; + + reg_vcc1v2: vcc1v2 { + compatible = "regulator-fixed"; + regulator-name = "vcc1v2"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + regulator-always-on; + regulator-boot-on; + vin-supply = <®_vcc5v0>; + gpio = <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */ + enable-active-high; + }; + + reg_vcc3v3: vcc3v3 { + compatible = "regulator-fixed"; + regulator-name = "vcc3v3"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + vin-supply = <®_vcc5v0>; + }; + + /* This represents the board's 5V input */ + reg_vcc5v0: vcc5v0 { + compatible = "regulator-fixed"; + regulator-name = "vcc5v0"; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + }; + + reg_vcc_dram: vcc-dram { + compatible = "regulator-fixed"; + regulator-name = "vcc-dram"; + regulator-min-microvolt = <1500000>; + regulator-max-microvolt = <1500000>; + regulator-always-on; + regulator-boot-on; + vin-supply = <®_vcc5v0>; + gpio = <&r_pio 0 9 GPIO_ACTIVE_HIGH>; /* PL9 */ + enable-active-high; + }; + + reg_vcc_io: vcc-io { + compatible = "regulator-fixed"; + regulator-name = "vcc-io"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + regulator-always-on; + regulator-boot-on; + vin-supply = <®_vcc3v3>; + gpio = <&r_pio 0 5 GPIO_ACTIVE_LOW>; /* PL5 */ + }; + + reg_vdd_cpux: vdd-cpux { + compatible = "regulator-fixed"; + regulator-name = "vdd-cpux"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + regulator-always-on; + regulator-boot-on; + vin-supply = <®_vcc5v0>; + gpio = <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */ + enable-active-high; + }; +}; + +&codec { + allwinner,audio-routing = + "Line Out", "LINEOUT", + "MIC1", "Mic", + "Mic", "MBIAS"; + status = "okay"; +}; + +&de { + status = "okay"; +}; + +&ehci0 { + status = "okay"; +}; + +&ehci1 { + status = "okay"; +}; + +&ehci2 { + status = "okay"; +}; + +&ehci3 { + status = "okay"; +}; + +&emac { + phy-handle = <&int_mii_phy>; + phy-mode = "mii"; + allwinner,leds-active-low; + status = "okay"; +}; + +&hdmi { + status = "okay"; +}; + +&hdmi_out { + hdmi_out_con: endpoint { + remote-endpoint = <&hdmi_con_in>; + }; +}; + +&ir { + pinctrl-names = "default"; + pinctrl-0 = <&ir_pins_a>; + status = "okay"; +}; + +&mmc0 { + vmmc-supply = <®_vcc_io>; + bus-width = <4>; + cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; /* PF6 */ + status = "okay"; +}; + +&ohci0 { + status = "okay"; +}; + +&ohci1 { + status = "okay"; +}; + +&ohci2 { + status = "okay"; +}; + +&ohci3 { + status = "okay"; +}; + +&uart0 { + pinctrl-names = "default"; + pinctrl-0 = <&uart0_pins_a>; + status = "okay"; +}; + +&usb_otg { + dr_mode = "host"; + status = "okay"; +}; + +&usbphy { + /* VBUS on USB ports are always on */ + usb0_vbus-supply = <®_vcc5v0>; + usb1_vbus-supply = <®_vcc5v0>; + usb2_vbus-supply = <®_vcc5v0>; + usb3_vbus-supply = <®_vcc5v0>; + status = "okay"; +}; -- 2.7.4