diff options
author | peter <peter@FreeBSD.org> | 1998-04-16 10:35:50 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 1998-04-16 10:35:50 +0000 |
commit | b8ece98820a93e36152d499c4aa67946e3d12b43 (patch) | |
tree | eaee262fc5daf03a414c6c486ed8738597024744 /sys/scsi | |
parent | 7e960e23c8a2d7dadca04b3344225434cb3d06a1 (diff) | |
download | FreeBSD-src-b8ece98820a93e36152d499c4aa67946e3d12b43.zip FreeBSD-src-b8ece98820a93e36152d499c4aa67946e3d12b43.tar.gz |
fix an obvious broken BOUNCE_BUFFER case.
Diffstat (limited to 'sys/scsi')
-rw-r--r-- | sys/scsi/st.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/sys/scsi/st.c b/sys/scsi/st.c index 8993ede..174bf85 100644 --- a/sys/scsi/st.c +++ b/sys/scsi/st.c @@ -12,7 +12,7 @@ * on the understanding that TFS is not responsible for the correct * functioning of this software in any circumstances. * - * $Id: st.c,v 1.84 1997/12/02 21:07:05 phk Exp $ + * $Id: st.c,v 1.85 1998/01/24 02:54:53 eivind Exp $ */ /* @@ -1911,7 +1911,11 @@ st_touch_tape(unit) u_int32_t readsiz; errval errno; +#ifdef BOUNCE_BUFFERS + buf = (caddr_t) vm_bounce_kva_alloc(btoc(1024)); +#else buf = malloc(1024, M_TEMP, M_NOWAIT); +#endif if (!buf) return (ENOMEM); @@ -1938,7 +1942,11 @@ bad: free(buf, M_TEMP); return (errno); } } while (readsiz != 1 && readsiz > st->blksiz); +#ifdef BOUNCE_BUFFERS + vm_bounce_kva_alloc_free((vm_offset_t) buf, btoc(1024)); +#else free(buf, M_TEMP); +#endif return 0; } |