public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Detlev Zundel <dzu@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] MPC512x FEC/MII
Date: Tue, 27 Sep 2011 16:27:58 +0200	[thread overview]
Message-ID: <m2zkhqrrf5.fsf@ohwell.denx.de> (raw)
In-Reply-To: <4E6E7311.8060608@gmx.net> (Bernhard Kaindl's message of "Mon, 12 Sep 2011 23:01:05 +0200")

Hi Bernhard,

> we also get broken output from mii_cmd when the commit which you show 
> below is applied, reverting it helps.
>
> Hardware: Our own MPC5121ADS-based board and the MPC5121ADS development 
> board.
>
> The commit is titled:
>
> mpc512x_fec: Move PHY initialization from probe into init routin
> This saves the autonegotation delay when not using ethernet in U-Boot",
>
> This exactly what it does, the effect is no suprise at all:
>
> Of course, the move of the PHY init from the fec_probe (executed before 
> the u-boot prompt appears) to the fec_init (called only and every time a 
> new network command is executed) has the effect which we see:
>
> The PHY is only initialized while a network command (such as dhcp, tftp, 
> ...) is being executed.

Well, this is actually in line with the U-Boot design principles of
initializing a device only if its needed[1].  This principle was
disregarded regularly in the past and so it seems kind of naturla that
"fixing" it results in changes of behaviour.  We should however fix the
fallout rather than going back to violating the principles.

If the mii routines need initializations, then they should ensure that
they have been done.

Cheers
  Detlev

[1] http://www.denx.de/wiki/view/U-Boot/DesignPrinciples#2_Keep_it_Fast

-- 
Practice random senselessness and act kind of beautiful.
--
DENX Software Engineering GmbH,      MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich,  Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu at denx.de

  reply	other threads:[~2011-09-27 14:27 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-09  9:51 [U-Boot] MPC512x FEC/MII Schneider, Kolja
2011-09-12 21:01 ` Bernhard Kaindl
2011-09-27 14:27   ` Detlev Zundel [this message]
2011-09-27 14:57     ` Schneider, Kolja
2011-09-27 15:21       ` Detlev Zundel

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=m2zkhqrrf5.fsf@ohwell.denx.de \
    --to=dzu@denx.de \
    --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