diff options
Diffstat (limited to 'src/southbridge/intel/esb6300/esb6300_smbus.h')
-rw-r--r-- | src/southbridge/intel/esb6300/esb6300_smbus.h | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/src/southbridge/intel/esb6300/esb6300_smbus.h b/src/southbridge/intel/esb6300/esb6300_smbus.h index 861230e130..439b8fc586 100644 --- a/src/southbridge/intel/esb6300/esb6300_smbus.h +++ b/src/southbridge/intel/esb6300/esb6300_smbus.h @@ -14,18 +14,12 @@ #define SMBUS_TIMEOUT (100*1000*10) - -static void smbus_delay(void) -{ - outb(0x80, 0x80); -} - static int smbus_wait_until_ready(unsigned smbus_io_base) { unsigned loops = SMBUS_TIMEOUT; unsigned char byte; do { - smbus_delay(); + udelay(100); if (--loops == 0) break; byte = inb(smbus_io_base + SMBHSTSTAT); @@ -38,7 +32,7 @@ static int smbus_wait_until_done(unsigned smbus_io_base) unsigned loops = SMBUS_TIMEOUT; unsigned char byte; do { - smbus_delay(); + udelay(100); if (--loops == 0) break; byte = inb(smbus_io_base + SMBHSTSTAT); @@ -46,18 +40,20 @@ static int smbus_wait_until_done(unsigned smbus_io_base) return loops?0:-1; } +#ifdef UNUSED_CODE static int smbus_wait_until_blk_done(unsigned smbus_io_base) { unsigned loops = SMBUS_TIMEOUT; unsigned char byte; do { - smbus_delay(); + udelay(100); if (--loops == 0) break; byte = inb(smbus_io_base + SMBHSTSTAT); } while((byte&(1<<7)) == 0); return loops?0:-1; } +#endif static int do_smbus_read_byte(unsigned smbus_io_base, unsigned device, unsigned address) { |