Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 05 Jul 2009 11:38:23 +0300
From:      Alexander Motin <mav@FreeBSD.org>
To:        gary.jennejohn@freenet.de
Cc:        freebsd-arch@freebsd.org
Subject:   Re: DFLTPHYS vs MAXPHYS
Message-ID:  <4A50667F.7080608@FreeBSD.org>
In-Reply-To: <20090705100044.4053e2f9@ernst.jennejohn.org>
References:  <4A4FAA2D.3020409@FreeBSD.org> <20090705100044.4053e2f9@ernst.jennejohn.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Gary Jennejohn wrote:
> On Sat, 04 Jul 2009 22:14:53 +0300
> Alexander Motin <mav@FreeBSD.org> wrote:
> 
>> Can somebody explain me a difference between DFLTPHYS and MAXPHYS 
>> constants? As I understand, the last one is a maximal amount of memory, 
>> that can be mapped to the kernel, or passed to the hardware drivers. But 
>> why then DFLTPHYS is used in so many places and what does it mean?
> 
> There's a pretty good comment on these in /sys/conf/NOTES.

But it does not explains why.

>> Isn't it a time to review their values for increasing? 64KB looks funny, 
>> comparing to modern memory sizes and data rates. It just increases 
>> interrupt rates, but I don't think it really need to be so small to 
>> improve interactivity now.
> 
> Probably historical from the days when memory was scarce.
> 
> There's nothing preventing the user from upping these values in his
> kernel config file.  But note the warning in NOTES about possibly
> making the kernel unbootable.  It's not clear whether this warning is
> still valid given todays larger memory footprints and the inmproved
> VM system.
> 
> I wonder whether all drivers can correctly handle larger values for
> DFLTPHYS.

There are always will be drivers/devices with limitations. They should 
just be able to report that limitations to system. This is possible with 
GEOM, but it doesn't looks tuned well for all providers. There are many 
places, when DFLTPHYS used just with hope that it will work. IMHO if 
driver unable to adapt to any defined DFLTPHYS value, it should not use 
it, but instead should announce some specific value that it really supports.

-- 
Alexander Motin



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