https://bugzilla.novell.com/show_bug.cgi?id=844336 https://bugzilla.novell.com/show_bug.cgi?id=844336#c0 Summary: wrmsr in msr-tools fails to write whole 64 bits value Classification: openSUSE Product: openSUSE 12.2 Version: Final Platform: x86-64 OS/Version: openSUSE 12.2 Status: NEW Severity: Normal Priority: P5 - None Component: Other AssignedTo: bnc-team-screening@forge.provo.novell.com ReportedBy: jin.kyu.song@intel.com QAContact: qa-bugs@suse.de Found By: --- Blocker: --- User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Firefox/24.0 wrmsr executable included in msr-tools-1.2-43.4.x86_64.rpm cannot write 64bit value to MSR. Only low 32bits are written. Disassembled code for wrmsr : 400aca: e8 41 fe ff ff call 400910 <strtoull@plt> 400acf: 41 83 fc ff cmp r12d,0xffffffff 400ad3: 4c 63 e8 movsxd r13,eax -> return value from strtoull() is treated as 32bits (eax instead of rax). This is where truncation occurs. 400ad6: 74 10 je 400ae8 <__sprintf_chk@plt+0x148> 400ad8: 44 89 e2 mov edx,r12d 400adb: 4c 89 ee mov rsi,r13 -> truncated value is passed to wrmsr_on_cpu() 400ade: 44 89 ff mov edi,r15d 400ae1: e8 9a 01 00 00 call 400c80 <__sprintf_chk@plt+0x2e0> It seems like OpenSuse packager of msr-tools has a wrong prototype of strtoull() or they do not even have a prototype declared. Reproducible: Always Steps to Reproduce: Example : Try setting CQoS per core// Successful # wrmsr –p 1 0xc8f 1 # rdmsr –p 1 0xc8f 1 Try setting CQoS, second attempt //Unsuccessful # wrmsr –p 0 0xc8f 0x10000000 # rdmsr –p 0 0xc8f 0 Expected Results: 0x10000000 msr-tools are moved to 01.org/msr-tools, which directs to the latest (version 1.3) source code repository at github.com/01org/msr-tools . Version 1.3 added cpuid utility. Please update with the latest code. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.