Thank you for this thread, this is the most clear&concise description of exactly what to do to get native power management for newer uefi systems.
I wanted to chime in to report that this method worked to unlock the powermanagement msr via bios on my asus p8h77-m pro. This motherboard, like many of the current asus boards, lack the USB flashback feature, and so flashing the bios is a bit more complicated than in post #1.
There is another thread on that other newbie forum recommending DPCIManager combined with an oracle that will patch your bioses for you.
Instead, one can simply dump your bios using flashrom, patch the bios using mmtool&phonenixtool per post #1, and flashing the result back using flashrom. I think this is superior to relying upon an oracle to do the patching for you.
I compiled the latest flashrom myself and did that portion under linux and it worked fine (just another datapoint that flashrom works fine to bypass asus's flash security under linux not just osx).
I agree with earlier posts that the phoenixtool description in post #1 is a bit lacking, especially since phoenixtool doesn't have full documentation of its own. I used the latest phoenixtool from:
http://forums.mydigi...Dell-EFI-BIOSes , version 2.11 and, from my notes, the workflow was:
Generate .rom file with flashrom using:
flashrom -p internal -r file.rom
Run phoenixtool
Open .cap file (or as in my case, the .rom file you generated using flashrom)
Select Manufacturer ASUS
click advanced
in response to are you sure, click yes
select 'Allow user to modify other modules'
select 'No SLIC'
click done
click go
See dialog box that it is OK to modify files in the DUMP directory
Work on patch as shown below
Move your patched PowerManagement module into the DUMP dump directory
Click OK
Also, after one has decompiled the PowerManagement module and verified that it matches up with post #1, it is perhaps easiest to do the patch with the perl one-liner:
perl -pi -e 's|\x75\x08\x0f\xba\xe8\x0f\x89\x44\x24\x30|\xeb\x08\x0f\xba\xe8\x0f\x89\x44\x24\x30|' <filename>
where <filename> is the name you get for the PowerManagement module from mmtool.
To in turn get the PowerManagement module from mmtool, you run mmtool, select 'Load Image', select your .rom/.cap file, select create report.
Then from a shell:
grep PowerManagement <file.rpt>
where <file.rpt> is the .rpt file generated by mmtool.
For example, on my system:
% grep PowerManagement P8H77-M-PRO-ASUS-1003.rpt
|139|PowerManagement|8C783970-F02A-4A4D-AF09-8797A51EEC8D|0040A120|0032C9|DRVR|
% cd DUMP
#Note: _1 suffix selects 2nd module file that matches the GUID above; the first
#file is just header information for the module
% ls -l 8C783970-F02A-4A4D-AF09-8797A51EEC8D_1*
-rwxr--r-- 1 root root 22984 Nov 8 22:01 8C783970-F02A-4A4D-AF09-8797A51EEC8D_1_407.ROM*
% cp 8C783970-F02A-4A4D-AF09-8797A51EEC8D_1_407.ROM ../powermanagement
% cd ..
% objdump -m i386 -b binary -D powermanagement > pm.asm
#Verify assembly; then patch with:
% perl -pi -e 's|\x75\x08\x0f\xba\xe8\x0f\x89\x44\x24\x30|\xeb\x08\x0f\xba\xe8\x0f\x89\x44\x24\x30|' powermanagement
# When ready to apply patch (at final dialog from phoenixtool):
# cp powermanagement DUMP/8C783970-F02A-4A4D-AF09-8797A51EEC8_1_407.ROM
Then after phoenixtool builds the new .rom file, flashing with
% flashrom -p internal -w 1003.v2_SLIC.rom
And the patch uefi bios is flashed. Then,the result (as seen under linux):
% rdmsr 0xe2
1e000400
%
Ie bit 15 is clear in the offending MSR (MSR_PKG_CST_CONFIG_CONTROL)
Now my system runs without NullCPUPowermanagement.
My system still doesn't suspend correctly (it hangs before suspending completely, and won't wake back up) so I'm not sure what else I have to do here. Probably some special usb setting is necessary? Hints anyone? suspend&resume work fine under linux.