Re: 3com 3c905c-txm

From: David Hinds (dhinds@valinux.com)
Date: Thu May 11 2000 - 13:33:27 EST


I have a couple comments regarding the command-in-progress loops. In
the 3c575_cb driver, I broke this out into a separate function called
wait_for_completion(), that does a printk(KERN_NOTICE ...) if the
command times out. I think that's a bit nicer than killing the system
with a panic(). As for the timing issue, one option would be to
change the loop to something like:

    while (--i > 0) {
        if (!(inw(ioaddr + EL3_STATUS) & CmdInProgress))
            break;
        udelay(1);
    }

to avoid the CPU scaling issue. It may be overkill, though, because
the loop time is essentially dictated by the inw() time, which in turn
is dictated by the clocking of the PCI bus (and the 3Com card), not
the speed of the host CPU.

-- Dave

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Mon May 15 2000 - 21:00:18 EST