From: Wolfgang Denk <wd@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] arm:kirkwood Wait for the link to come up on kirkwood network init
Date: Wed, 19 Aug 2009 21:25:10 +0200 [thread overview]
Message-ID: <20090819192510.BD75D833DBD2@gemini.denx.de> (raw)
In-Reply-To: <4A8C3172.70001@gmail.com>
Dear Ben Warren,
In message <4A8C3172.70001@gmail.com> you wrote:
>
> > - if (!miiphy_link(dev->name, phyadr)) {
> > - printf("%s: No link on %s\n", __FUNCTION__, dev->name);
> >
> Please use __func__ instead. It's defined in C99, while __FUNCTION__
> isn't (or so I've read)
Do we really need the function name at all? This sounds more like a
debug message for the developper than a standard error message.
> > + /* Wait up to 5s for the link status */
> > + for (i = 0; i < 5; i++) {
> > + u16 phyadr;
> >
> Please put this variable declaration outside of the 'for' loop
Why? If it's only used in this block it's actually a good thing to
restrict it to this scope.
Best regards,
Wolfgang Denk
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Man is the best computer we can put aboard a spacecraft ... and the
only one that can be mass produced with unskilled labor.
-- Wernher von Braun
next prev parent reply other threads:[~2009-08-19 19:25 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-08-19 10:24 [U-Boot] [PATCH] arm:kirkwood Wait for the link to come up on kirkwood network init Simon Kagstrom
2009-08-19 17:08 ` Ben Warren
2009-08-19 19:25 ` Wolfgang Denk [this message]
2009-08-19 19:29 ` Ben Warren
2009-08-19 19:40 ` Wolfgang Denk
2009-08-20 7:51 ` Simon Kagstrom
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=20090819192510.BD75D833DBD2@gemini.denx.de \
--to=wd@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 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.