summaryrefslogtreecommitdiffstats
path: root/sys/dev
diff options
context:
space:
mode:
authormarcel <marcel@FreeBSD.org>2009-07-12 16:46:43 +0000
committermarcel <marcel@FreeBSD.org>2009-07-12 16:46:43 +0000
commit0e0d7918913f4172a6b43b35541958444d31743e (patch)
tree521f0ac2bc5aef023ed64c137b9ebfc21f58a56a /sys/dev
parent32d59587cd275dd8b0e8db80ddc997a52e0771fa (diff)
downloadFreeBSD-src-0e0d7918913f4172a6b43b35541958444d31743e.zip
FreeBSD-src-0e0d7918913f4172a6b43b35541958444d31743e.tar.gz
MFp4:
USB CORE: busdma improvement For single segment allocations the boundary field of the BUSDMA tag should be zero. Currently all single segment allocations are less than or equal to 4096 bytes, so the limit does not kick in. If any single segment USB allocations would be greater than 4K, then it would be a problem. Approved by: re (kensmith) Obtained from: HPS
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/usb/usb_busdma.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/dev/usb/usb_busdma.c b/sys/dev/usb/usb_busdma.c
index 4127449..e5d6ed7 100644
--- a/sys/dev/usb/usb_busdma.c
+++ b/sys/dev/usb/usb_busdma.c
@@ -359,7 +359,8 @@ usb_dma_tag_create(struct usb_dma_tag *udt,
if (bus_dma_tag_create
( /* parent */ udt->tag_parent->tag,
/* alignment */ align,
- /* boundary */ USB_PAGE_SIZE,
+ /* boundary */ (align == 1) ?
+ USB_PAGE_SIZE : 0,
/* lowaddr */ (2ULL << (udt->tag_parent->dma_bits - 1)) - 1,
/* highaddr */ BUS_SPACE_MAXADDR,
/* filter */ NULL,
OpenPOWER on IntegriCloud