summaryrefslogtreecommitdiff
path: root/sys/dev/pci/if_bgereg.h
diff options
context:
space:
mode:
authorBrad Smith <brad@cvs.openbsd.org>2006-10-01 17:29:49 +0000
committerBrad Smith <brad@cvs.openbsd.org>2006-10-01 17:29:49 +0000
commit419b286d9c4fec8fff203fcffcc944b2fb68c802 (patch)
tree7208f7e886a8dc324c5b7ae0cf5171a5107cfc1c /sys/dev/pci/if_bgereg.h
parent86ea2712f27da9a028f9c487e7847da01930700d (diff)
pack several boolean fields into the existing bge_flags field.
Diffstat (limited to 'sys/dev/pci/if_bgereg.h')
-rw-r--r--sys/dev/pci/if_bgereg.h35
1 files changed, 16 insertions, 19 deletions
diff --git a/sys/dev/pci/if_bgereg.h b/sys/dev/pci/if_bgereg.h
index 4105a496ec3..8d2f3423932 100644
--- a/sys/dev/pci/if_bgereg.h
+++ b/sys/dev/pci/if_bgereg.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_bgereg.h,v 1.61 2006/10/01 00:34:07 brad Exp $ */
+/* $OpenBSD: if_bgereg.h,v 1.62 2006/10/01 17:29:48 brad Exp $ */
/*
* Copyright (c) 2001 Wind River Systems
@@ -2335,13 +2335,6 @@ struct txdmamap_pool_entry {
SLIST_ENTRY(txdmamap_pool_entry) link;
};
-/*
- * Flags for bge_flags.
- */
-#define BGE_TXRING_VALID 0x0001
-#define BGE_RXRING_VALID 0x0002
-#define BGE_JUMBO_RXRING_VALID 0x0004
-
#define ASF_ENABLE 1
#define ASF_NEW_HANDSHAKE 2
#define ASF_STACKUP 4
@@ -2355,18 +2348,23 @@ struct bge_softc {
struct pci_attach_args bge_pa;
struct mii_data bge_mii;
struct ifmedia bge_ifmedia; /* media info */
- u_int8_t bge_extram; /* has external SSRAM */
- u_int8_t bge_eeprom;
- u_int8_t bge_tbi;
- u_int8_t bge_jumbo_cap;
- u_int8_t bge_rx_alignment_bug;
+ u_int32_t bge_flags;
+#define BGE_TXRING_VALID 0x00000001
+#define BGE_RXRING_VALID 0x00000002
+#define BGE_JUMBO_RXRING_VALID 0x00000004
+#define BGE_EXTRAM 0x00000008 /* Has external SSRAM. */
+#define BGE_TBI 0x00000010
+#define BGE_RX_ALIGNBUG 0x00000020
+#define BGE_NO_3LED 0x00000040
+#define BGE_PCIX 0x00000080
+#define BGE_PCIE 0x00000100
+#define BGE_ASF_MODE 0x00000200
+#define BGE_NO_EEPROM 0x00000400
+#define BGE_JUMBO_CAP 0x00000800
+#define BGE_10_100_ONLY 0x00001000
+
bus_dma_tag_t bge_dmatag;
u_int32_t bge_chipid;
- u_int8_t bge_no_3_led;
- u_int8_t bge_asf_mode;
- u_int8_t bge_pcie;
- u_int8_t bge_pcix;
- u_int8_t bge_10_100_only;
struct bge_ring_data *bge_rdata; /* rings */
struct bge_chain_data bge_cdata; /* mbufs */
bus_dmamap_t bge_ring_map;
@@ -2386,7 +2384,6 @@ struct bge_softc {
u_int32_t bge_tx_max_coal_bds;
u_int32_t bge_tx_buf_ratio;
int bge_if_flags;
- int bge_flags;
int bge_txcnt;
int bge_link; /* link state */
int bge_link_evt; /* pending link event */