1
0
Fork 0
mirror of https://github.com/anrieff/libcpuid synced 2024-12-26 16:55:45 +00:00

Add comment about cpu_msrinfo() being not-threadsafe.

This commit is contained in:
Veselin Georgiev 2017-03-04 20:22:13 +02:00
parent 2a2d43b9a3
commit 3272be1d21

View file

@ -1100,6 +1100,8 @@ int cpu_rdmsr_range(struct msr_driver_t* handle, uint32_t msr_index, uint8_t hig
* processor model, the respective value is returned. * processor model, the respective value is returned.
* if no information is available, or the CPU doesn't support * if no information is available, or the CPU doesn't support
* the query, the special value CPU_INVALID_VALUE is returned * the query, the special value CPU_INVALID_VALUE is returned
* @note This function is not MT-safe. If you intend to call it from multiple
* threads, guard it through a mutex or a similar primitive.
*/ */
int cpu_msrinfo(struct msr_driver_t* handle, cpu_msrinfo_request_t which); int cpu_msrinfo(struct msr_driver_t* handle, cpu_msrinfo_request_t which);
#define CPU_INVALID_VALUE 0x3fffffff #define CPU_INVALID_VALUE 0x3fffffff