diff options
author | wpaul <wpaul@FreeBSD.org> | 2000-10-24 22:38:54 +0000 |
---|---|---|
committer | wpaul <wpaul@FreeBSD.org> | 2000-10-24 22:38:54 +0000 |
commit | deefde18d945622194e19ab0449141b879104d9b (patch) | |
tree | 27821821a225a50037f2e42bb26e3efea97acf15 /sys/dev/usb/if_kuereg.h | |
parent | 46334203c117eda9e89c8f885354dfc350035a21 (diff) | |
download | FreeBSD-src-deefde18d945622194e19ab0449141b879104d9b.zip FreeBSD-src-deefde18d945622194e19ab0449141b879104d9b.tar.gz |
Convert the USB ethernet drivers to use mutexes. Also convert
usb_ethersubr.c. This module maintains two queues for packets which
are each protected with one mutex. These are all the changes I can
do for now. Removing the USBD_NO_TSLEEP flag doesn't work yet: when
I tried it, the system would usually freeze up after a NIC had been
operating for a while. The usb_ethersubr module itself ought to
go away; this is the next thing I need to test.
Diffstat (limited to 'sys/dev/usb/if_kuereg.h')
-rw-r--r-- | sys/dev/usb/if_kuereg.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/dev/usb/if_kuereg.h b/sys/dev/usb/if_kuereg.h index 5a315b1..49cd235 100644 --- a/sys/dev/usb/if_kuereg.h +++ b/sys/dev/usb/if_kuereg.h @@ -170,4 +170,8 @@ struct kue_softc { u_int16_t kue_rxfilt; u_int8_t *kue_mcfilters; struct kue_cdata kue_cdata; + struct mtx kue_mtx; }; + +#define KUE_LOCK(_sc) mtx_enter(&(_sc)->kue_mtx, MTX_DEF) +#define KUE_UNLOCK(_sc) mtx_exit(&(_sc)->kue_mtx, MTX_DEF) |