From: Shawn Guo <shawn.guo@linaro.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v3 3/3] poplar: enable Ethernet driver support
Date: Wed, 20 Mar 2019 11:28:28 +0800 [thread overview]
Message-ID: <20190320032826.GB27952@dragon> (raw)
In-Reply-To: <CANr=Z=a5Do_F0EkpRWopJg3t0cQLNZWKUaemdw9WKTwksA9LGg@mail.gmail.com>
On Tue, Mar 19, 2019 at 06:42:17PM +0000, Joe Hershberger wrote:
> On Sun, Mar 10, 2019 at 3:53 AM Shawn Guo <shawn.guo@linaro.org> wrote:
> >
> > The 'phy' reset of gmac device in kernel device tree is not generic
> > enough for u-boot to use, so we need to overwrite the 'resets' property
> > as needed. With this device tree fixup and poplar_defconfig changes,
> > Ethernet starts working on Poplar board.
> >
> > Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
> > Reviewed-by: Igor Opaniuk <igor.opaniuk@linaro.org>
> > ---
> > arch/arm/dts/hi3798cv200-u-boot.dtsi | 14 ++++++++++++++
> > configs/poplar_defconfig | 3 +++
> > 2 files changed, 17 insertions(+)
> >
> > diff --git a/arch/arm/dts/hi3798cv200-u-boot.dtsi b/arch/arm/dts/hi3798cv200-u-boot.dtsi
> > index 7844c5208c5d..2ca943f64e59 100644
> > --- a/arch/arm/dts/hi3798cv200-u-boot.dtsi
> > +++ b/arch/arm/dts/hi3798cv200-u-boot.dtsi
> > @@ -8,7 +8,15 @@
> > * (C) Copyright 2017 Jorge Ramirez-Ortiz <jorge.ramirez-ortiz@linaro.org>
> > */
> >
> > +#include <dt-bindings/reset/hisi-reset.h>
>
> Where does this file come from?
>
> > +
> > &soc {
> > + rst: reset-controller at 8a22000 {
> > + compatible = "hisilicon,hi3798cv200-reset";
> > + reg = <0x8a22000 0x1000>;
>
> Would it not be reasonable to include the "0xcc" from below in this
> address instead of adding them at runtime?
In that case, if we have new client devices using other registers in the
reset controller, we will need to have multiple such nodes to be
defined. This is less efficient and doesn't describe HW design well.
Shawn
>
>
> > + #reset-cells = <3>;
> > + };
> > +
> > usb2: ehci at 9890000 {
> > compatible = "generic-ehci";
> > reg = <0x9890000 0x100>;
> > @@ -16,6 +24,12 @@
> > };
> > };
> >
> > +&gmac1 {
> > + resets = <&rst 0xcc 9 HISI_RESET_ACTIVE_HIGH>,
> > + <&rst 0xcc 11 HISI_RESET_ACTIVE_HIGH>,
> > + <&rst 0xcc 13 HISI_RESET_ACTIVE_LOW>;
> > +};
> > +
> > &uart0 {
> > clock = <75000000>;
> > status = "okay";
> > diff --git a/configs/poplar_defconfig b/configs/poplar_defconfig
> > index 81bd3702e42a..76ab5eb70e7e 100644
> > --- a/configs/poplar_defconfig
> > +++ b/configs/poplar_defconfig
> > @@ -19,6 +19,9 @@ CONFIG_FASTBOOT_FLASH_MMC_DEV=0
> > CONFIG_DM_MMC=y
> > CONFIG_MMC_DW=y
> > CONFIG_MMC_DW_K3=y
> > +CONFIG_DM_ETH=y
> > +CONFIG_HIGMACV300_ETH=y
> > +CONFIG_RESET_HISILICON=y
> > CONFIG_USB=y
> > CONFIG_USB_EHCI_HCD=y
> > CONFIG_USB_EHCI_GENERIC=y
> > --
> > 2.18.0
> >
> > _______________________________________________
> > U-Boot mailing list
> > U-Boot at lists.denx.de
> > https://lists.denx.de/listinfo/u-boot
next prev parent reply other threads:[~2019-03-20 3:28 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-10 8:51 [U-Boot] [PATCH v3 0/3] Add Ethernet support for Poplar board Shawn Guo
2019-03-10 8:51 ` [U-Boot] [PATCH v3 1/3] reset: add reset driver for HiSilicon platform Shawn Guo
2019-03-19 18:42 ` Joe Hershberger
2019-03-20 3:13 ` Shawn Guo
2019-03-10 8:51 ` [U-Boot] [PATCH v3 2/3] net: add higmacv300 Ethernet " Shawn Guo
2019-03-19 18:41 ` Joe Hershberger
2019-03-10 8:51 ` [U-Boot] [PATCH v3 3/3] poplar: enable Ethernet driver support Shawn Guo
2019-03-19 18:42 ` Joe Hershberger
2019-03-20 3:28 ` Shawn Guo [this message]
2019-03-19 8:31 ` [U-Boot] [PATCH v3 0/3] Add Ethernet support for Poplar board Shawn Guo
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=20190320032826.GB27952@dragon \
--to=shawn.guo@linaro.org \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox