diff options
author | Alexey Zaytsev <alexey.zaytsev@gmail.com> | 2008-03-02 03:41:10 +0300 |
---|---|---|
committer | Alexey Zaytsev <alexey.zaytsev@gmail.com> | 2008-03-02 03:41:10 +0300 |
commit | a1572e0ab0f5fab9a1f0185ded593bec811aa175 (patch) | |
tree | e407d6d0f2b8e93950216268ec0198fff865c6a0 /src/drivers/net/3c90x.c | |
parent | 4006d229e50204c93c1aa04c58385ce2e66d597e (diff) | |
download | ipxe-a1572e0ab0f5fab9a1f0185ded593bec811aa175.tar.gz |
Modify gPXE core and drivers to work with the new timer subsystem
Signed-off-by: Alexey Zaytsev <alexey.zaytsev@gmail.com>
Diffstat (limited to 'src/drivers/net/3c90x.c')
-rw-r--r-- | src/drivers/net/3c90x.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/drivers/net/3c90x.c b/src/drivers/net/3c90x.c index 8e1f160e..8158239d 100644 --- a/src/drivers/net/3c90x.c +++ b/src/drivers/net/3c90x.c @@ -43,7 +43,6 @@ #include "nic.h" #include <gpxe/pci.h> #include <gpxe/ethernet.h> -#include "timer.h" static struct nic_operations a3c90x_operations; @@ -498,6 +497,7 @@ a3c90x_transmit(struct nic *nic __unused, const char *d, unsigned int t, unsigned char status; unsigned i, retries; + tick_t ct; for (retries=0; retries < XMIT_RETRIES ; retries++) { @@ -540,9 +540,10 @@ a3c90x_transmit(struct nic *nic __unused, const char *d, unsigned int t, ; /** Wait for NIC Transmit to Complete **/ - load_timer2(10*TICKS_PER_MS); /* Give it 10 ms */ + ct = currticks(); + while (!(inw(INF_3C90X.IOAddr + regCommandIntStatus_w)&0x0004) && - timer2_running()) + ct + 10*USECS_IN_MSEC < currticks()); ; if (!(inw(INF_3C90X.IOAddr + regCommandIntStatus_w)&0x0004)) |