From: Alessandro Rubini <rubini-list@gnudd.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] ppc: transform init_sequence into a function.
Date: Fri, 27 Nov 2009 15:54:57 +0100 [thread overview]
Message-ID: <20091127145456.GA21440@mail.gnudd.com> (raw)
In-Reply-To: <OF012B1DA7.446FFBCD-ONC125767B.004DD4EE-C125767B.00508FF3@tran smode.se>
> I think most of the ugliness comes from the #ifdef hell in this list.
> replacing the #ifdefs is another matter so looking behind
> the #ifdef mess, I don't think it looks too bad.
I think the approach I took with lib_arm/board.c may apply as well.
A simple weak init_nop(), no change at all in board code and
no more "CONFIG_BOARD_EARLY_INIT_F" kind of stuff.
>> This is much more ugly, and I cannot see why it would be easier to
>> debug.
>
> You can set breakpoints anywhere you like. When it crashes in here
> somewhere, it isn't easy to tell where it did so.
I agree it is uglier (and I've discussed with Joakim offlist), this is
a very strong point. I never had problems with the u-boot init
function, I had serious issues with kernel initcalls.
Whils debug_initcall is great and good in the kernel, we can't do with
printf ini u-boot, not in the first steps, at least.
So while I strongly prefer data structures to a burst of "if () goto error;",
I think Joakim has a point here -- after I argued against it offlist.
/alessandro
next prev parent reply other threads:[~2009-11-27 14:54 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <OF012B1DA7.446FFBCD-ONC125767B.004DD4EE-C125767B.00508FF3@trans mode.se>
2009-11-27 10:32 ` [U-Boot] [PATCH] ppc: transform init_sequence into a function Joakim Tjernlund
2009-11-27 14:06 ` Wolfgang Denk
2009-11-27 14:39 ` Joakim Tjernlund
2009-11-27 20:18 ` Wolfgang Denk
2009-11-28 13:56 ` Joakim Tjernlund
2009-11-30 12:36 ` Joakim Tjernlund
2009-11-30 21:02 ` Wolfgang Denk
2009-11-30 22:27 ` Joakim Tjernlund
2009-11-30 23:27 ` Wolfgang Denk
2009-12-01 10:43 ` Detlev Zundel
[not found] ` <OF012B1DA7.446FFBCD-ONC125767B.004DD4EE-C125767B.00508FF3@tran smode.se>
2009-11-27 14:54 ` Alessandro Rubini [this message]
2009-11-27 15:01 ` Joakim Tjernlund
2010-12-06 17:59 Joakim Tjernlund
2010-12-06 20:09 ` Wolfgang Denk
2010-12-06 20:42 ` Joakim Tjernlund
2010-12-06 21:33 ` Scott Wood
2010-12-06 22:36 ` Graeme Russ
2010-12-06 22:49 ` Scott Wood
2010-12-06 23:04 ` Graeme Russ
2010-12-06 23:12 ` Scott Wood
2010-12-06 23:13 ` Wolfgang Denk
2010-12-07 0:07 ` Joakim Tjernlund
2010-12-07 0:21 ` Scott Wood
2010-12-07 0:41 ` Joakim Tjernlund
2010-12-07 0:59 ` Scott Wood
2010-12-06 23:09 ` Wolfgang Denk
2010-12-06 22:36 ` Wolfgang Denk
2010-12-06 23:06 ` Graeme Russ
2010-12-07 0:32 ` Joakim Tjernlund
2010-12-07 6:34 ` Wolfgang Denk
2010-12-07 9:08 ` Joakim Tjernlund
2010-12-07 13:07 ` Wolfgang Denk
2010-12-07 13:57 ` Joakim Tjernlund
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=20091127145456.GA21440@mail.gnudd.com \
--to=rubini-list@gnudd.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