i386: Add safe variants of rdmsr_on_cpu and wrmsr_on_cpu
authorRudolf Marek <r.marek@assembler.cz>
Tue, 8 May 2007 15:22:01 +0000 (17:22 +0200)
committerJean Delvare <khali@hyperion.delvare>
Tue, 8 May 2007 15:22:01 +0000 (17:22 +0200)
commit4e9baad8f5cb2040e802eff484fad7e721b21c0b
tree35bd0bdbc9185b0a21d56b32fbd78390a06b1b41
parent9ca8e40c8414d25e880b587cbd4d130750c49588
i386: Add safe variants of rdmsr_on_cpu and wrmsr_on_cpu

Add safe (exception handled) variants of rdmsr_on_cpu and wrmsr_on_cpu.
You should use these when the target MSR may not actually exist, as
doing so could trigger an exception which the regular functions do not
handle. The safe variants are slower, though.

The upcoming coretemp hardware monitoring driver will need this.

Signed-off-by: Rudolf Marek <r.marek@assembler.cz>
Cc: Alexey Dobriyan <adobriyan@openvz.org>
Cc: Dave Jones <davej@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
arch/i386/lib/msr-on-cpu.c
include/asm-i386/msr.h
include/asm-x86_64/msr.h