On Tue, May 15, 2007 at 02:26:15PM +0200, Stefan Reinauer wrote:
static inline int spd_read_byte(unsigned device, unsigned address) {
- uint8_t c;
- c = smbus_read_byte(device, address);
- return c;
- return smbus_read_byte(device, address);
}
Did you compare the assembler code produced by romcc, verifying that this has no bad impact?
Nope, but the 'return smbus_read_byte(device, address)' variant is already used in many places in svn, so I'm somewhat confident it works as expected.
If it would _not_ work then there should have been a big fat warning in the code that this is done deliberately to workaround romcc issues.
Uwe.