summaryrefslogtreecommitdiff
path: root/sys/dev/amd
diff options
context:
space:
mode:
authorScott Long <scottl@FreeBSD.org>2003-07-01 15:52:06 +0000
committerScott Long <scottl@FreeBSD.org>2003-07-01 15:52:06 +0000
commitf6b1c44d1f70d5f298b911f2c1dcd802b0d11339 (patch)
tree1bbd76935b6d5917753df7328c69bd2f3c75f15a /sys/dev/amd
parentdfebdcdf7ca22f2767534b7df4b828f55b6e754f (diff)
Notes
Diffstat (limited to 'sys/dev/amd')
-rw-r--r--sys/dev/amd/amd.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/sys/dev/amd/amd.c b/sys/dev/amd/amd.c
index 6267ce00c252..fe398ad443af 100644
--- a/sys/dev/amd/amd.c
+++ b/sys/dev/amd/amd.c
@@ -55,6 +55,8 @@
#include <sys/systm.h>
#include <sys/queue.h>
#include <sys/kernel.h>
+#include <sys/lock.h>
+#include <sys/mutex.h>
#include <vm/vm.h>
#include <vm/pmap.h>
@@ -2290,6 +2292,8 @@ amd_init(device_t dev)
/*maxsize*/MAXBSIZE, /*nsegments*/AMD_NSEG,
/*maxsegsz*/AMD_MAXTRANSFER_SIZE,
/*flags*/BUS_DMA_ALLOCNOW,
+ /*lockfunc*/busdma_lock_mutex,
+ /*lockarg*/&Giant,
&amd->buffer_dmat) != 0) {
if (bootverbose)
printf("amd_init: bus_dma_tag_create failure!\n");
@@ -2305,7 +2309,9 @@ amd_init(device_t dev)
sizeof(struct scsi_sense_data) * MAX_SRB_CNT,
/*nsegments*/1,
/*maxsegsz*/AMD_MAXTRANSFER_SIZE,
- /*flags*/0, &amd->sense_dmat) != 0) {
+ /*flags*/0,
+ /*lockfunc*/busdma_lock_mutex,
+ /*lockarg*/&Giant, &amd->sense_dmat) != 0) {
if (bootverbose)
device_printf(dev, "cannot create sense buffer dmat\n");
return (ENXIO);