[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: inconsisten sizeof(paddr_t) in userland/kernel for PAE/i386
On Sat, Dec 05, 2009 at 10:51:35AM +0000, Cherry G. Mathew wrote:
> If you run the test program from the agp(4) manpage on XEN3PAE_DOM0
> and GENERIC, it fails on the former, and succeeds in the latter. ( A
> more interesting symptom is that xf86AllocateGARTMemory() fails for
> xorg on the PAE kernel; ie; no xorg with agp for Xen/i386 dom0s )
> The symptom is caused by inconsistent values of the macro
> AGPIOC_ALLOCATE in user applications and the kernel.
> The reason for this is that sizeof(paddr_t) can vary depending on the
> codebase you're compiling from, due to a double #if clause here:
> There must be a better way to express PAE on i386 within
> machine/types.h, surely ?
What do you mean ? physical addresses are indeed 32bits on i386 without PAE
and 64bit on i386 with PAE. I don't think you want to define paddr_t as
being always 64bits, this would add some overhead for non-PAE kernels
(not to mention that native i386 doesn't support PAE at this time and would
need some work to support 64bit paddr_t, even without PAE support).
Maybe AGPIOC_ALLOCATE should be fixed to not use paddr_t but a fixed size
type instead ?
Manuel Bouyer <bouyer%antioche.eu.org@localhost>
NetBSD: 26 ans d'experience feront toujours la difference
Main Index |
Thread Index |