Re: msr(7) manpage

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Feb 24, 2009 at 10:40:57PM +1300, Michael Kerrisk wrote:
> > .\" Some sentences copied from comment in arch/x86/kernel/msr.c
> > .TH MSR 7 2009-02-22 "Linux" "Linux Programmer's Manual"
> > .SH NAME
> > msr \- x86 CPU MSR access device
> > .SH DESCRIPTION
> > .I /dev/cpu/CPUNUM/msr
> > allows to read and write the model specific registers (MSRs) of an x86 CPU.
> > .I CPUNUM
> > is the number of the cpu to access as listed in
> > .I /proc/cpuinfo.
> > The register access is done by opening the file and seeking to the MSR
> > number
> 
> Could you clarify "seek to the MSR number" == does that mean seek to
> offset (MSR_number * 8) or something like that?

No it means seek to MSR number. Yes the semantics are a little weird.

> 
> > as offset in the file and then read or write in chunks of 8 bytes.
> > A larger size than 8 bytes means multiple reads or writes of the
> > same register.
> 
> What are the semantics of reading the same register multiple times?
> Is a read non-destructive?  Do the multiple reads always get the same
> value?

It depends on the hardware. A typical x86 CPU has hundreds
of different MSRs. Typically they're non destructive, but some
might still change. I intentionally didn't try to cover that but
just added references (although those could be probably also
extended)

BTW what I also forgot was a note that it's root only.

Please just edit it yourself. I assume you'll be doing that anyways.

-Andi

-- 
ak@xxxxxxxxxxxxxxx -- Speaking for myself only.
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Documentation]     [Netdev]     [Linux Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux