summaryrefslogtreecommitdiffstats
path: root/sys/pci/if_dcreg.h
diff options
context:
space:
mode:
authortruckman <truckman@FreeBSD.org>2004-01-08 06:22:15 +0000
committertruckman <truckman@FreeBSD.org>2004-01-08 06:22:15 +0000
commit21e6787900aa26e4eab836a91d34f366df0d97e7 (patch)
tree64e45a82ea2f7001592cfa29c880d379095d596f /sys/pci/if_dcreg.h
parent7289c3aadd278486c0c87e9ee2a3bc26cc82f60c (diff)
downloadFreeBSD-src-21e6787900aa26e4eab836a91d34f366df0d97e7.zip
FreeBSD-src-21e6787900aa26e4eab836a91d34f366df0d97e7.tar.gz
The transmit frame status is stored in the last transmit descriptor for the
frame, not the first. It is probably also not safe to free the mbuf chain as soon as the OWN bit is cleared on the first descriptor since the chip may not be done copying the frame into the transmit FIFO. Revert the part of of busdma conversion (if_dc.c rev 1.115) which changed dc_txeof() to look for the status in the first descriptor and free the mbuf chain when processing the first descriptor for the frame, and revert the matching changes elsewhere in the driver. This part of the busdma change caused the driver to report spurious collisions and output errors, even when running in full-duplex mode. Reverting the mbuf chain handling slightly complicates dc_dma_map_txbuf(), since it is responsible for setting the OWN bits on the descriptors, but does not normally have direct access to the mbuf chain. Tested by: Dejan Lesjak <dejan.lesjak at ijs.si> alpha/<Intel 21143 10/100BaseTX> "Xin LI" <delphij at frontfree.net> i386/<Macronix 98713 10/100BaseTX> Wiktor Niesiobedzki <bsd at w.evip.pl> i386/<3Com OfficeConnect 10/100B> Reviewed by: mux
Diffstat (limited to 'sys/pci/if_dcreg.h')
-rw-r--r--sys/pci/if_dcreg.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/pci/if_dcreg.h b/sys/pci/if_dcreg.h
index 64dcc28..c7339eb 100644
--- a/sys/pci/if_dcreg.h
+++ b/sys/pci/if_dcreg.h
@@ -486,6 +486,7 @@ struct dc_list_data {
struct dc_chain_data {
struct mbuf *dc_rx_chain[DC_RX_LIST_CNT];
struct mbuf *dc_tx_chain[DC_TX_LIST_CNT];
+ struct mbuf *dc_tx_mapping;
bus_dmamap_t dc_rx_map[DC_RX_LIST_CNT];
bus_dmamap_t dc_tx_map[DC_TX_LIST_CNT];
u_int32_t *dc_sbuf;
OpenPOWER on IntegriCloud