← Back to team overview

sony-vaio-z-series team mailing list archive

Poor BIOS Memory Remap and VT support

 

Hi all,
I have a VGN-Z21WN/B, now I'm using Windows XP from the downgrade CD
but I'm planning to use only Linux.
The Z21 have 4 GiB that is remapped (there is no option in BIOS) : up
to 3 GiB the CPU can access directly the RAM.
Then, up to 4 GiB there is 1 GiB window for PCI memory address range
to be reclaimed with minimal loss of available physical memory.
The BIOS establishes a remap window at the top of physical memory. The
remap window corresponds to the PCI memory address range.
So there is available 1 GiB of Memory up to 5 GiB (addressable only
with 64bit O.S.)

>From the chipset specs: http://www.intel.com/Assets/PDF/datasheet/319122.pdf

Top of Memory
The "Top of Memory" (TOM) register reflects the total amount of
populated physical
memory. This is NOT necessarily the highest main memory address (holes
may exist in
main memory address map due to addresses allocated for memory mapped I/O above
TOM). TOM is used to allocate the Intel Management Engine's stolen
memory. The Intel
ME stolen size register reflects the total amount of physical memory
stolen by the Intel
ME. The ME stolen memory is located at the top of physical memory. The ME stolen
memory base is calculated by subtracting the amount of memory stolen
by the Intel ME
from TOM.
The Top of Upper Usable Dram (TOUUD) register reflects the total amount of
addressable DRAM. If reclaim is disabled, TOUUD will reflect TOM minus
Intel ME stolen
size. If reclaim is enabled, then it will reflect the reclaim limit.
Also, the reclaim base
will be the same as TOM minus ME stolen memory size to the nearest 64
MB alignment.
TOLUD register is restricted to 4 GB memory (A[31:20]), but the MCH
can support up
to 16 GB, limited by DRAM pins.


There is no way to enable/disable Memory-Remap feature (Memory
Reclaim) in the BIOS but it is already enabled so that's OK.
Now here comes the problem. I need to be able to enable VT support in
the BIOS, but it doesn't give me the option.
The official Sony line is that VT "Is not supported".

The Sony BIOS doesn't enable VMX, and locks MSR 0x3A so it can't be
enabled by the operating system later.
The feature control MSR 0x3A has two bits of interest for VT: the
VMXON enable bit (bit 2) and the lock bit (bit 0). If the lock bit is
clear, the contents of the MSR can be changed by the wrmsr
instruction. If the lock bit is set, the contents of the MSR cannot be
changed, except by cycling power to the CPU, which resets the MSR to
0.
For VT to work, both of these bits must be set.
A BIOS that explicitly disables VT will leave the VMXON enable bit
clear and set the lock bit. If the BIOS does this, the only recourse
is to change the behavior of the BIOS. However, some BIOSes may just
leave the MSR at its power-on value of 0. In this state, the MSR can
still be changed by privileged (CPL 0) software.
On a multiprocessor/multicore system, each core has its own feature
control MSR, and the two bits must be set on all processors where you
want to use VT. To further complicate matters, the MSR has to be set
again each time the system awakens from deep sleep (S4), since the
processor loses power in that state. Some BIOS fail to set the MSR
when awakening from S4.

Vaio Z is unfortunately using InsydeH2O UEFI - so Phoenix BIOS trick
will not work and MSR 0x3A is set - which means that VT is disabled
and locked and Insyde firmware does not forget to re-disable it every
time CPU wakes up from S4 (sleep)

Now I'm investigating how to enable VT support in BIOS, any help is appreciated.
-- 
Ciao,
   alla prossima_