mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-16 22:39:29 +00:00
HV: make io_write_fn_t return true or false
This patch makes io_write_fn_t return true or false instead of void. Returning true means that the handler in HV process the request completely. Returning false means that we need to re-inject the request to DM after processing it in HV. Tracked-On: #2865 Signed-off-by: Kaige Fu <kaige.fu@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
committed by
ACRN System Integration
parent
ed286e3239
commit
3b2ad67788
@@ -58,16 +58,14 @@ static uint32_t vrtc_read(struct acrn_vm *vm, uint16_t addr, __unused size_t wid
|
||||
return reg;
|
||||
}
|
||||
|
||||
static void vrtc_write(struct acrn_vm *vm, uint16_t addr, size_t width,
|
||||
static bool vrtc_write(struct acrn_vm *vm, uint16_t addr, size_t width,
|
||||
uint32_t value)
|
||||
{
|
||||
|
||||
if (width != 1U)
|
||||
return;
|
||||
|
||||
if (addr == CMOS_ADDR_PORT) {
|
||||
if ((width == 1U) && (addr == CMOS_ADDR_PORT)) {
|
||||
vm->vrtc_offset = value & 0x7FU;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void vrtc_init(struct acrn_vm *vm)
|
||||
|
Reference in New Issue
Block a user