smbus_delay() performs its own inb(0x80). We can use the generic udelay() instead which does the same, and achieve better abstraction.
Signed-off-by: Carl-Daniel Hailfinger c-d.hailfinger.devel.2006@gmx.net
Index: corebootv3-stuff3/southbridge/amd/cs5536/smbus_initram.c =================================================================== --- corebootv3-stuff3/southbridge/amd/cs5536/smbus_initram.c (Revision 798) +++ corebootv3-stuff3/southbridge/amd/cs5536/smbus_initram.c (Arbeitskopie) @@ -69,7 +69,7 @@ */ static void smbus_delay(void) { - /* inb(0x80); */ + /* udelay(1); */ }
/** Index: corebootv3-stuff3/southbridge/nvidia/mcp55/mcp55_smbus.h =================================================================== --- corebootv3-stuff3/southbridge/nvidia/mcp55/mcp55_smbus.h (Revision 798) +++ corebootv3-stuff3/southbridge/nvidia/mcp55/mcp55_smbus.h (Arbeitskopie) @@ -39,8 +39,7 @@
static inline void smbus_delay(void) { - /* let's hope this is not optimized out */ - (void) inb(0x80); + udelay(1); }
int do_smbus_recv_byte(u16 smbus_io_base, u8 device);
On Thu, Aug 21, 2008 at 6:44 PM, Carl-Daniel Hailfinger c-d.hailfinger.devel.2006@gmx.net wrote:
smbus_delay() performs its own inb(0x80). We can use the generic udelay() instead which does the same, and achieve better abstraction.
Signed-off-by: Carl-Daniel Hailfinger c-d.hailfinger.devel.2006@gmx.net
Acked-by: Ronald G. Minnich rminnich@gmail.com
On 22.08.2008 05:35, ron minnich wrote:
On Thu, Aug 21, 2008 at 6:44 PM, Carl-Daniel Hailfinger c-d.hailfinger.devel.2006@gmx.net wrote:
smbus_delay() performs its own inb(0x80). We can use the generic udelay() instead which does the same, and achieve better abstraction.
Signed-off-by: Carl-Daniel Hailfinger c-d.hailfinger.devel.2006@gmx.net
Acked-by: Ronald G. Minnich rminnich@gmail.com
Thanks, r799.
Regards, Carl-Daniel