Re: [PATCH] x86: set PAE PHYSICAL_MASK_SHIFT to match 64-bit



H. Peter Anvin wrote:
Jeremy Fitzhardinge wrote:

We could have an auction:

Do I hear 46? 47? 48? 50? 52! Going once, twice, 52 bits!

Anyway, we can fix it later in a separate patch. This is a change-as-little-as-possible bugfix patch.


It should either be 52 bits or dynamic based on CPUID information. The latter is very expensive.

I'm more concerned that it might not be possible. I'm trying to think how many places have compile-time constants derived from this mask. Maybe not too many.

If there end up being additional control bits assigned in this space we won't use them since we know the size of the address space (which won't include the control bits) and thus will leave them at zero.

You mean, if new bits appear we can just adjust the mask accordingly to avoid them? And if we don't use them, then they'll be zero?

It's largely theoretical, since I believe Linux on x86-64 relies on virtual >= physical+N, where I believe N is about 3 bits, and the page table format or page size need to change to support more than 48 bits of virtual address space.

I don't see any relationship between the physical and virtual size. Certainly virtual is fixed at 48 bits (4*9+12), but I don't think there's any deep reason why physical needs to be within 3 bits.

J
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



Relevant Pages

  • Re: [PATCH] x86: set PAE PHYSICAL_MASK_SHIFT to match 64-bit
    ... I'm trying to think how many places have compile-time constants derived from this mask. ... we won't use them since we know the size of the address space and thus will leave them at zero. ... Certainly virtual is fixed at 48 bits, but I don't think there's any deep reason why physical needs to be within 3 bits. ...
    (Linux-Kernel)
  • Re: Determining what should be blocked in and out?
    ... mask, the .0, will always make the last byte of the IP address you're ... zero always for the purposes of checking if it's to be blocked. ... IP address you are trying to contact is on the same network as you. ... Since this equals the same network to be blocked, ...
    (comp.security.firewalls)
  • Re: [PATCH] mask ADT: bitmap and bitop tweaks [1/22]
    ... And 2.6.4 deviates from my bitmap model by a couple of *_complement ... the CPU_MASK_ALL code for large systems ... If input tails are zero, then output tails will be zero. ...
    (Linux-Kernel)
  • Re: Heisenbug in Intels MINLOC()
    ... "If ARRAY has size zero or every element of MASK has the value false, all elements of the result are zero." ... pretty egregious error when it states the result is processor dependent. ...
    (comp.lang.fortran)