[U-Boot] [PATCH] Marvell GuruPlug Board Support

Wolfgang Denk wd at denx.de
Thu Mar 18 09:38:14 CET 2010


Dear Siddarth Gore,

In message <1268890125.23313.27.camel at pe-dt434> you wrote:
>
...
> > We have pretty much identical code already in mv_phy_88e1116_init()
> > [in "board/Marvell/rd6281a/rd6281a.c"], in reset_phy() [in
> > "board/Marvell/openrd_base/openrd_base.c"], in reset_phy(0 [in
> > "board/Marvell/sheevaplug/sheevaplug.c"] and I don't know where else.
> > 
> > I object against adding more and more copies of the same code. Please
> > factor out the common part into a single implementation, and call this
> > everwhere where such code is used.  Thanks.
> > 
> i can create a new file ethphy.c in board/Marvell/common and put this
> code there. but if we are going to move to a phy driver (as Prafulla
> suggested) then that wont be necessary. Please advise.

Is there any actual development for a generic PHY support layer going
on anywhere? I must have missed this, then.  If there is such a thing,
it should be used, obviously.

> Also i think we should maintain different init functions for 1116 and
> 1121 as they represent different phy families, even though the code is
> pretty much the same right now.

If the code is the same, then duplication makes no sense to me.

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
Space is big. You just won't believe how vastly, hugely, mind-
bogglingly big it is. I mean, you may think it's a long way down the
road to the drug store, but that's just peanuts to space.
                              -- The Hitchhiker's Guide to the Galaxy


More information about the U-Boot mailing list