Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 3 Jun 1999 10:05:46 -0600 (MDT)
From:      "Kenneth D. Merry" <ken@plutotech.com>
To:        Jos.Backus@nl.origin-it.com (Jos Backus)
Cc:        zzhang@cs.binghamton.edu (Zhihui Zhang), freebsd-hackers@FreeBSD.ORG
Subject:   Re: The choice of MAXPHYS
Message-ID:  <199906031605.KAA93292@panzer.plutotech.com>
In-Reply-To: <19990603172907.A20792@hal.mpn.cp.philips.com> from Jos Backus at "Jun 3, 1999 05:29:07 pm"

next in thread | previous in thread | raw e-mail | index | archive | help
Jos Backus wrote...
> On Thu, Jun 03, 1999 at 10:40:10AM -0400, Zhihui Zhang wrote:
> > The value of MAXPHYS is chosen to be 64K for the maximum raw I/O transfer
> > size. I am wondering why it is not set larger.
> 
> Just a guess: maybe this has something to do with DMA address counters on ISA
> cards being 16 bit? (ducks) Or is this total nonsense? :-)

Actually, MAXPHYS is 128K, not 64K.  This is from sys/i386/include/param.h:

#define DFLTPHYS        (64 * 1024)     /* default max raw I/O transfer size */
#define MAXPHYS         (128 * 1024)    /* max raw I/O transfer size */ 

MAXPHYS was 64K for a good while, and then John Dyson changed it to 128K in
revision 1.42 of param.h (early '98).

I think the 64K value may have been chosen because cards like the Adaptec
1542 can't handle more than that.  That's the reason the CAM passthrough
driver won't allow transfers larger than 64K in most cases.  We plan on
implementing a facility at some point that will allow userland applications
to ask what the maximum transfer size is for a given path.

At some point we should implement some sort of buffer chaining mechanism or
something else that would allow larger I/O sizes for devices that support
it.

Ken
-- 
Kenneth Merry
ken@plutotech.com


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199906031605.KAA93292>