netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andrew Lunn <andrew@lunn.ch>
To: David Daney <ddaney@caviumnetworks.com>
Cc: Dinh Nguyen <dinguyen@opensource.altera.com>,
	Florian Fainelli <f.fainelli@gmail.com>,
	"David S. Miller" <davem@davemloft.net>,
	david.daney@cavium.com, netdev@vger.kernel.org,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: SoCFPGA ethernet broken
Date: Fri, 16 Oct 2015 22:29:05 +0200	[thread overview]
Message-ID: <20151016202905.GE28207@lunn.ch> (raw)
In-Reply-To: <56215CF0.6080905@caviumnetworks.com>

On Fri, Oct 16, 2015 at 01:24:16PM -0700, David Daney wrote:
> On 10/16/2015 12:38 PM, Andrew Lunn wrote:
> >>>Maybe we need to walk up the hierarchy.
> >>>
> >>>Perhaps something like:
> >>>
> >>>const struct device *dev_walker;
> >>>
> >>>dev_walker = &phydev->dev;
> >>>do {
> >>>    of_node = dev_walker->of_node;
> >>>    dev_walker = dev_walker->parent;
> >>>} while (!of_node && dev_walker);
> >>>
> >>
> >>The above code seems to have fixed the issue.
> >
> >What i don't like about this is that it allows you to put these
> >properties in the mdio device node. These are phy properties, not mdio
> >properties....
> 
> Yes, we know that the device tree is not correctly formed.
> 
> You have a choice:
> 
> A) Fix the device tree and any code that may have to change to work
> with a good device tree.
> 
> B) Change the code to work with the screwy existing device tree.
> The above seems to work, other things may also be possible.
> 
> I can't really make any decisions as to what the best way to proceed
> is, as I neither have the hardware in question, nor the time to work
> on it.

Hi hope Dinh will test with phydev->attached_dev->dev->of_node.

   Andrew

  reply	other threads:[~2015-10-16 20:29 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-15 19:09 SoCFPGA ethernet broken Dinh Nguyen
2015-10-15 20:03 ` Florian Fainelli
2015-10-15 19:59   ` Dinh Nguyen
2015-10-15 20:25     ` Florian Fainelli
2015-10-15 20:35       ` David Daney
2015-10-15 20:49         ` Dinh Nguyen
2015-10-15 21:30           ` Florian Fainelli
2015-10-16  2:32             ` Dinh Nguyen
2015-10-16  3:31               ` Andrew Lunn
2015-10-16 14:38                 ` Dinh Nguyen
2015-10-16 15:03                   ` Andrew Lunn
2015-10-16 15:31                     ` Dinh Nguyen
2015-10-16 15:56                       ` Andrew Lunn
2015-10-16 16:47                         ` David Daney
2015-10-16 19:10                           ` Dinh Nguyen
2015-10-16 19:38                             ` Andrew Lunn
2015-10-16 20:24                               ` David Daney
2015-10-16 20:29                                 ` Andrew Lunn [this message]
2015-10-19 15:14                               ` Dinh Nguyen
2015-10-16 18:17                         ` Florian Fainelli
2015-10-16  3:04             ` Dinh Nguyen
2015-12-03 20:48       ` Pavel Machek
2015-12-03 21:23         ` David Daney
2015-12-03 23:17           ` Dinh Nguyen
2015-12-04  1:10             ` Andrew Lunn
2015-12-04  1:50               ` Andrew Lunn
2015-12-04 11:27                 ` Dinh Nguyen
2015-12-04 14:31                   ` Andrew Lunn
2015-12-04  9:38           ` Pavel Machek

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=20151016202905.GE28207@lunn.ch \
    --to=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=david.daney@cavium.com \
    --cc=ddaney@caviumnetworks.com \
    --cc=dinguyen@opensource.altera.com \
    --cc=f.fainelli@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).