All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jagan Teki <jagannadh.teki@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v4 13/19] sunxi: DT: A64: update board .dts files from Linux
Date: Fri, 23 Mar 2018 23:44:13 +0530	[thread overview]
Message-ID: <CAD6G_RRukdWS_NCe9+7hzcWOgZXz9Vc6CCchfaV4aD2DwK-LCQ@mail.gmail.com> (raw)
In-Reply-To: <20180314015715.15615-14-andre.przywara@arm.com>

On Wed, Mar 14, 2018 at 7:27 AM, Andre Przywara <andre.przywara@arm.com> wrote:
> Update the .dts files for the various boards with an Allwinner A64 SoC.
> This is as of v4.15-rc9, exactly Linux commit:
> commit bdfe4cebea11476d278b1b98dd0f7cdac8269d62
> Author: Icenowy Zheng <icenowy@aosc.io>
> Date:   Fri Nov 10 17:26:54 2017 +0800
>     arm64: allwinner: a64: add Ethernet PHY regulator for several boards
>
> It updates the existing DT files, adds the newly added axp803.dtsi and
> removes our temporary kludge file to get Ethernet support in U-Boot.
>
> Signed-off-by: Andre Przywara <andre.przywara@arm.com>
> Acked-by: Maxime Ripard <maxime.ripard@bootlin.com>
> ---
>  arch/arm/dts/axp803.dtsi                        | 150 ++++++++++++++++++++
>  arch/arm/dts/sun50i-a64-bananapi-m64.dts        | 161 +++++++++++++++++++--
>  arch/arm/dts/sun50i-a64-nanopi-a64.dts          | 108 ++++++++++++--
>  arch/arm/dts/sun50i-a64-olinuxino.dts           | 131 +++++++++++++++--
>  arch/arm/dts/sun50i-a64-orangepi-win.dts        |   7 +-
>  arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi |  20 ---
>  arch/arm/dts/sun50i-a64-pine64-plus.dts         |  17 ++-
>  arch/arm/dts/sun50i-a64-pine64.dts              | 178 +++++++++++++++++++++++-
>  8 files changed, 716 insertions(+), 56 deletions(-)
>  create mode 100644 arch/arm/dts/axp803.dtsi
>  delete mode 100644 arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi
>
> diff --git a/arch/arm/dts/axp803.dtsi b/arch/arm/dts/axp803.dtsi
> new file mode 100644
> index 0000000000..ff8af52743
> --- /dev/null
> +++ b/arch/arm/dts/axp803.dtsi
> @@ -0,0 +1,150 @@
> +/*
> + * Copyright 2017 Icenowy Zheng <icenowy@aosc.xyz>
> + *
> + * This file is dual-licensed: you can use it either under the terms
> + * of the GPL or the X11 license, at your option. Note that this dual
> + * licensing only applies to this file, and not this project as a
> + * whole.
> + *
> + *  a) This file is free software; you can redistribute it and/or
> + *     modify it under the terms of the GNU General Public License as
> + *     published by the Free Software Foundation; either version 2 of the
> + *     License, or (at your option) any later version.
> + *
> + *     This file is distributed in the hope that it will be useful,
> + *     but WITHOUT ANY WARRANTY; without even the implied warranty of
> + *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
> + *     GNU General Public License for more details.
> + *
> + * Or, alternatively,
> + *
> + *  b) Permission is hereby granted, free of charge, to any person
> + *     obtaining a copy of this software and associated documentation
> + *     files (the "Software"), to deal in the Software without
> + *     restriction, including without limitation the rights to use,
> + *     copy, modify, merge, publish, distribute, sublicense, and/or
> + *     sell copies of the Software, and to permit persons to whom the
> + *     Software is furnished to do so, subject to the following
> + *     conditions:
> + *
> + *     The above copyright notice and this permission notice shall be
> + *     included in all copies or substantial portions of the Software.
> + *
> + *     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
> + *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
> + *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
> + *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
> + *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
> + *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
> + *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
> + *     OTHER DEALINGS IN THE SOFTWARE.
> + */
> +
> +/*
> + * AXP803 Integrated Power Management Chip
> + * http://files.pine64.org/doc/datasheet/pine64/AXP803_Datasheet_V1.0.pdf
> + */
> +
> +&axp803 {
> +       interrupt-controller;
> +       #interrupt-cells = <1>;
> +
> +       regulators {
> +               /* Default work frequency for buck regulators */
> +               x-powers,dcdc-freq = <3000>;
> +
> +               reg_aldo1: aldo1 {
> +                       regulator-name = "aldo1";
> +               };
> +
> +               reg_aldo2: aldo2 {
> +                       regulator-name = "aldo2";
> +               };
> +
> +               reg_aldo3: aldo3 {
> +                       regulator-name = "aldo3";
> +               };
> +
> +               reg_dc1sw: dc1sw {
> +                       regulator-name = "dc1sw";
> +               };
> +
> +               reg_dcdc1: dcdc1 {
> +                       regulator-name = "dcdc1";
> +               };
> +
> +               reg_dcdc2: dcdc2 {
> +                       regulator-name = "dcdc2";
> +               };
> +
> +               reg_dcdc3: dcdc3 {
> +                       regulator-name = "dcdc3";
> +               };
> +
> +               reg_dcdc4: dcdc4 {
> +                       regulator-name = "dcdc4";
> +               };
> +
> +               reg_dcdc5: dcdc5 {
> +                       regulator-name = "dcdc5";
> +               };
> +
> +               reg_dcdc6: dcdc6 {
> +                       regulator-name = "dcdc6";
> +               };
> +
> +               reg_dldo1: dldo1 {
> +                       regulator-name = "dldo1";
> +               };
> +
> +               reg_dldo2: dldo2 {
> +                       regulator-name = "dldo2";
> +               };
> +
> +               reg_dldo3: dldo3 {
> +                       regulator-name = "dldo3";
> +               };
> +
> +               reg_dldo4: dldo4 {
> +                       regulator-name = "dldo4";
> +               };
> +
> +               reg_eldo1: eldo1 {
> +                       regulator-name = "eldo1";
> +               };
> +
> +               reg_eldo2: eldo2 {
> +                       regulator-name = "eldo2";
> +               };
> +
> +               reg_eldo3: eldo3 {
> +                       regulator-name = "eldo3";
> +               };
> +
> +               reg_fldo1: fldo1 {
> +                       regulator-name = "fldo1";
> +               };
> +
> +               reg_fldo2: fldo2 {
> +                       regulator-name = "fldo2";
> +               };
> +
> +               reg_ldo_io0: ldo-io0 {
> +                       regulator-name = "ldo-io0";
> +                       status = "disabled";
> +               };
> +
> +               reg_ldo_io1: ldo-io1 {
> +                       regulator-name = "ldo-io1";
> +                       status = "disabled";
> +               };
> +
> +               reg_rtc_ldo: rtc-ldo {
> +                       /* RTC_LDO is a fixed, always-on regulator */
> +                       regulator-always-on;
> +                       regulator-min-microvolt = <3000000>;
> +                       regulator-max-microvolt = <3000000>;
> +                       regulator-name = "rtc-ldo";
> +               };
> +       };
> +};
> diff --git a/arch/arm/dts/sun50i-a64-bananapi-m64.dts b/arch/arm/dts/sun50i-a64-bananapi-m64.dts
> index 02db114113..4a8d3f83a3 100644
> --- a/arch/arm/dts/sun50i-a64-bananapi-m64.dts
> +++ b/arch/arm/dts/sun50i-a64-bananapi-m64.dts
> @@ -1,6 +1,5 @@
>  /*
>   * Copyright (c) 2016 ARM Ltd.
> - * Copyright (C) 2017 Jagan Teki <jteki@openedev.com>
>   *
>   * This file is dual-licensed: you can use it either under the terms
>   * of the GPL or the X11 license, at your option. Note that this dual
> @@ -52,6 +51,7 @@
>         compatible = "sinovoip,bananapi-m64", "allwinner,sun50i-a64";
>
>         aliases {
> +               ethernet0 = &emac;
>                 serial0 = &uart0;
>                 serial1 = &uart1;
>         };
> @@ -60,14 +60,25 @@
>                 stdout-path = "serial0:115200n8";
>         };
>
> -       reg_vcc3v3: vcc3v3 {
> -               compatible = "regulator-fixed";
> -               regulator-name = "vcc3v3";
> -               regulator-min-microvolt = <3300000>;
> -               regulator-max-microvolt = <3300000>;
> +       wifi_pwrseq: wifi_pwrseq {
> +               compatible = "mmc-pwrseq-simple";
> +               reset-gpios = <&r_pio 0 2 GPIO_ACTIVE_LOW>; /* PL2 */
>         };
>  };
>
> +&ehci1 {
> +       status = "okay";
> +};
> +
> +&emac {
> +       pinctrl-names = "default";
> +       pinctrl-0 = <&rgmii_pins>;
> +       phy-mode = "rgmii";
> +       phy-handle = <&ext_rgmii_phy>;
> +       phy-supply = <&reg_dc1sw>;
> +       status = "okay";
> +};
> +
>  &i2c1 {
>         pinctrl-names = "default";
>         pinctrl-0 = <&i2c1_pins>;
> @@ -78,10 +89,17 @@
>         bias-pull-up;
>  };
>
> +&mdio {
> +       ext_rgmii_phy: ethernet-phy at 1 {
> +               compatible = "ethernet-phy-ieee802.3-c22";
> +               reg = <1>;
> +       };
> +};
> +
>  &mmc0 {
>         pinctrl-names = "default";
>         pinctrl-0 = <&mmc0_pins>;
> -       vmmc-supply = <&reg_vcc3v3>;
> +       vmmc-supply = <&reg_dcdc1>;
>         cd-gpios = <&pio 5 6 GPIO_ACTIVE_HIGH>;
>         cd-inverted;
>         disable-wp;
> @@ -92,22 +110,143 @@
>  &mmc1 {
>         pinctrl-names = "default";
>         pinctrl-0 = <&mmc1_pins>;
> -       vmmc-supply = <&reg_vcc3v3>;
> +       vmmc-supply = <&reg_dldo2>;
> +       vqmmc-supply = <&reg_dldo4>;
> +       mmc-pwrseq = <&wifi_pwrseq>;
>         bus-width = <4>;
>         non-removable;
>         status = "okay";
> +
> +       brcmf: wifi at 1 {
> +               reg = <1>;
> +               compatible = "brcm,bcm4329-fmac";
> +               interrupt-parent = <&r_pio>;
> +               interrupts = <0 3 IRQ_TYPE_LEVEL_LOW>; /* PL3 */
> +               interrupt-names = "host-wake";
> +       };
>  };
>
>  &mmc2 {
>         pinctrl-names = "default";
>         pinctrl-0 = <&mmc2_pins>;
> -       vmmc-supply = <&reg_vcc3v3>;
> +       vmmc-supply = <&reg_dcdc1>;

These AXP regulator stuff need to wait until the relevant driver
supported through dt otherwise moving to DM_MMC might fail to get the
regulator? [1]

[1] https://patchwork.ozlabs.org/patch/887405/

Jagan.

  reply	other threads:[~2018-03-23 18:14 UTC|newest]

Thread overview: 57+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-14  1:56 [U-Boot] [PATCH v4 00/19] sunxi: sync H3, H5, A64 DTs from mainline Linux Andre Przywara
2018-03-14  1:56 ` [U-Boot] [PATCH v4 01/19] sunxi: README.sunxi64: Add hint about non-debug of ARM Trusted Firmware Andre Przywara
2018-03-21 18:40   ` Jagan Teki
2018-03-21 19:03     ` André Przywara
2018-03-21 19:08       ` Jagan Teki
2018-03-21 19:23         ` André Przywara
2018-03-14  1:56 ` [U-Boot] [PATCH v4 02/19] sunxi: gpio: add missing compatible strings Andre Przywara
2018-03-14  1:56 ` [U-Boot] [PATCH v4 03/19] net: sun8i-emac: support new pinctrl DT bindings Andre Przywara
2018-03-14  1:57 ` [U-Boot] [PATCH v4 04/19] net: sun8i-emac: add support for new EMAC DT binding Andre Przywara
2018-03-14  1:57 ` [U-Boot] [PATCH v4 05/19] arm: dts: sunxi: update A64 to new EMAC binding Andre Przywara
2018-03-14  1:57 ` [U-Boot] [PATCH v4 06/19] arm: dts: sunxi: update H3 " Andre Przywara
2018-03-14  1:57 ` [U-Boot] [PATCH v4 07/19] arm: dts: sunxi: update H5 " Andre Przywara
2018-03-14  1:57 ` [U-Boot] [PATCH v4 08/19] net: sun8i-emac: remove support for old binding Andre Przywara
2018-03-14  1:57 ` [U-Boot] [PATCH v4 09/19] sunxi: disable direct MMC environment Andre Przywara
2018-03-14  7:17   ` Maxime Ripard
2018-03-14  1:57 ` [U-Boot] [PATCH v4 10/19] sunxi: revert disabling of features Andre Przywara
2018-03-14  1:57 ` [U-Boot] [PATCH v4 11/19] Revert "sunxi: Pine64: temporarily remove extra Pine64 non-plus DT" Andre Przywara
2018-03-14  7:17   ` Maxime Ripard
2018-03-14  1:57 ` [U-Boot] [PATCH v4 12/19] sunxi: DT: A64: update device tree file for Allwinner A64 SoC Andre Przywara
2018-03-14  1:57 ` [U-Boot] [PATCH v4 13/19] sunxi: DT: A64: update board .dts files from Linux Andre Przywara
2018-03-23 18:14   ` Jagan Teki [this message]
2018-03-24  1:07     ` André Przywara
2018-03-27 14:30       ` Maxime Ripard
2018-03-27 14:43         ` Andre Przywara
2018-03-27 17:46           ` Jagan Teki
2018-03-30  4:25           ` [U-Boot] [linux-sunxi] " Chen-Yu Tsai
2018-04-01  1:28             ` André Przywara
2018-04-01  2:41               ` Chen-Yu Tsai
2018-05-08 10:34                 ` Jagan Teki
2018-05-08 13:15                   ` Andre Przywara
2018-07-04  6:54                     ` Jagan Teki
2018-03-27 17:58       ` [U-Boot] " Jagan Teki
2018-03-27 22:53         ` André Przywara
2018-03-28  9:52           ` Jagan Teki
2018-03-28 11:15             ` Maxime Ripard
2018-03-28 17:59               ` Jagan Teki
2018-03-29  9:07                 ` Maxime Ripard
2018-03-29  9:30                   ` Jagan Teki
2018-03-28 13:52             ` Andre Przywara
2018-03-14  1:57 ` [U-Boot] [PATCH v4 14/19] sunxi: DT: update device tree files for Allwinner H3 and H5 SoCs Andre Przywara
2018-03-14  1:57 ` [U-Boot] [PATCH v4 15/19] sunxi: DT: H5: update board .dts files from Linux Andre Przywara
2018-03-14  1:57 ` [U-Boot] [PATCH v4 16/19] sunxi: DT: H3: " Andre Przywara
2018-03-14  1:57 ` [U-Boot] [PATCH v4 17/19] sunxi: DT: H3: update libre-cc board .dts file Andre Przywara
2018-03-14  1:57 ` [U-Boot] [PATCH v4 18/19] sunxi: DT: H2+: update Opi-zero .dts Andre Przywara
2018-03-14  1:57 ` [U-Boot] [PATCH v4 19/19] sunxi: DT: A64: add proper SoPine baseboard device tree Andre Przywara
2018-03-29  8:51 ` [U-Boot] [PATCH v4 00/19] sunxi: sync H3, H5, A64 DTs from mainline Linux Jagan Teki
2018-03-29  9:06   ` Maxime Ripard
2018-03-29  9:19   ` Andre Przywara
2018-03-29  9:30     ` Maxime Ripard
2018-04-02  7:40     ` Jagan Teki
2018-04-02 11:20       ` Mark Kettenis
2018-04-02 11:51         ` André Przywara
2018-04-02 12:47           ` Mark Kettenis
2018-04-02 15:14             ` André Przywara
2018-04-02 19:06               ` Mark Kettenis
2018-04-02 11:39       ` André Przywara
2018-04-03 17:14 ` Jagan Teki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAD6G_RRukdWS_NCe9+7hzcWOgZXz9Vc6CCchfaV4aD2DwK-LCQ@mail.gmail.com \
    --to=jagannadh.teki@gmail.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.