arch/x86/ioapic: use uintptr_t for IOAPIC base address

Use uintptr_t for the IOAPIC base parameter of the various IOAPIC-
related functions to avoid needing type casts in the callers. This also
allows dropping the VIO_APIC_VADDR define and consistently use the
IO_APIC_ADDR define instead.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I912943e923ff092708e90138caa5e1daf269a69f
Reviewed-on: https://review.coreboot.org/c/coreboot/+/80358
Reviewed-by: Elyes Haouas <ehaouas@noos.fr>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Matt DeVillier <matt.devillier@amd.corp-partner.google.com>
Reviewed-by: Jérémy Compostella <jeremy.compostella@intel.com>
diff --git a/src/arch/x86/mpspec.c b/src/arch/x86/mpspec.c
index ac3fc79..f5242d3 100644
--- a/src/arch/x86/mpspec.c
+++ b/src/arch/x86/mpspec.c
@@ -11,8 +11,8 @@
 #include <device/pci_def.h>
 #include <device/pci_ids.h>
 #include <identity.h>
-#include <stdint.h>
 #include <string.h>
+#include <types.h>
 
 /* Initialize the specified "mc" struct with initial values. */
 void mptable_init(struct mp_config_table *mc)
@@ -207,7 +207,7 @@
  * APIC Flags:EN, Address
  */
 static void smp_write_ioapic(struct mp_config_table *mc,
-	u8 id, u8 ver, void *apicaddr)
+	u8 id, u8 ver, uintptr_t apicaddr)
 {
 	struct mpc_config_ioapic *mpc;
 	mpc = smp_next_mpc_entry(mc);
@@ -216,11 +216,11 @@
 	mpc->mpc_apicid = id;
 	mpc->mpc_apicver = ver;
 	mpc->mpc_flags = MPC_APIC_USABLE;
-	mpc->mpc_apicaddr = apicaddr;
+	mpc->mpc_apicaddr = (void *)apicaddr;
 	smp_add_mpc_entry(mc, sizeof(*mpc));
 }
 
-u8 smp_write_ioapic_from_hw(struct mp_config_table *mc, void *apicaddr)
+u8 smp_write_ioapic_from_hw(struct mp_config_table *mc, uintptr_t apicaddr)
 {
 	u8 id = get_ioapic_id(apicaddr);
 	u8 ver = get_ioapic_version(apicaddr);