[coreboot] patch: remove static variable from cs5536 smbus function

ron minnich rminnich at gmail.com
Wed Sep 17 01:07:57 CEST 2008


On Mon, Sep 15, 2008 at 5:01 PM, Peter Stuge <peter at stuge.se> wrote:

> But I don't like all the duplication. Could it be made more generic?
>\

how about we go with this patch and take an action to make it more
generic when the time comes?

I've done it this way because I want to make sure that spd_init gets
called. Putting a call to spd_init() in the generic sdram code
will ensure that the mainboard-specific spd_init() gets written; you
can't link coreboot unless you define that function, and if you define
that function, it *will* be called.

So this way of doing it makes very certain that the function will be
written and will be called when needed.

If we leave it up to people to call smbus_init() in initram main(),
somebody is going
to have a bad time when they forget to call it.

But one last option is take the spd_init call out of the spd code and
just remind people that the first call in initram should be
smbus_init()
if they need it.

let's get to a decision :-)

ron




More information about the coreboot mailing list