Verified Commit 1917749b authored by Recolic Keghart's avatar Recolic Keghart
Browse files

> Manual commit: keyboard code added

U201614531
recolic
Linux RECOLICPC 5.4.6-arch3-1 #1 SMP PREEMPT Tue, 24 Dec 2019 04:36:53 +0000 x86_64 GNU/Linux
 21:40:47 up 2 days,  3:14,  1 user,  load average: 1.46, 1.21, 1.21
99c5fc3af793f6de570abffbfc804632e49f21b
parent 3e49770a
Pipeline #801 passed with stages
in 3 minutes and 33 seconds
......@@ -15,7 +15,7 @@ uint8_t pmem[PMEM_SIZE];
__attribute__((hot)) uint32_t paddr_read(paddr_t addr, int len) {
static const uint32_t niddle[] = {0, 0xff, 0xffff, 0xffffff, 0xffffffff};
if(const auto mmio_id = is_mmio(addr);(-1 == mmio_id)) {
if(const auto mmio_id = is_mmio(addr); RLIB_MACRO_LIKELY(-1 == mmio_id)) {
return pmem_rw(addr, uint32_t) & niddle[len];
}
else {
......@@ -24,7 +24,7 @@ __attribute__((hot)) uint32_t paddr_read(paddr_t addr, int len) {
}
void paddr_write(paddr_t addr, uint32_t data, int len) {
if(const auto mmio_id = is_mmio(addr);(-1 == mmio_id)) {
if(const auto mmio_id = is_mmio(addr); RLIB_MACRO_LIKELY(-1 == mmio_id)) {
memcpy(guest_to_host(addr), &data, len);
}
else {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment