cpu/x86/lapic: Unify some parameter
Change-Id: I790fddea747f5db0536159e6c2ac90ea1da2830e Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/60712 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
This commit is contained in:
parent
c8d26c0158
commit
0c1158b15d
|
@ -18,9 +18,9 @@ static __always_inline void xapic_write(unsigned int reg, uint32_t v)
|
|||
write32((volatile void *)(uintptr_t)(LAPIC_DEFAULT_BASE + reg), v);
|
||||
}
|
||||
|
||||
static __always_inline void xapic_send_ipi(uint32_t icrlow, uint32_t apicid)
|
||||
static __always_inline void xapic_send_ipi(uint32_t icrlow, uint32_t icrhi)
|
||||
{
|
||||
xapic_write(LAPIC_ICR2, SET_LAPIC_DEST_FIELD(apicid));
|
||||
xapic_write(LAPIC_ICR2, icrhi);
|
||||
xapic_write(LAPIC_ICR, icrlow);
|
||||
}
|
||||
|
||||
|
@ -51,10 +51,10 @@ static __always_inline void x2apic_write(unsigned int reg, uint32_t v)
|
|||
wrmsr(index, msr);
|
||||
}
|
||||
|
||||
static __always_inline void x2apic_send_ipi(uint32_t icrlow, uint32_t apicid)
|
||||
static __always_inline void x2apic_send_ipi(uint32_t icrlow, uint32_t icrhi)
|
||||
{
|
||||
msr_t icr;
|
||||
icr.hi = apicid;
|
||||
icr.hi = icrhi;
|
||||
icr.lo = icrlow;
|
||||
wrmsr(X2APIC_MSR_ICR_ADDRESS, icr);
|
||||
}
|
||||
|
@ -112,7 +112,7 @@ static __always_inline void lapic_send_ipi(uint32_t icrlow, uint32_t apicid)
|
|||
if (is_x2apic_mode())
|
||||
x2apic_send_ipi(icrlow, apicid);
|
||||
else
|
||||
xapic_send_ipi(icrlow, apicid);
|
||||
xapic_send_ipi(icrlow, SET_LAPIC_DEST_FIELD(apicid));
|
||||
}
|
||||
|
||||
static __always_inline int lapic_busy(void)
|
||||
|
|
Loading…
Reference in New Issue