Module Name: src Committed By: msaitoh Date: Wed Jun 19 06:32:46 UTC 2019
Modified Files: src/sys/arch/x86/include: i82093reg.h src/sys/arch/x86/x86: ioapic.c Log Message: Fix ioapic_dump_raw() to dump whole ioapic area. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/arch/x86/include/i82093reg.h cvs rdiff -u -r1.62 -r1.63 src/sys/arch/x86/x86/ioapic.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/arch/x86/include/i82093reg.h diff -u src/sys/arch/x86/include/i82093reg.h:1.5 src/sys/arch/x86/include/i82093reg.h:1.6 --- src/sys/arch/x86/include/i82093reg.h:1.5 Sat Apr 22 04:25:09 2017 +++ src/sys/arch/x86/include/i82093reg.h Wed Jun 19 06:32:46 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: i82093reg.h,v 1.5 2017/04/22 04:25:09 nonaka Exp $ */ +/* $NetBSD: i82093reg.h,v 1.6 2019/06/19 06:32:46 msaitoh Exp $ */ /*- * Copyright (c) 2000 The NetBSD Foundation, Inc. @@ -81,8 +81,9 @@ * Redirection table registers. */ -#define IOAPIC_REDHI(pin) (0x11 + ((pin)<<1)) -#define IOAPIC_REDLO(pin) (0x10 + ((pin)<<1)) +#define IOAPIC_REDTBL 0x10 +#define IOAPIC_REDHI(pin) (IOAPIC_REDTBL + ((pin) << 1) + 1) +#define IOAPIC_REDLO(pin) (IOAPIC_REDTBL + ((pin) << 1)) #define IOAPIC_REDHI_DEST_SHIFT 24 /* destination. */ #define IOAPIC_REDHI_DEST_MASK 0xff000000 Index: src/sys/arch/x86/x86/ioapic.c diff -u src/sys/arch/x86/x86/ioapic.c:1.62 src/sys/arch/x86/x86/ioapic.c:1.63 --- src/sys/arch/x86/x86/ioapic.c:1.62 Mon Jun 17 06:38:30 2019 +++ src/sys/arch/x86/x86/ioapic.c Wed Jun 19 06:32:46 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: ioapic.c,v 1.62 2019/06/17 06:38:30 msaitoh Exp $ */ +/* $NetBSD: ioapic.c,v 1.63 2019/06/19 06:32:46 msaitoh Exp $ */ /*- * Copyright (c) 2000, 2009 The NetBSD Foundation, Inc. @@ -64,7 +64,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: ioapic.c,v 1.62 2019/06/17 06:38:30 msaitoh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ioapic.c,v 1.63 2019/06/19 06:32:46 msaitoh Exp $"); #include "opt_ddb.h" @@ -611,7 +611,7 @@ ioapic_dump_raw(void) printf(" %08x", (u_int)reg); if (++i % 0x08 == 0) printf("\n"); - } while (i < 0x40); + } while (i < IOAPIC_REDTBL + (sc->sc_apic_sz * 2)); } } #endif