summaryrefslogtreecommitdiffstats
path: root/sys/pci
diff options
context:
space:
mode:
authorjmg <jmg@FreeBSD.org>2004-09-19 17:45:56 +0000
committerjmg <jmg@FreeBSD.org>2004-09-19 17:45:56 +0000
commit6c7697503ce2f99ebe7b638b4050cf49f2517f00 (patch)
treee954de976e88edcc090c74c7514f0fb363299e26 /sys/pci
parent15deca3fae97535705845b6981ed8944f75bc72b (diff)
downloadFreeBSD-src-6c7697503ce2f99ebe7b638b4050cf49f2517f00.zip
FreeBSD-src-6c7697503ce2f99ebe7b638b4050cf49f2517f00.tar.gz
comment requirement that rx/tx descriptor counts must be equal due to
shared code... define rx descriptor count in terms of tx align defines MFC after: 3 days
Diffstat (limited to 'sys/pci')
-rw-r--r--sys/pci/if_rlreg.h11
1 files changed, 8 insertions, 3 deletions
diff --git a/sys/pci/if_rlreg.h b/sys/pci/if_rlreg.h
index 35cf5a1..273de102 100644
--- a/sys/pci/if_rlreg.h
+++ b/sys/pci/if_rlreg.h
@@ -603,8 +603,13 @@ struct rl_stats {
uint16_t rl_rx_underruns;
};
-#define RL_RX_DESC_CNT 64
+/*
+ * Rx/Tx descriptor parameters (8139C+ and 8169 only)
+ *
+ * Tx/Rx count must be equal. Shared code like re_dma_map_desc assumes this.
+ */
#define RL_TX_DESC_CNT 64
+#define RL_RX_DESC_CNT RL_RX_DESC_CNT
#define RL_RX_LIST_SZ (RL_RX_DESC_CNT * sizeof(struct rl_desc))
#define RL_TX_LIST_SZ (RL_TX_DESC_CNT * sizeof(struct rl_desc))
#define RL_RING_ALIGN 256
@@ -614,8 +619,8 @@ struct rl_stats {
#define RL_RXBYTES(x) (le32toh((x)->rl_cmdstat) & sc->rl_rxlenmask)
#define RL_PKTSZ(x) ((x)/* >> 3*/)
-#define RL_ADDR_LO(y) ((uint64_t) (y) & 0xFFFFFFFF)
-#define RL_ADDR_HI(y) ((uint64_t) (y) >> 32)
+#define RL_ADDR_LO(y) ((uint64_t) (y) & 0xFFFFFFFF)
+#define RL_ADDR_HI(y) ((uint64_t) (y) >> 32)
#define RL_JUMBO_FRAMELEN 9018
#define RL_JUMBO_MTU (RL_JUMBO_FRAMELEN-ETHER_HDR_LEN-ETHER_CRC_LEN)
OpenPOWER on IntegriCloud