diff options
author | mdodd <mdodd@FreeBSD.org> | 2000-03-13 11:59:21 +0000 |
---|---|---|
committer | mdodd <mdodd@FreeBSD.org> | 2000-03-13 11:59:21 +0000 |
commit | 88b8866bdd26b7ce811e987aa6d5cc52770dc9d9 (patch) | |
tree | 27d709ca39c2f47e7ae2106e69176876775768c2 | |
parent | a8f3dc6a73e598ae0c8af0e6b07deb05b979f9f3 (diff) | |
download | FreeBSD-src-88b8866bdd26b7ce811e987aa6d5cc52770dc9d9.zip FreeBSD-src-88b8866bdd26b7ce811e987aa6d5cc52770dc9d9.tar.gz |
Copy how everyone else is doing packet transmission. (NetBSD mostly)
I've been running this for a month or so and have had no problems with it
and if I recall it was my last speed tweak. Holler if this breaks anything.
-rw-r--r-- | sys/dev/ep/if_ep.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/sys/dev/ep/if_ep.c b/sys/dev/ep/if_ep.c index 63772cb..139e0a5 100644 --- a/sys/dev/ep/if_ep.c +++ b/sys/dev/ep/if_ep.c @@ -498,19 +498,21 @@ startagain: if (EP_FTST(sc, F_ACCESS_32_BITS)) { for (top = m; m != 0; m = m->m_next) { - outsl(BASE + EP_W1_TX_PIO_WR_1, mtod(m, caddr_t), - m->m_len / 4); + if (m->m_len > 3) + outsl(BASE + EP_W1_TX_PIO_WR_1, + mtod(m, caddr_t), m->m_len / 4); if (m->m_len & 3) outsb(BASE + EP_W1_TX_PIO_WR_1, - mtod(m, caddr_t) + (m->m_len & (~3)), - m->m_len & 3); + mtod(m, caddr_t) + (m->m_len & (~3)), m->m_len & 3); } } else { for (top = m; m != 0; m = m->m_next) { - outsw(BASE + EP_W1_TX_PIO_WR_1, mtod(m, caddr_t), m->m_len / 2); + if (m->m_len > 3) + outsw(BASE + EP_W1_TX_PIO_WR_1, + mtod(m, caddr_t), m->m_len / 2); if (m->m_len & 1) outb(BASE + EP_W1_TX_PIO_WR_1, - *(mtod(m, caddr_t) + m->m_len - 1)); + *(mtod(m, caddr_t) + m->m_len - 1)); } } |