diff options
| author | Matt Jacob <mjacob@FreeBSD.org> | 2007-06-11 17:57:24 +0000 |
|---|---|---|
| committer | Matt Jacob <mjacob@FreeBSD.org> | 2007-06-11 17:57:24 +0000 |
| commit | f2114f3bcd6d262d1d1ae3e98a5e63f0c149dae8 (patch) | |
| tree | d75551979d4da4e2cf5483d16ace1ef9958137c4 /sys/amd64 | |
| parent | 9b434ede5cbcf005dc46d72278bba24336a3775d (diff) | |
Notes
Diffstat (limited to 'sys/amd64')
| -rw-r--r-- | sys/amd64/amd64/busdma_machdep.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/amd64/amd64/busdma_machdep.c b/sys/amd64/amd64/busdma_machdep.c index 59495bfc198a..462abe97b387 100644 --- a/sys/amd64/amd64/busdma_machdep.c +++ b/sys/amd64/amd64/busdma_machdep.c @@ -220,6 +220,10 @@ bus_dma_tag_create(bus_dma_tag_t parent, bus_size_t alignment, if (boundary != 0 && boundary < maxsegsz) maxsegsz = boundary; + if (maxsegsz == 0) { + return (EINVAL); + } + /* Return a NULL tag on failure */ *dmat = NULL; |
