Il 16/07/2013 20:11, Eduardo Habkost ha scritto: > For physical bit size, what about extending it in a backwards-compatible > way? Something like this: > > *eax = 0x0003000; /* 48 bits virtual */ > if (ram_size < 1TB) { > physical_size = 40; /* Keeping backwards compatibility */ > } else if (ram_size < 4TB) { > physical_size = 42;
Why not go straight up to 44? > } else { > abort(); > } > if (supported_host_physical_size() < physical_size) { > abort(); > } > *eax |= physical_size; > > (Of course, the abort() calls should be replaced with proper error > reporting) This makes sense too. Though the best would be of course to use CPUID values coming from the real processors, and only using 40 for backwards compatibility. Paolo