summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_physio.c
diff options
context:
space:
mode:
authordg <dg@FreeBSD.org>1994-08-07 13:10:43 +0000
committerdg <dg@FreeBSD.org>1994-08-07 13:10:43 +0000
commit81dc370a9d5a2ec97a413123079d94be91110fbe (patch)
treec701e7ef61340402192c9838085c1028a0a3b07c /sys/kern/kern_physio.c
parent024b33e58ce38e9533965d82b09863cc5f9aefd7 (diff)
downloadFreeBSD-src-81dc370a9d5a2ec97a413123079d94be91110fbe.zip
FreeBSD-src-81dc370a9d5a2ec97a413123079d94be91110fbe.tar.gz
Provide support for upcoming merged VM/buffer cache, and fixed a few bugs
that haven't appeared to manifest themselves (yet). Submitted by: John Dyson
Diffstat (limited to 'sys/kern/kern_physio.c')
-rw-r--r--sys/kern/kern_physio.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/sys/kern/kern_physio.c b/sys/kern/kern_physio.c
index 487e38e..0fcb0bf 100644
--- a/sys/kern/kern_physio.c
+++ b/sys/kern/kern_physio.c
@@ -16,7 +16,7 @@
* 4. Modifications may be freely made to this file if the above conditions
* are met.
*
- * $Id: kern_physio.c,v 1.3 1994/08/02 07:42:05 davidg Exp $
+ * $Id: kern_physio.c,v 1.4 1994/08/06 09:15:28 davidg Exp $
*/
#include <sys/param.h>
@@ -27,6 +27,7 @@
#include <vm/vm.h>
static void physwakeup();
+u_int minphys(struct buf *bp);
int
physio(strategy, bp, dev, rw, minp, uio)
@@ -78,6 +79,9 @@ physio(strategy, bp, dev, rw, minp, uio)
caddr_t adr;
bp->b_bcount = uio->uio_iov[i].iov_len;
+ bp->b_bcount = minp( bp);
+ if( minp != minphys)
+ bp->b_bcount = minphys( bp);
bp->b_bufsize = bp->b_bcount;
bp->b_flags = B_BUSY | B_PHYS | B_CALL | bufflags;
bp->b_iodone = physwakeup;
OpenPOWER on IntegriCloud