On 04/01/2010 17:46, Manuel Bouyer wrote: > what issue with ptoa() did you see ? I understand how bad trucating to > vaddr_t here can be, but it's not an issue with Xen so I wonder why > it's needed in the native case. The problem I ran into was this [0] portion of uvm_page_init() - For a high segment of memory (0x100000000 -> 0x1FFFF8000 on my machine) the top part of the address is lost by ptoa(), leading to incorrect paddr calculations in the following loop. (The upshot is that high memory gets silently ignored). This behavior won't occur if memory is reported as one segment with the first address below the 4Gb boundry - could this be why Xen doesn't have trouble with that piece of code? [0] http://nxr.netbsd.org/xref/src/sys/uvm/uvm_page.c#442 -- Thanks, Jeremy
Attachment:
signature.asc
Description: OpenPGP digital signature