summaryrefslogtreecommitdiffstats
path: root/sys/dev/mxge/if_mxge_var.h
diff options
context:
space:
mode:
authorgallatin <gallatin@FreeBSD.org>2007-01-31 15:29:31 +0000
committergallatin <gallatin@FreeBSD.org>2007-01-31 15:29:31 +0000
commit60e3c7067047cbb6c9f0fa5bfcb0ad9d19fe721d (patch)
tree6ce4bf2ae8cb1509cf925d3640cbcc0162fc36d8 /sys/dev/mxge/if_mxge_var.h
parent3bd3bcc77909873a2c6ae0e8f139126642e309d4 (diff)
downloadFreeBSD-src-60e3c7067047cbb6c9f0fa5bfcb0ad9d19fe721d.zip
FreeBSD-src-60e3c7067047cbb6c9f0fa5bfcb0ad9d19fe721d.tar.gz
Abandon using sleepable locks in favor of mutexes for mxge's if_ioctl
locking in preparation for adding a watchdog handler (callouts must not use sleepable locks). This required shuffling memory and interrupt allocation to the attach routine rather than if_ioctl so as to avoid potential sleeps while bringing up the interface.
Diffstat (limited to 'sys/dev/mxge/if_mxge_var.h')
-rw-r--r--sys/dev/mxge/if_mxge_var.h10
1 files changed, 7 insertions, 3 deletions
diff --git a/sys/dev/mxge/if_mxge_var.h b/sys/dev/mxge/if_mxge_var.h
index 82beda1..cf3c0d4 100644
--- a/sys/dev/mxge/if_mxge_var.h
+++ b/sys/dev/mxge/if_mxge_var.h
@@ -114,7 +114,7 @@ typedef struct
typedef struct {
struct ifnet* ifp;
int big_bytes;
- struct mtx tx_lock;
+ struct mtx tx_mtx;
int csum_flag; /* rx_csums? */
uint8_t mac_addr[6]; /* eeprom mac address */
mxge_tx_buf_t tx; /* transmit ring */
@@ -138,8 +138,8 @@ typedef struct {
int intr_coal_delay;
volatile uint32_t *intr_coal_delay_ptr;
int wc;
- struct mtx cmd_lock;
- struct sx driver_lock;
+ struct mtx cmd_mtx;
+ struct mtx driver_mtx;
int wake_queue;
int stop_queue;
int down_cnt;
@@ -159,10 +159,14 @@ typedef struct {
int read_write_dma;
int fw_multicast_support;
int link_width;
+ mxge_dma_t dmabench_dma;
char *mac_addr_string;
char product_code_string[64];
char serial_number_string[64];
char scratch[256];
+ char tx_mtx_name[16];
+ char cmd_mtx_name[16];
+ char driver_mtx_name[16];
} mxge_softc_t;
#define MXGE_PCI_VENDOR_MYRICOM 0x14c1
OpenPOWER on IntegriCloud