tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: [PAE support] Types + cosmetic fixes



On 02/23/10 20:27, Manuel Bouyer wrote:
On Mon, Feb 22, 2010 at 10:25:35AM +0100, Jean-Yves Migeon wrote:
Second small patch [2] contains fixes regarding UVM:
- RLIMIT_RSS which is now set to VM_MAXUSER_ADDRESS (shouldn't it be set to
MIN(VM_MAXUSER_ADDRESS, ptoa(uvmexp.free) instead?),

I think it should be MIN(VM_MAXUSER_ADDRESS, ptoa(uvmexp.free).
Otherwise it's a change in behavior not related to i386PAE.

Just checked, uvmexp elements are "int", so IMHO ctob((rlim_t)uvmexp.free) is less error-prone (again, risk of overflow with free > 4GB).

Not that it could happen on a daily basis :o

- ptoa =>  ctob use (to avoid vaddr_t casts, which might be bad for systems
with total RAM>  4GB)
- a small fix inside AGP heuristics to avoid masking high order bits

Compile tested for ALL, GENERIC, XEN3 kernels for i386, and GENERIC, XEN3*
for amd64.

Looks good.

Committed, thanks

In case someone wonders, if PAE is added as default option for ALL, more
fixes will be needed in some drivers under sys/dev/ (paddr_t vs unsigned
long issues). Question is: should it be added to ALL for additional checks?

I think so. Such issues should be fixed in MI code anyway. paddr_t !=
unsigned long is something we want to support.

Will do.

Thanks all for the review.

Cheers,

--
Jean-Yves Migeon
jeanyves.migeon%free.fr@localhost


Home | Main Index | Thread Index | Old Index