All of lore.kernel.org
 help / color / mirror / Atom feed
From: jacopo mondi <jacopo@jmondi.org>
To: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Jacopo Mondi <jacopo+renesas@jmondi.org>,
	Simon Horman <horms@verge.net.au>,
	Magnus Damm <magnus.damm@gmail.com>,
	Linux-Renesas <linux-renesas-soc@vger.kernel.org>
Subject: Re: [PATCH 3/4] arm: dts: gr-peach: Add ETHER pin group
Date: Thu, 14 Sep 2017 17:59:11 +0200	[thread overview]
Message-ID: <20170914155911.GI3358@w540> (raw)
In-Reply-To: <20170824125359.GB3905@w540>

Hello Geert and Renesas-SoC list
 - devicetree
 - arm-linux

On Thu, Aug 24, 2017 at 02:53:59PM +0200, jmondi wrote:
> Thanks Geert,
>
> On Thu, Aug 24, 2017 at 01:56:16PM +0200, Geert Uytterhoeven wrote:
> > Hi Jacopo,
> >
>
> [snip]
>
> > > I haven't find any mention in device tree bindings documentation of a
> > > "reset-gpio" property for sh_eth, in the code examples I've seen in
> > > u-boot and mbed, the interface is reset before any actual
> > > configuration is performed. I feel like that should be the place where
> > > that gpio is requested and cycled...
> >
> > Documentation/devicetree/bindings/net/mdio.txt says
> >
> > These are generic properties that can apply to any MDIO bus.
> >
>
> I have now used mdio defined generic properties
>
> &ether {
> 	pinctrl-names = "default";
> 	pinctrl-0 = <&ether_pins>;
>
> 	status = "okay";
>
> 	reset-gpios = <&port4 2 GPIO_ACTIVE_LOW>;
> 	reset-delay-us = <5>;
>
> 	renesas,no-ether-link;
> 	phy-handle = <&phy0>;
> 	phy0: ethernet-phy@0 {
>                reg = <0>;
> 	};
> };
>
> I see the gpio being cycled, but same results as before: device gets
> probed, address set, but I cannot ping, device gets probed, address
> gets set, but I cannot ping
>

I'm back on this with a few days of more hacking, and I'm here to ask
you a suggestion on how to proceed on this.

I'm still in a situation where I'm not able to send any frame on the
interface (I can receive them though), and several traces show me that
the sh_eth_start_xmit() function never gets called, probably because
of the interface being put in QDISC_STATE_DEACTIVATE by some upper
layers state machine.

Compared to my initial submission, I have now made sure the
correct PHY is identified, as the gr-peach uses a LAN8710a
transceiver.

I have the PHY correctly identified during phy initialization

SMSC LAN8710/LAN8720 e8203000.ethernet-ffffffff:00: attached PHY driver [SMSC LAN8710/LAN8720] (mii_bus:phy_addr=e8203000.ethernet-ffffffff:00, irq=-1)

And I'm not worried by the "irq=-1" as Genmai has the same but Ethernet
works there...

This particular PHY has a nINTSEL pin that determinates if pin #18
has to be used as TxD4/TxERR of as interrupt signal nINT [1].
Compared to Genmai (and maybe other RZ devices) there is no interrupt
pin that goes from the PHY to the LSI, so I do now assume the only
option is to use TxD4 for this purpose (see P1_15 in Genmai schematics
[2])

gr-peach has a pull-up wired to nINTSEL pin [3] which makes me think
again that TxD4 pin is intended to be used as interrupt to the ETHER
interface (nINTSEL == Vdd -> use pin #18 as nINT signal).

Before going any further with this, I would like to better understand
if:

1) is an interrupt signal from PHY to ETHER mandatory? There is no
mention of in the ETHER pin description list of an interrupt pin, and
my understanding was the E-DMAC does not need any.
2) where is that interrupt pin described in dts for genmai and other
RZ devices?

Links to gr-peach schematics and LAN8710a datasheet (both publicly
available but uploaded here as I cannot retrieve links easily)
gr-peach: http://jmondi.org/owncloud/index.php/s/RbCvWCv9EWhtO9H
lan8710a: http://jmondi.org/owncloud/index.php/s/Its3RxdhfJtxc2n

Thanks
   j

[1] http://jmondi.org/owncloud/index.php/s/IH2vuCsGmoaqUL7
[2] http://jmondi.org/owncloud/index.php/s/qz6UZXUHPhQyMVm
[3] http://jmondi.org/owncloud/index.php/s/GAphEgxBXzbM2NI

  parent reply	other threads:[~2017-09-14 15:59 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-24  8:48 [PATCH 0/4] GR-Peach DTS update Jacopo Mondi
2017-08-24  8:48 ` Jacopo Mondi
2017-08-24  8:48 ` [PATCH 1/4] arm: dts: gr-peach: Remove empty line Jacopo Mondi
2017-08-24  9:22   ` Geert Uytterhoeven
2017-08-24  9:22     ` Geert Uytterhoeven
2017-08-24  8:48 ` [PATCH 2/4] arm: dts: gr-peach: Add SCIF2 pin group Jacopo Mondi
2017-08-24  9:27   ` Geert Uytterhoeven
2017-08-24  9:27     ` Geert Uytterhoeven
     [not found] ` <1503564523-31899-1-git-send-email-jacopo+renesas-AW8dsiIh9cEdnm+yROfE0A@public.gmane.org>
2017-08-24  8:48   ` [PATCH 3/4] arm: dts: gr-peach: Add ETHER " Jacopo Mondi
2017-08-24  8:48     ` Jacopo Mondi
     [not found]     ` <1503564523-31899-4-git-send-email-jacopo+renesas-AW8dsiIh9cEdnm+yROfE0A@public.gmane.org>
2017-08-24  9:48       ` Geert Uytterhoeven
2017-08-24  9:48         ` Geert Uytterhoeven
2017-08-24  9:48         ` Geert Uytterhoeven
2017-08-24 11:46         ` jmondi
2017-08-24 11:46           ` jmondi
2017-08-24 11:56           ` Geert Uytterhoeven
2017-08-24 11:56             ` Geert Uytterhoeven
2017-08-24 12:53             ` jmondi
2017-08-24 12:53               ` jmondi
2017-08-30  7:25               ` Simon Horman
2017-08-30  7:25                 ` Simon Horman
2017-08-30  7:25                 ` Simon Horman
2017-08-30  7:35                 ` jmondi
2017-08-30  7:35                   ` jmondi
2017-08-30  9:28                   ` Simon Horman
2017-08-30  9:28                     ` Simon Horman
2017-08-30  9:28                     ` Simon Horman
2017-09-14 15:59               ` jacopo mondi [this message]
2017-09-14 16:09                 ` Chris Brandt
2017-08-24  8:48   ` [PATCH 4/4] arm: dts: gr-peach: Add user led device nodes Jacopo Mondi
2017-08-24  8:48     ` Jacopo Mondi
     [not found]     ` <1503564523-31899-5-git-send-email-jacopo+renesas-AW8dsiIh9cEdnm+yROfE0A@public.gmane.org>
2017-08-24  9:31       ` Geert Uytterhoeven
2017-08-24  9:31         ` Geert Uytterhoeven
2017-08-24  9:31         ` Geert Uytterhoeven
2017-08-24 10:53 ` [PATCH 0/4] GR-Peach DTS update Simon Horman
2017-08-24 10:53   ` Simon Horman
     [not found]   ` <20170824105350.GD27788-/R6kz+dDXgpPR4JQBCEnsQ@public.gmane.org>
2017-08-24 10:57     ` Simon Horman
2017-08-24 10:57       ` Simon Horman
2017-08-24 10:57       ` Simon Horman

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=20170914155911.GI3358@w540 \
    --to=jacopo@jmondi.org \
    --cc=geert@linux-m68k.org \
    --cc=horms@verge.net.au \
    --cc=jacopo+renesas@jmondi.org \
    --cc=linux-renesas-soc@vger.kernel.org \
    --cc=magnus.damm@gmail.com \
    /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.