public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Andre Przywara <andre.przywara@arm.com>
To: u-boot@lists.denx.de
Subject: [PATCH 1/3] net: Add support for Broadcom GENETv5 Ethernet controller
Date: Fri, 20 Dec 2019 15:47:52 +0000	[thread overview]
Message-ID: <20191220154752.30501d4b@donnerap.cambridge.arm.com> (raw)
In-Reply-To: <0a23bcd9-be1f-c6b9-d9d5-85e2f70cff26@gmail.com>

On Thu, 19 Dec 2019 13:58:24 +0100
Daniel Schwierzeck <daniel.schwierzeck@gmail.com> wrote:

Hi Daniel,

> Am 19.12.19 um 12:42 schrieb Andre Przywara:
> > On Thu, 19 Dec 2019 12:32:06 +0100
> > Daniel Schwierzeck <daniel.schwierzeck@gmail.com> wrote:
> > 
> > Hi Daniel,
> > 
> > many thanks for your valuable comments! Do you have access to a MIPS board using a GENETv5 MAC? I would be very curious to see if the driver works there, and am happy to make adjustments.  
> 
> No, I have not. I was only triggered by your commit message that this
> MAC is also used on some MIPS based Broadcom SoC's ;)

Well, actually I am not sure about it, I just saw *previous* generations (up to v3) used in MIPS .dts files in the kernel. Might as well be that v5 was never used with a MIPS core.
 
> > Does your board use a PHY connected via RGMII? Because this is something we are relying on at the moment. But without any ways of testing this I'd rather not support other transports at this time.
> > 
> > I think your points below are all valid, so thanks for bringing this up. Will test this later on and post a v2 in due time then.
> >   
> 
> We had a similar scenario a few months ago, where a newly supported ARM
> based Broadcom SoC could simply reuse various drivers initially added
> for MIPS based Broadcom SoC's. So if someone wants to use your driver
> with a MIPS based Broadcom SoC in the future, likely some tweaking of
> the driver is required. But at least the basic cross-arch compatibility
> should be given.

Yeah, and especially the fdt vs. ofnode comments were very justified.

One thing I was wondering about: on ARM the bus is always little-endian, regardless of the current CPU state. That's why we routinely use _le32 function for hardware accesses. A comment in the Linux driver[1] suggests that this is not the case for MIPS, do you know anything about it?
I used the native endian version as you suggested, as I am not aware that anyone is running U-Boot in BE on ARM.

So I addressed your comments already, you can have a look here [2] (top three commits).
I will try if I can fix some of the known shortcomings (PHY timeout etc) before posting a v2.

Cheers,
Andre.

[1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/net/ethernet/broadcom/genet/bcmgenet.c#n72
[2] https://github.com/apritzel/u-boot/commits/rpi4-eth

  reply	other threads:[~2019-12-20 15:47 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-18 11:59 [PATCH 0/3] Ethernet support for Raspberry Pi 4 Andre Przywara
2019-12-18 11:59 ` [PATCH 1/3] net: Add support for Broadcom GENETv5 Ethernet controller Andre Przywara
2019-12-19 11:32   ` Daniel Schwierzeck
2019-12-19 11:42     ` Andre Przywara
2019-12-19 12:58       ` Daniel Schwierzeck
2019-12-20 15:47         ` Andre Przywara [this message]
2019-12-21  3:41         ` Florian Fainelli
2019-12-19 17:29   ` Matthias Brugger
2019-12-20 19:29   ` Stefan Wahren
2019-12-23 18:42     ` Stefan Wahren
2019-12-23 22:24       ` André Przywara
2019-12-24 18:30         ` Sascha Dewald
2019-12-27 11:15           ` Amit Tomer
2019-12-18 11:59 ` [PATCH 2/3] rpi4: Update memory map to accommodate scb devices Andre Przywara
2019-12-18 11:59 ` [PATCH 3/3] rpi4: Enable GENET Ethernet controller Andre Przywara
2019-12-19  8:27 ` [PATCH 0/3] Ethernet support for Raspberry Pi 4 Sascha Dewald

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=20191220154752.30501d4b@donnerap.cambridge.arm.com \
    --to=andre.przywara@arm.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox