mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-23 09:47:44 +00:00
HV:fix type related violations
1.Function return type inconsistent 2.cast on a constant value V1->V2 add () to return type V2->V3 keep the sbuf_get and sbuf_put return code Tracked-On: #861 Signed-off-by: Huihuang Shi <huihuang.shi@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
@@ -98,9 +98,9 @@ ioapic_read_reg32(const void *ioapic_base, const uint32_t offset)
|
||||
spinlock_irqsave_obtain(&ioapic_lock, &rflags);
|
||||
|
||||
/* Write IOREGSEL */
|
||||
mmio_write32(offset, (void *)ioapic_base + IOAPIC_REGSEL);
|
||||
mmio_write32(offset, ioapic_base + IOAPIC_REGSEL);
|
||||
/* Read IOWIN */
|
||||
v = mmio_read32((void *)ioapic_base + IOAPIC_WINDOW);
|
||||
v = mmio_read32(ioapic_base + IOAPIC_WINDOW);
|
||||
|
||||
spinlock_irqrestore_release(&ioapic_lock, rflags);
|
||||
return v;
|
||||
@@ -115,9 +115,9 @@ ioapic_write_reg32(const void *ioapic_base,
|
||||
spinlock_irqsave_obtain(&ioapic_lock, &rflags);
|
||||
|
||||
/* Write IOREGSEL */
|
||||
mmio_write32(offset, (void *)ioapic_base + IOAPIC_REGSEL);
|
||||
mmio_write32(offset, ioapic_base + IOAPIC_REGSEL);
|
||||
/* Write IOWIN */
|
||||
mmio_write32(value, (void *)ioapic_base + IOAPIC_WINDOW);
|
||||
mmio_write32(value, ioapic_base + IOAPIC_WINDOW);
|
||||
|
||||
spinlock_irqrestore_release(&ioapic_lock, rflags);
|
||||
}
|
||||
|
Reference in New Issue
Block a user