From 56948f82f5dc2d74432bc167dc307d2efa804e97 Mon Sep 17 00:00:00 2001 From: phk Date: Wed, 22 Sep 1999 19:56:14 +0000 Subject: Kill the cdevsw->d_maxio field. d_maxio is replaced by the dev->si_iosize_max field which the driver should be set in all calls to cdevsw->d_open if it has a better idea than the system wide default. The field is a generic dev_t field (ie: not disk specific) so that tapes and other devices can use physio as well. --- sys/kern/kern_physio.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'sys/kern/kern_physio.c') diff --git a/sys/kern/kern_physio.c b/sys/kern/kern_physio.c index cc436bf..01bc7f3 100644 --- a/sys/kern/kern_physio.c +++ b/sys/kern/kern_physio.c @@ -172,14 +172,9 @@ u_int minphys(bp) struct buf *bp; { - u_int maxphys = DFLTPHYS; - struct cdevsw *bdsw; + u_int maxphys; - bdsw = devsw(bp->b_dev); - - if (bdsw && bdsw->d_maxio) { - maxphys = bdsw->d_maxio; - } + maxphys = bp->b_dev->si_iosize_max; if (bp->b_kvasize && (bp->b_kvasize < maxphys)) maxphys = bp->b_kvasize; -- cgit v1.1