Skip to content

Commit

Permalink
Fix return value for failed VM exception callbacks
Browse files Browse the repository at this point in the history
I don't know why I even wrote this comment originally. I think
I must have refactored something and not considered this case.

Signed-off-by: Ivan Velickovic <[email protected]>
  • Loading branch information
Ivan-Velickovic committed Sep 19, 2024
1 parent 3880812 commit 3bb3481
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/arch/aarch64/fault.c
Original file line number Diff line number Diff line change
Expand Up @@ -381,14 +381,11 @@ static bool fault_handle_registered_vm_exceptions(size_t vcpu_id, uintptr_t addr
if (addr >= base && addr < end) {
bool success = callback(vcpu_id, addr - base, fsr, regs, data);
if (!success) {
// @ivanv: improve error message
LOG_VMM_ERR("registered virtual memory exception handler for region [0x%lx..0x%lx) at address 0x%lx failed\n", base,
end, addr);
}
/* Whether or not the callback actually successfully handled the
* exception, we return true to say that we at least found a handler
* for the faulting address. */
return true;

return success;
}
}

Expand Down

0 comments on commit 3bb3481

Please sign in to comment.