x86, apic: refactor ->get_apic_id() & GET_APIC_ID()