Add rdmsr/wrmsr to io.cpp

This commit is contained in:
Justin C. Miller
2018-04-29 13:24:02 -07:00
parent b3e49590a7
commit cfecf4f1d4
2 changed files with 26 additions and 0 deletions

View File

@@ -14,6 +14,16 @@ uint8_t inb(uint16_t port);
/// \arg val The byte to write
void outb(uint16_t port, uint8_t val);
/// Read the value of a MSR
/// \arg addr The MSR address
/// \returns The current value of the MSR
uint64_t rdmsr(uint64_t addr);
/// Write to a MSR
/// \arg addr The MSR address
/// \arg value The value to write
void wrmsr(uint64_t addr, uint64_t value);
}
const uint16_t COM1 = 0x03f8;