exo2: add a number of minor configuration fixes

This commit is contained in:
Michael Scire authored and SciresM committed 2020-06-14 22:07:45 -07:00
1 parent 8e401f4daa
commit 068c25ce66
5 files changed
+25 -5

No files matched your search

@@ -124,7 +124,11 @@ namespace ams::gic {
const int word = i / scale;
const int bit = (i % scale) * width;
reg::ReadWrite(address + sizeof(u32) * word, REG_BITS_VALUE(bit, width, value));
const u32 mask = ((1u << width) - 1) << bit;
const uintptr_t reg_addr = address + sizeof(u32) * word;
const u32 old = reg::Read(reg_addr) & ~mask;
reg::Write(reg_addr, old | ((value << bit) & mask));
}
void Write(uintptr_t address, int width, int i, u32 value) {