On 10/10/2011 07:51 PM, Mike Frysinger wrote: Hi Mike,
> i believe we have two standards. Well, two standards means we have no standard...;-) > i'm not sure which gets used more, or if > it's just a wash. i think it makes sense to have an accessible default func > if it does something useful, but not if it's just a stub. > > in the __def/weak style above, unless people use --gc-sections when linking > (i > think we've got many people doing this now, but not all), you end up with > dead > code in the binary. in the code i proposed, the func gets discarded both > when > using --gc-sections and when not. You are right, but probably it makes no difference. I checked and it seems that only a few architectute (m68k, sparc and microblaze) do not set --gc-sections. After the Heiko's post and our discussion, I think that this patch is another work-around waiting for the Heiko's patches to go to mainline. And it becomes a second work-around, because there is already the I2C_SET_BUS() for boards supporting only one bus. Two work-around are too much... I drop this patch and I will make use of I2C_SET_BUS() in pmic. This is coherent with the actual u-boot code. Regards, Stefano -- ===================================================================== DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: off...@denx.de ===================================================================== _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot