Thread (19 messages) flat view 19 messages, 5 authors, 2006-09-19

Re: [PATCH 1/6] bootwrapper: arch/powerpc/boot code reorg

From: Tom Rini <hidden>
Date: 2006-08-02 16:03:18

On Wed, Aug 02, 2006 at 04:15:05PM +1000, Paul Mackerras wrote:
I wrote:
quoted
The ops structure seems like a reasonable concept, but I question
whether we need to have platform_ops separate from fw_ops, since the
firmware is essentially part of the implementation of the platform.
Also I don't see why we need to do a double indirection to get to each
ops function.
Thinking about this a bit more, why do we need the indirect function
calls at all?  Do we ever want to be able to choose (e.g.) one of
several possible console implementations at runtime?  Don't we know at
compile time which one we will be using, and thus can't we use the
linker to make the necessary linkages?
Right.  I was thinking perhaps Mark did it this way so certain things
could be omitted (if ops->foo  then ops->foo(bar, baz)) but that'd
better taken care of with weak functions and getting the right one at
compile time.

The only potential case, but I'm not even sure then that it is an issue,
is on platforms where it's either U-Boot or PIBS/DINK/whatever.  But
even then, the only thing that should matter is 'Do we have a tree
passed in?'.

-- 
Tom Rini
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help