arch/x86/ioapic: Add get_ioapic_id() and get_ioapic_version()
Change-Id: I4ad080653c9af94a4dc73d93ddc4c8c117a682b9 Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/55282 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Furquan Shaikh <furquan@google.com> Reviewed-by: Angel Pons <th3fanbus@gmail.com>
This commit is contained in:
@@ -109,6 +109,16 @@ void set_ioapic_id(void *ioapic_base, u8 ioapic_id)
|
||||
|
||||
}
|
||||
|
||||
u8 get_ioapic_id(void *ioapic_base)
|
||||
{
|
||||
return (io_apic_read(ioapic_base, 0x00) >> 24) & 0x0f;
|
||||
}
|
||||
|
||||
u8 get_ioapic_version(void *ioapic_base)
|
||||
{
|
||||
return io_apic_read(ioapic_base, 0x01) & 0xff;
|
||||
}
|
||||
|
||||
void setup_ioapic_helper(void *ioapic_base, u8 ioapic_id, bool irq_on_fsb,
|
||||
bool enable_virtual_wire)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user