struct CpuidIo

Defined at line 30 of file ../../zircon/kernel/lib/arch/include/lib/arch/x86/cpuid.h

An hwreg-compatible interface for reading CPUID values, where the

"addresses" correspond to the EAX, EBX, ECX, and EDX registers. The values

are expected to be programmatically filled before use, e.g., using

the compiler-supplied

<cpuid

.h> (not included here, since it is x86-only):

```

cpuid_count(leaf, subleaf, values_[CpuidIo::kEax], values_[CpuidIo::kEbx],

values_[CpuidIo::kEcx], values_[CpuidIo::kEdx]);

```

Public Members

uint32_t[4] values_

Public Methods

template <typename T>
T Read (uint32_t reg)

The API needs this to be a template even though only one type is valid.

In the general case, this is usually a template that admits multiple

possible integer types. So calls to it from template-generic code use

`io.template Read

<uint32

_t>(offset)` and the like, which is invalid if

this is not a template function.

Defined at line 44 of file ../../zircon/kernel/lib/arch/include/lib/arch/x86/cpuid.h

Enumerations

enum Register
Name Value
kEax 0
kEbx 1
kEcx 2
kEdx 3

Defined at line 31 of file ../../zircon/kernel/lib/arch/include/lib/arch/x86/cpuid.h