From: mpi Date: Sun, 30 Apr 2017 16:45:45 +0000 (+0000) Subject: Rename Debugger() into db_enter(). X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=e97088d66c8eee044cad550a3fd9fad00889544f;p=openbsd Rename Debugger() into db_enter(). Using a name with the 'db_' prefix makes it invisible from the dynamic profiler. ok deraadt@, kettenis@, visa@ --- diff --git a/sys/arch/alpha/alpha/db_interface.c b/sys/arch/alpha/alpha/db_interface.c index 80b91dd1786..9249bf3a9a3 100644 --- a/sys/arch/alpha/alpha/db_interface.c +++ b/sys/arch/alpha/alpha/db_interface.c @@ -1,4 +1,4 @@ -/* $OpenBSD: db_interface.c,v 1.22 2016/04/27 11:03:24 mpi Exp $ */ +/* $OpenBSD: db_interface.c,v 1.23 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: db_interface.c,v 1.8 1999/10/12 17:08:57 jdolecek Exp $ */ /* @@ -220,7 +220,7 @@ db_write_bytes(addr, size, data) } void -Debugger() +db_enter() { __asm volatile("call_pal 0x81"); /* bugchk */ diff --git a/sys/arch/alpha/alpha/lock_machdep.c b/sys/arch/alpha/alpha/lock_machdep.c index 4c03840657b..21100c8c0ef 100644 --- a/sys/arch/alpha/alpha/lock_machdep.c +++ b/sys/arch/alpha/alpha/lock_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: lock_machdep.c,v 1.4 2016/03/19 11:34:22 mpi Exp $ */ +/* $OpenBSD: lock_machdep.c,v 1.5 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2007 Artur Grabowski @@ -80,7 +80,7 @@ __mp_lock_spin(struct __mp_lock *mpl) if (nticks == 0) { db_printf("__mp_lock(%p): lock spun out", mpl); - Debugger(); + db_enter(); } #endif } @@ -128,7 +128,7 @@ __mp_unlock(struct __mp_lock *mpl) #ifdef MP_LOCKDEBUG if (mpl->mpl_cpu != curcpu()) { db_printf("__mp_unlock(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif @@ -150,7 +150,7 @@ __mp_release_all(struct __mp_lock *mpl) #ifdef MP_LOCKDEBUG if (mpl->mpl_cpu != curcpu()) { db_printf("__mp_release_all(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif @@ -170,7 +170,7 @@ __mp_release_all_but_one(struct __mp_lock *mpl) #ifdef MP_LOCKDEBUG if (mpl->mpl_cpu != curcpu()) { db_printf("__mp_release_all_but_one(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif diff --git a/sys/arch/alpha/alpha/machdep.c b/sys/arch/alpha/alpha/machdep.c index 8a22b6bcb71..9a0db1004fe 100644 --- a/sys/arch/alpha/alpha/machdep.c +++ b/sys/arch/alpha/alpha/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.179 2017/04/30 13:04:49 mpi Exp $ */ +/* $OpenBSD: machdep.c,v 1.180 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: machdep.c,v 1.210 2000/06/01 17:12:38 thorpej Exp $ */ /*- @@ -762,7 +762,7 @@ nobootinfo: ddb_init(); if (boothowto & RB_KDB) - Debugger(); + db_enter(); #endif /* * Figure out our clock frequency, from RPB fields. diff --git a/sys/arch/alpha/dev/sgmap_typedep.c b/sys/arch/alpha/dev/sgmap_typedep.c index cb8ef29f7da..ab8643bbfa4 100644 --- a/sys/arch/alpha/dev/sgmap_typedep.c +++ b/sys/arch/alpha/dev/sgmap_typedep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sgmap_typedep.c,v 1.14 2014/07/11 12:55:32 dlg Exp $ */ +/* $OpenBSD: sgmap_typedep.c,v 1.15 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: sgmap_typedep.c,v 1.17 2001/07/19 04:27:37 thorpej Exp $ */ /*- @@ -222,7 +222,7 @@ __C(SGMAP_TYPE,_load)(bus_dma_tag_t t, bus_dmamap_t map, void *buf, #if defined(SGMAP_DEBUG) && defined(DDB) if (__C(SGMAP_TYPE,_debug) > 1) - Debugger(); + db_enter(); #endif if (error == 0) { @@ -281,7 +281,7 @@ __C(SGMAP_TYPE,_load_mbuf)(bus_dma_tag_t t, bus_dmamap_t map, #if defined(SGMAP_DEBUG) && defined(DDB) if (__C(SGMAP_TYPE,_debug) > 1) - Debugger(); + db_enter(); #endif if (error == 0) { @@ -358,7 +358,7 @@ __C(SGMAP_TYPE,_load_uio)(bus_dma_tag_t t, bus_dmamap_t map, struct uio *uio, #if defined(SGMAP_DEBUG) && defined(DDB) if (__C(SGMAP_TYPE,_debug) > 1) - Debugger(); + db_enter(); #endif if (error == 0) { diff --git a/sys/arch/alpha/tc/scc.c b/sys/arch/alpha/tc/scc.c index d25901ee6b2..e790ecc0b26 100644 --- a/sys/arch/alpha/tc/scc.c +++ b/sys/arch/alpha/tc/scc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: scc.c,v 1.29 2010/07/02 17:27:01 nicm Exp $ */ +/* $OpenBSD: scc.c,v 1.30 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: scc.c,v 1.58 2002/03/17 19:40:27 atatat Exp $ */ /* @@ -1084,7 +1084,7 @@ scc_modem_intr(dev) if ((value & ZSRR0_BREAK) && CONSOLE_ON_UNIT(sc->sc_dv.dv_unit)) { #ifdef DDB splx(s); /* spl0()? */ - Debugger(); + db_enter(); return; #else /* XXX maybe fall back to PROM? */ diff --git a/sys/arch/amd64/amd64/cpu.c b/sys/arch/amd64/amd64/cpu.c index 033f4f3c03a..280fde86dc2 100644 --- a/sys/arch/amd64/amd64/cpu.c +++ b/sys/arch/amd64/amd64/cpu.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cpu.c,v 1.102 2016/07/28 21:57:57 kettenis Exp $ */ +/* $OpenBSD: cpu.c,v 1.103 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: cpu.c,v 1.1 2003/04/26 18:39:26 fvdl Exp $ */ /*- @@ -619,7 +619,7 @@ cpu_start_secondary(struct cpu_info *ci) printf("%s: failed to become ready\n", ci->ci_dev->dv_xname); #if defined(MPDEBUG) && defined(DDB) printf("dropping into debugger; continue from here to resume boot\n"); - Debugger(); + db_enter(); #endif } @@ -655,7 +655,7 @@ cpu_boot_secondary(struct cpu_info *ci) printf("cpu failed to start\n"); #if defined(MPDEBUG) && defined(DDB) printf("dropping into debugger; continue from here to resume boot\n"); - Debugger(); + db_enter(); #endif } } diff --git a/sys/arch/amd64/amd64/db_interface.c b/sys/arch/amd64/amd64/db_interface.c index c4050f84b97..c68c74026d9 100644 --- a/sys/arch/amd64/amd64/db_interface.c +++ b/sys/arch/amd64/amd64/db_interface.c @@ -1,4 +1,4 @@ -/* $OpenBSD: db_interface.c,v 1.27 2017/04/20 14:13:00 visa Exp $ */ +/* $OpenBSD: db_interface.c,v 1.28 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: db_interface.c,v 1.1 2003/04/26 18:39:27 fvdl Exp $ */ /* @@ -352,7 +352,7 @@ db_stopcpu(int cpu) void x86_ipi_db(struct cpu_info *ci) { - Debugger(); + db_enter(); } #endif /* MULTIPROCESSOR */ @@ -396,7 +396,7 @@ db_machine_init(void) } void -Debugger(void) +db_enter(void) { breakpoint(); } diff --git a/sys/arch/amd64/amd64/lock_machdep.c b/sys/arch/amd64/amd64/lock_machdep.c index 937ca7c5272..cec96af1987 100644 --- a/sys/arch/amd64/amd64/lock_machdep.c +++ b/sys/arch/amd64/amd64/lock_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: lock_machdep.c,v 1.13 2017/04/20 13:20:17 visa Exp $ */ +/* $OpenBSD: lock_machdep.c,v 1.14 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2007 Artur Grabowski @@ -59,7 +59,7 @@ __mp_lock_spin(struct __mp_lock *mpl, u_int me) if (--nticks <= 0) { db_printf("__mp_lock(%p): lock spun out", mpl); - Debugger(); + db_enter(); nticks = __mp_lock_spinout; } } @@ -99,7 +99,7 @@ ___mp_unlock(struct __mp_lock *mpl LOCK_FL_VARS) #ifdef MP_LOCKDEBUG if (!__mp_lock_held(mpl)) { db_printf("__mp_unlock(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif @@ -149,7 +149,7 @@ ___mp_release_all_but_one(struct __mp_lock *mpl LOCK_FL_VARS) #ifdef MP_LOCKDEBUG if (!__mp_lock_held(mpl)) { db_printf("__mp_release_all_but_one(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif diff --git a/sys/arch/amd64/amd64/machdep.c b/sys/arch/amd64/amd64/machdep.c index e8289c206f4..a65fc470ab8 100644 --- a/sys/arch/amd64/amd64/machdep.c +++ b/sys/arch/amd64/amd64/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.227 2017/04/30 13:04:49 mpi Exp $ */ +/* $OpenBSD: machdep.c,v 1.228 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: machdep.c,v 1.3 2003/05/07 22:58:18 fvdl Exp $ */ /*- @@ -1602,7 +1602,7 @@ init_x86_64(paddr_t first_avail) db_machine_init(); ddb_init(); if (boothowto & RB_KDB) - Debugger(); + db_enter(); #endif } diff --git a/sys/arch/arm/arm/db_interface.c b/sys/arch/arm/arm/db_interface.c index d740cd3f178..322eb123bf6 100644 --- a/sys/arch/arm/arm/db_interface.c +++ b/sys/arch/arm/arm/db_interface.c @@ -1,4 +1,4 @@ -/* $OpenBSD: db_interface.c,v 1.11 2016/04/20 07:59:25 mpi Exp $ */ +/* $OpenBSD: db_interface.c,v 1.12 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: db_interface.c,v 1.34 2003/10/26 23:11:15 chris Exp $ */ /* @@ -340,7 +340,7 @@ db_write_bytes(vaddr_t addr, size_t size, char *data) } void -Debugger(void) +db_enter(void) { asm(".word 0xe7ffffff"); } diff --git a/sys/arch/arm/arm/undefined.c b/sys/arch/arm/arm/undefined.c index 95a9d451b4c..afe94ef85b7 100644 --- a/sys/arch/arm/arm/undefined.c +++ b/sys/arch/arm/arm/undefined.c @@ -1,4 +1,4 @@ -/* $OpenBSD: undefined.c,v 1.9 2017/04/30 13:04:49 mpi Exp $ */ +/* $OpenBSD: undefined.c,v 1.10 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: undefined.c,v 1.22 2003/11/29 22:21:29 bjh21 Exp $ */ /* @@ -242,7 +242,7 @@ undefinedinstruction(trapframe_t *frame) if ((fault_code & FAULT_USER) == 0) { printf("Undefined instruction in kernel\n"); #ifdef DDB - Debugger(); + db_enter(); #endif } diff --git a/sys/arch/arm/cortex/ampintc.c b/sys/arch/arm/cortex/ampintc.c index 3cc51e2bd0b..9e917e7821c 100644 --- a/sys/arch/arm/cortex/ampintc.c +++ b/sys/arch/arm/cortex/ampintc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ampintc.c,v 1.19 2017/03/21 21:51:03 kettenis Exp $ */ +/* $OpenBSD: ampintc.c,v 1.20 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2007,2009,2011 Dale Rahn * @@ -491,7 +491,7 @@ ampintc_irq_handler(void *frame) if ((cnt++ % 100) == 0) { printf("irq %d fired * _100\n", iack_val); #ifdef DDB - Debugger(); + db_enter(); #endif } diff --git a/sys/arch/arm64/arm64/arm64_mutex.c b/sys/arch/arm64/arm64/arm64_mutex.c index 95d27ee7673..216171967d9 100644 --- a/sys/arch/arm64/arm64/arm64_mutex.c +++ b/sys/arch/arm64/arm64/arm64_mutex.c @@ -1,4 +1,4 @@ -/* $OpenBSD: arm64_mutex.c,v 1.1 2016/12/17 23:38:33 patrick Exp $ */ +/* $OpenBSD: arm64_mutex.c,v 1.2 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2004 Artur Grabowski * All rights reserved. @@ -61,7 +61,7 @@ mtx_enter(struct mutex *mtx) #ifdef MP_LOCKDEBUG if (--ticks == 0) { db_printf("%s(%p): lock spun out", __func__, mtx); - Debugger(); + db_enter(); ticks = __mp_lock_spinout; } #endif diff --git a/sys/arch/arm64/arm64/db_interface.c b/sys/arch/arm64/arm64/db_interface.c index 1f39c3f6c24..d5d85b36e77 100644 --- a/sys/arch/arm64/arm64/db_interface.c +++ b/sys/arch/arm64/arm64/db_interface.c @@ -1,4 +1,4 @@ -/* $OpenBSD: db_interface.c,v 1.2 2017/02/17 17:16:04 patrick Exp $ */ +/* $OpenBSD: db_interface.c,v 1.3 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: db_interface.c,v 1.34 2003/10/26 23:11:15 chris Exp $ */ /* @@ -251,7 +251,7 @@ db_write_bytes(vaddr_t addr, size_t size, char *data) } void -Debugger(void) +db_enter(void) { asm("brk 0"); } diff --git a/sys/arch/arm64/arm64/machdep.c b/sys/arch/arm64/arm64/machdep.c index b755b43552b..c86a32747f8 100644 --- a/sys/arch/arm64/arm64/machdep.c +++ b/sys/arch/arm64/arm64/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.14 2017/04/29 10:05:49 jsg Exp $ */ +/* $OpenBSD: machdep.c,v 1.15 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2014 Patrick Wildt * @@ -962,7 +962,7 @@ initarm(struct arm64_bootparams *abp) ddb_init(); if (boothowto & RB_KDB) - Debugger(); + db_enter(); #endif softintr_init(); diff --git a/sys/arch/arm64/dev/agintc.c b/sys/arch/arm64/dev/agintc.c index e2efc1f9aec..fd9e8b53bcf 100644 --- a/sys/arch/arm64/dev/agintc.c +++ b/sys/arch/arm64/dev/agintc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: agintc.c,v 1.2 2017/04/29 18:13:25 kettenis Exp $ */ +/* $OpenBSD: agintc.c,v 1.3 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2007, 2009, 2011, 2017 Dale Rahn * @@ -616,7 +616,7 @@ agintc_irq_handler(void *frame) if ((cnt++ % 100) == 0) { printf("irq %d fired * _100\n", irq); #ifdef DDB - Debugger(); + db_enter(); #endif } } diff --git a/sys/arch/arm64/dev/ampintc.c b/sys/arch/arm64/dev/ampintc.c index acca8ac5745..6e5fecf0ec2 100644 --- a/sys/arch/arm64/dev/ampintc.c +++ b/sys/arch/arm64/dev/ampintc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ampintc.c,v 1.8 2017/04/08 22:31:33 kettenis Exp $ */ +/* $OpenBSD: ampintc.c,v 1.9 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2007,2009,2011 Dale Rahn * @@ -516,7 +516,7 @@ ampintc_irq_handler(void *frame) if ((cnt++ % 100) == 0) { printf("irq %d fired * _100\n", iack_val); #ifdef DDB - Debugger(); + db_enter(); #endif } diff --git a/sys/arch/arm64/dev/bcm2836_intr.c b/sys/arch/arm64/dev/bcm2836_intr.c index 8e374412e99..f106b78c523 100644 --- a/sys/arch/arm64/dev/bcm2836_intr.c +++ b/sys/arch/arm64/dev/bcm2836_intr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bcm2836_intr.c,v 1.2 2017/02/24 17:16:41 patrick Exp $ */ +/* $OpenBSD: bcm2836_intr.c,v 1.3 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2007,2009 Dale Rahn * Copyright (c) 2015 Patrick Wildt @@ -442,7 +442,7 @@ bcm_intc_call_handler(int irq, void *frame) static int cnt = 0; if ((cnt++ % 100) == 0) { printf("irq %d fired * _100\n", irq); - Debugger(); + db_enter(); } } #endif diff --git a/sys/arch/arm64/dev/pluart.c b/sys/arch/arm64/dev/pluart.c index f61b4e61ce2..f07e0f62530 100644 --- a/sys/arch/arm64/dev/pluart.c +++ b/sys/arch/arm64/dev/pluart.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pluart.c,v 1.4 2017/04/30 13:04:49 mpi Exp $ */ +/* $OpenBSD: pluart.c,v 1.5 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2014 Patrick Wildt @@ -310,7 +310,7 @@ pluart_intr(void *arg) #ifdef DDB if (ISSET(sc->sc_hwflags, COM_HW_CONSOLE)) { if (db_console) - Debugger(); + db_enter(); continue; } #endif diff --git a/sys/arch/armv7/armv7/armv7_machdep.c b/sys/arch/armv7/armv7/armv7_machdep.c index 0ee2189d67e..a2fcc8a6094 100644 --- a/sys/arch/armv7/armv7/armv7_machdep.c +++ b/sys/arch/armv7/armv7/armv7_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: armv7_machdep.c,v 1.47 2017/03/24 13:04:16 patrick Exp $ */ +/* $OpenBSD: armv7_machdep.c,v 1.48 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: lubbock_machdep.c,v 1.2 2003/07/15 00:25:06 lukem Exp $ */ /* @@ -790,7 +790,7 @@ initarm(void *arg0, void *arg1, void *arg2, paddr_t loadaddr) ddb_init(); if (boothowto & RB_KDB) - Debugger(); + db_enter(); #endif printf("board type: %u\n", board_id); diff --git a/sys/arch/armv7/broadcom/bcm2836_intr.c b/sys/arch/armv7/broadcom/bcm2836_intr.c index 05e935b627e..27028a08b76 100644 --- a/sys/arch/armv7/broadcom/bcm2836_intr.c +++ b/sys/arch/armv7/broadcom/bcm2836_intr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bcm2836_intr.c,v 1.2 2016/08/07 18:43:17 kettenis Exp $ */ +/* $OpenBSD: bcm2836_intr.c,v 1.3 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2007,2009 Dale Rahn * Copyright (c) 2015 Patrick Wildt @@ -447,7 +447,7 @@ bcm_intc_call_handler(int irq, void *frame) static int cnt = 0; if ((cnt++ % 100) == 0) { printf("irq %d fired * _100\n", irq); - Debugger(); + db_enter(); } } #endif diff --git a/sys/arch/armv7/dev/pluart.c b/sys/arch/armv7/dev/pluart.c index af078552f2f..cc03430bacb 100644 --- a/sys/arch/armv7/dev/pluart.c +++ b/sys/arch/armv7/dev/pluart.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pluart.c,v 1.3 2017/04/30 13:04:49 mpi Exp $ */ +/* $OpenBSD: pluart.c,v 1.4 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2014 Patrick Wildt @@ -314,7 +314,7 @@ pluart_intr(void *arg) #ifdef DDB if (ISSET(sc->sc_hwflags, COM_HW_CONSOLE)) { if (db_console) - Debugger(); + db_enter(); continue; } #endif diff --git a/sys/arch/armv7/omap/if_cpsw.c b/sys/arch/armv7/omap/if_cpsw.c index 0fb3c9c92b9..2813e11cca0 100644 --- a/sys/arch/armv7/omap/if_cpsw.c +++ b/sys/arch/armv7/omap/if_cpsw.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_cpsw.c,v 1.42 2017/01/22 10:17:37 dlg Exp $ */ +/* $OpenBSD: if_cpsw.c,v 1.43 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: if_cpsw.c,v 1.3 2013/04/17 14:36:34 bouyer Exp $ */ /* @@ -1175,7 +1175,7 @@ cpsw_txintr(void *arg) cpsw_get_txdesc(sc, sc->sc_txhead, &bd); if (bd.buflen == 0) { - /* Debugger(); */ + /* db_enter(); */ } if ((bd.flags & CPDMA_BD_SOP) == 0) @@ -1268,7 +1268,7 @@ cpsw_miscintr(void *arg) stat = bus_space_read_4(sc->sc_bst, sc->sc_bsh, CPSW_CPDMA_RX_CP(0)); printf("CPSW_CPDMA_RX0_CP %x\n", stat); - /* Debugger(); */ + /* db_enter(); */ bus_space_write_4(sc->sc_bst, sc->sc_bsh, CPSW_CPDMA_DMA_INTMASK_CLEAR, dmastat); dmastat = bus_space_read_4(sc->sc_bst, sc->sc_bsh, CPSW_CPDMA_DMA_INTSTAT_MASKED); diff --git a/sys/arch/hppa/hppa/db_interface.c b/sys/arch/hppa/hppa/db_interface.c index 80202ff372a..707f6db3e7f 100644 --- a/sys/arch/hppa/hppa/db_interface.c +++ b/sys/arch/hppa/hppa/db_interface.c @@ -1,4 +1,4 @@ -/* $OpenBSD: db_interface.c,v 1.38 2016/09/19 21:18:35 jasper Exp $ */ +/* $OpenBSD: db_interface.c,v 1.39 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 1999-2003 Michael Shalayeff @@ -125,7 +125,7 @@ struct db_variable *db_eregs = db_regs + nitems(db_regs); int db_active = 0; void -Debugger() +db_enter(void) { extern int kernelmapped; /* from locore.S */ if (kernelmapped) diff --git a/sys/arch/hppa/hppa/lock_machdep.c b/sys/arch/hppa/hppa/lock_machdep.c index 7b23204fc13..444e2858f64 100644 --- a/sys/arch/hppa/hppa/lock_machdep.c +++ b/sys/arch/hppa/hppa/lock_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: lock_machdep.c,v 1.9 2016/03/19 11:34:22 mpi Exp $ */ +/* $OpenBSD: lock_machdep.c,v 1.10 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2007 Artur Grabowski @@ -88,7 +88,7 @@ __mp_lock_spin(struct __mp_lock *mpl) if (nticks == 0) { db_printf("__mp_lock(%p): lock spun out", mpl); - Debugger(); + db_enter(); } #endif } @@ -136,7 +136,7 @@ __mp_unlock(struct __mp_lock *mpl) if (mpl->mpl_cpu != curcpu()) { db_printf("__mp_unlock(%p): lock not held - %p != %p\n", mpl, mpl->mpl_cpu, curcpu()); - Debugger(); + db_enter(); } #endif @@ -159,7 +159,7 @@ __mp_release_all(struct __mp_lock *mpl) if (mpl->mpl_cpu != curcpu()) { db_printf("__mp_release_all(%p): lock not held - %p != %p\n", mpl, mpl->mpl_cpu, curcpu()); - Debugger(); + db_enter(); } #endif @@ -181,7 +181,7 @@ __mp_release_all_but_one(struct __mp_lock *mpl) if (mpl->mpl_cpu != curcpu()) { db_printf("__mp_release_all_but_one(%p): lock not held - " "%p != %p\n", mpl, mpl->mpl_cpu, curcpu()); - Debugger(); + db_enter(); } #endif diff --git a/sys/arch/hppa/hppa/locore.S b/sys/arch/hppa/hppa/locore.S index 785da2d1daf..dbd995b2472 100644 --- a/sys/arch/hppa/hppa/locore.S +++ b/sys/arch/hppa/hppa/locore.S @@ -1,4 +1,4 @@ -/* $OpenBSD: locore.S,v 1.195 2016/05/23 20:11:49 deraadt Exp $ */ +/* $OpenBSD: locore.S,v 1.196 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 1998-2004 Michael Shalayeff @@ -257,7 +257,7 @@ $virtual_mode stw t1, R%kernelmapped(t1) #ifdef DDB - .import Debugger, code + .import db_enter, code /* have to call debugger from here, from virtual mode */ ldil L%boothowto, r1 ldw R%boothowto(r1), r1 diff --git a/sys/arch/hppa/hppa/pmap.c b/sys/arch/hppa/hppa/pmap.c index 034d040b9eb..f9a9648aa9f 100644 --- a/sys/arch/hppa/hppa/pmap.c +++ b/sys/arch/hppa/hppa/pmap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pmap.c,v 1.172 2016/10/19 08:28:20 guenther Exp $ */ +/* $OpenBSD: pmap.c,v 1.173 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 1998-2004 Michael Shalayeff @@ -1194,7 +1194,7 @@ pmap_kenter_pa(vaddr_t va, paddr_t pa, vm_prot_t prot) if (pmap_initialized && (pg = PHYS_TO_VM_PAGE(PTE_PAGE(pte)))) { if (pmap_check_alias(pg, va, pte)) - Debugger(); + db_enter(); } } #endif diff --git a/sys/arch/i386/i386/cpu.c b/sys/arch/i386/i386/cpu.c index b454da2b630..c2d0e72d248 100644 --- a/sys/arch/i386/i386/cpu.c +++ b/sys/arch/i386/i386/cpu.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cpu.c,v 1.81 2017/03/28 17:28:35 kettenis Exp $ */ +/* $OpenBSD: cpu.c,v 1.82 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: cpu.c,v 1.1.2.7 2000/06/26 02:04:05 sommerfeld Exp $ */ /*- @@ -575,7 +575,7 @@ cpu_boot_secondary(struct cpu_info *ci) if (!(ci->ci_flags & CPUF_RUNNING)) { printf("%s failed to become ready\n", ci->ci_dev.dv_xname); #ifdef DDB - Debugger(); + db_enter(); #endif } diff --git a/sys/arch/i386/i386/db_interface.c b/sys/arch/i386/i386/db_interface.c index 85a31f3d6a6..07d123ba1c2 100644 --- a/sys/arch/i386/i386/db_interface.c +++ b/sys/arch/i386/i386/db_interface.c @@ -1,4 +1,4 @@ -/* $OpenBSD: db_interface.c,v 1.34 2017/03/03 20:49:47 bluhm Exp $ */ +/* $OpenBSD: db_interface.c,v 1.35 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: db_interface.c,v 1.22 1996/05/03 19:42:00 christos Exp $ */ /* @@ -355,7 +355,7 @@ db_machine_init(void) } void -Debugger(void) +db_enter(void) { __asm__("int $3"); } diff --git a/sys/arch/i386/i386/db_mp.c b/sys/arch/i386/i386/db_mp.c index 036dc30e720..dd7a27b832b 100644 --- a/sys/arch/i386/i386/db_mp.c +++ b/sys/arch/i386/i386/db_mp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: db_mp.c,v 1.9 2017/04/20 14:13:00 visa Exp $ */ +/* $OpenBSD: db_mp.c,v 1.10 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2003, 2004 Andreas Gunnarsson @@ -137,5 +137,5 @@ db_stopcpu(int cpu) void i386_ipi_db(struct cpu_info *ci) { - Debugger(); + db_enter(); } diff --git a/sys/arch/i386/i386/lock_machdep.c b/sys/arch/i386/i386/lock_machdep.c index 4439df8f7a5..74f631f2f49 100644 --- a/sys/arch/i386/i386/lock_machdep.c +++ b/sys/arch/i386/i386/lock_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: lock_machdep.c,v 1.22 2017/04/20 13:20:17 visa Exp $ */ +/* $OpenBSD: lock_machdep.c,v 1.23 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: lock_machdep.c,v 1.1.2.3 2000/05/03 14:40:30 sommerfeld Exp $ */ /*- @@ -78,7 +78,7 @@ __mp_lock_spin(struct __mp_lock *mpl, u_int me) if (--nticks <= 0) { db_printf("__mp_lock(%p): lock spun out", mpl); - Debugger(); + db_enter(); nticks = __mp_lock_spinout; } } @@ -118,7 +118,7 @@ ___mp_unlock(struct __mp_lock *mpl LOCK_FL_VARS) #ifdef MP_LOCKDEBUG if (!__mp_lock_held(mpl)) { db_printf("__mp_unlock(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif diff --git a/sys/arch/i386/i386/machdep.c b/sys/arch/i386/i386/machdep.c index b66741c801e..315807b0405 100644 --- a/sys/arch/i386/i386/machdep.c +++ b/sys/arch/i386/i386/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.599 2017/04/30 13:04:49 mpi Exp $ */ +/* $OpenBSD: machdep.c,v 1.600 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: machdep.c,v 1.214 1996/11/10 03:16:17 thorpej Exp $ */ /*- @@ -3377,7 +3377,7 @@ init386(paddr_t first_avail) db_machine_init(); ddb_init(); if (boothowto & RB_KDB) - Debugger(); + db_enter(); #endif softintr_init(); diff --git a/sys/arch/landisk/dev/power.c b/sys/arch/landisk/dev/power.c index dbce1ee0f10..bb66681bc36 100644 --- a/sys/arch/landisk/dev/power.c +++ b/sys/arch/landisk/dev/power.c @@ -1,4 +1,4 @@ -/* $OpenBSD: power.c,v 1.6 2014/07/11 08:18:30 guenther Exp $ */ +/* $OpenBSD: power.c,v 1.7 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2007 Martin Reindl. @@ -102,7 +102,7 @@ power_intr(void *arg) if (status & BTN_POWER_BIT) { #ifdef DEBUG printf("%s switched\n", sc->sc_dev.dv_xname); - Debugger(); + db_enter(); #endif _reg_write_1(LANDISK_PWRSW_INTCLR, 1); if (allowpowerdown == 1) { diff --git a/sys/arch/landisk/landisk/machdep.c b/sys/arch/landisk/landisk/machdep.c index 36d788c2fba..b4baca5c86a 100644 --- a/sys/arch/landisk/landisk/machdep.c +++ b/sys/arch/landisk/landisk/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.44 2016/10/09 11:25:39 tom Exp $ */ +/* $OpenBSD: machdep.c,v 1.45 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: machdep.c,v 1.1 2006/09/01 21:26:18 uwe Exp $ */ /*- @@ -177,7 +177,7 @@ landisk_startup(int howto, char *_esym) db_machine_init(); ddb_init(); if (boothowto & RB_KDB) { - Debugger(); + db_enter(); } #endif diff --git a/sys/arch/loongson/dev/bonito.c b/sys/arch/loongson/dev/bonito.c index 7ccb4861f4f..0a0a1a42feb 100644 --- a/sys/arch/loongson/dev/bonito.c +++ b/sys/arch/loongson/dev/bonito.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bonito.c,v 1.31 2016/03/06 19:42:27 mpi Exp $ */ +/* $OpenBSD: bonito.c,v 1.32 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: bonito_mainbus.c,v 1.11 2008/04/28 20:23:10 martin Exp $ */ /* $NetBSD: bonito_pci.c,v 1.5 2008/04/28 20:23:28 martin Exp $ */ @@ -714,7 +714,7 @@ bonito_intr_dispatch(uint64_t isr, int startbit, struct trapframe *frame) REGVAL(BONITO_INTISR), REGVAL(BONITO_INTEN), frame->ipl, bonito_imask[frame->ipl]); #ifdef DDB - Debugger(); + db_enter(); #endif #endif } diff --git a/sys/arch/loongson/loongson/generic2e_machdep.c b/sys/arch/loongson/loongson/generic2e_machdep.c index 38df7a262b1..aa16917f7d9 100644 --- a/sys/arch/loongson/loongson/generic2e_machdep.c +++ b/sys/arch/loongson/loongson/generic2e_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: generic2e_machdep.c,v 1.8 2016/08/30 12:15:28 jsg Exp $ */ +/* $OpenBSD: generic2e_machdep.c,v 1.9 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2010 Miodrag Vallat. @@ -308,7 +308,7 @@ generic2e_isa_intr(uint32_t hwpend, struct trapframe *frame) " isaimr %08x\n", ocw1, ocw2, frame->ipl, bonito_imask[frame->ipl], loongson_isaimr); #ifdef DDB - Debugger(); + db_enter(); #endif #endif } diff --git a/sys/arch/loongson/loongson/machdep.c b/sys/arch/loongson/loongson/machdep.c index 4f641a79824..3100d7cf40c 100644 --- a/sys/arch/loongson/loongson/machdep.c +++ b/sys/arch/loongson/loongson/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.76 2017/04/22 15:37:39 visa Exp $ */ +/* $OpenBSD: machdep.c,v 1.77 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2009, 2010, 2014 Miodrag Vallat. @@ -859,7 +859,7 @@ mips_init(uint64_t argc, uint64_t argv, uint64_t envp, uint64_t cv, #ifdef DDB db_machine_init(); if (boothowto & RB_KDB) - Debugger(); + db_enter(); #endif /* diff --git a/sys/arch/luna88k/dev/mb89352.c b/sys/arch/luna88k/dev/mb89352.c index a68d4bc3d02..d0dbe8e1729 100644 --- a/sys/arch/luna88k/dev/mb89352.c +++ b/sys/arch/luna88k/dev/mb89352.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mb89352.c,v 1.21 2017/03/16 18:15:20 miod Exp $ */ +/* $OpenBSD: mb89352.c,v 1.22 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: mb89352.c,v 1.5 2000/03/23 07:01:31 thorpej Exp $ */ /* NecBSD: mb89352.c,v 1.4 1998/03/14 07:31:20 kmatsuda Exp */ @@ -140,7 +140,7 @@ #include #ifndef DDB -#define Debugger() panic("should call debugger here (mb89352.c)") +#define db_enter() panic("should call debugger here (mb89352.c)") #endif /* ! DDB */ #ifdef SPC_DEBUG diff --git a/sys/arch/luna88k/dev/mb89352var.h b/sys/arch/luna88k/dev/mb89352var.h index da2d7c7f654..85fc053c394 100644 --- a/sys/arch/luna88k/dev/mb89352var.h +++ b/sys/arch/luna88k/dev/mb89352var.h @@ -1,4 +1,4 @@ -/* $OpenBSD: mb89352var.h,v 1.5 2014/05/08 22:17:33 miod Exp $ */ +/* $OpenBSD: mb89352var.h,v 1.6 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: mb89352var.h,v 1.6 2003/08/02 12:48:09 tsutsui Exp $ */ /* NecBSD: mb89352var.h,v 1.4 1998/03/14 07:31:22 kmatsuda Exp */ @@ -190,8 +190,8 @@ struct spc_softc { #define SPC_DOBREAK 0x40 extern int spc_debug; /* SPC_SHOWSTART|SPC_SHOWMISC|SPC_SHOWTRACE; */ #define SPC_PRINT(b, s) do {if ((spc_debug & (b)) != 0) printf s;} while (0) -#define SPC_BREAK() do {if ((spc_debug & SPC_DOBREAK) != 0) Debugger();} while (0) -#define SPC_ASSERT(x) do {if (x) {} else {printf("%s at line %d: assertion failed\n", sc->sc_dev.dv_xname, __LINE__); Debugger();}} while (0) +#define SPC_BREAK() do {if ((spc_debug & SPC_DOBREAK) != 0) db_enter();} while (0) +#define SPC_ASSERT(x) do {if (x) {} else {printf("%s at line %d: assertion failed\n", sc->sc_dev.dv_xname, __LINE__); db_enter();}} while (0) #else #define SPC_PRINT(b, s) #define SPC_BREAK() diff --git a/sys/arch/luna88k/dev/siotty.c b/sys/arch/luna88k/dev/siotty.c index 9799db08da5..3fc73b84b7b 100644 --- a/sys/arch/luna88k/dev/siotty.c +++ b/sys/arch/luna88k/dev/siotty.c @@ -1,4 +1,4 @@ -/* $OpenBSD: siotty.c,v 1.17 2017/03/20 19:37:54 miod Exp $ */ +/* $OpenBSD: siotty.c,v 1.18 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: siotty.c,v 1.9 2002/03/17 19:40:43 atatat Exp $ */ /*- @@ -162,7 +162,7 @@ siottyintr(int chan) #if 0 && defined(DDB) /* ?!?! fails to resume ?!?! */ if ((rr & RR_BREAK) && tp->t_dev == cn_tab->cn_dev) { if (db_console) - Debugger(); + db_enter(); return; } #endif diff --git a/sys/arch/luna88k/luna88k/machdep.c b/sys/arch/luna88k/luna88k/machdep.c index 1ebb31de176..1d684f75b27 100644 --- a/sys/arch/luna88k/luna88k/machdep.c +++ b/sys/arch/luna88k/luna88k/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.123 2017/03/19 10:57:29 miod Exp $ */ +/* $OpenBSD: machdep.c,v 1.124 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 1998, 1999, 2000, 2001 Steve Murphree, Jr. * Copyright (c) 1996 Nivas Madhur @@ -248,7 +248,7 @@ consinit() db_machine_init(); ddb_init(); if (boothowto & RB_KDB) - Debugger(); + db_enter(); #endif } @@ -1323,7 +1323,7 @@ luna88k_ipi_handler(struct trapframe *eframe) * If ddb is hoping to us, it's our turn to enter ddb now. */ if (ci->ci_cpuid == ddb_mp_nextcpu) - Debugger(); + db_enter(); #endif } if (ipi & CI_IPI_NOTIFY) { diff --git a/sys/arch/m88k/m88k/db_interface.c b/sys/arch/m88k/m88k/db_interface.c index ea607fd1fa5..72c512d2556 100644 --- a/sys/arch/m88k/m88k/db_interface.c +++ b/sys/arch/m88k/m88k/db_interface.c @@ -1,4 +1,4 @@ -/* $OpenBSD: db_interface.c,v 1.21 2016/03/09 08:58:50 mpi Exp $ */ +/* $OpenBSD: db_interface.c,v 1.22 2017/04/30 16:45:45 mpi Exp $ */ /* * Mach Operating System * Copyright (c) 1993-1991 Carnegie Mellon University @@ -435,7 +435,7 @@ kdbprinttrap(int type) } void -Debugger() +db_enter(void) { asm (ENTRY_ASM); /* entry trap */ /* ends up at ddb_entry_trap below */ diff --git a/sys/arch/m88k/m88k/mplock.c b/sys/arch/m88k/m88k/mplock.c index bdbf9d517e3..91c33ed555c 100644 --- a/sys/arch/m88k/m88k/mplock.c +++ b/sys/arch/m88k/m88k/mplock.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mplock.c,v 1.4 2016/03/19 11:34:22 mpi Exp $ */ +/* $OpenBSD: mplock.c,v 1.5 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2004 Niklas Hallqvist. All rights reserved. @@ -57,7 +57,7 @@ __mp_lock_spin(struct __mp_lock *mpl) if (nticks == 0) { db_printf("__mp_lock(0x%x): lock spun out", mpl); - Debugger(); + db_enter(); } #endif } @@ -109,7 +109,7 @@ __mp_unlock(struct __mp_lock *mpl) #ifdef MP_LOCKDEBUG if (mpl->mpl_cpu != ci) { db_printf("__mp_unlock(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif @@ -132,7 +132,7 @@ __mp_release_all(struct __mp_lock *mpl) #ifdef MP_LOCKDEBUG if (mpl->mpl_cpu != ci) { db_printf("__mp_release_all(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif @@ -156,7 +156,7 @@ __mp_release_all_but_one(struct __mp_lock *mpl) #ifdef MP_LOCKDEBUG if (mpl->mpl_cpu != ci) { db_printf("__mp_release_all_but_one(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif diff --git a/sys/arch/macppc/dev/macintr.c b/sys/arch/macppc/dev/macintr.c index 6054216554d..135221ccfe1 100644 --- a/sys/arch/macppc/dev/macintr.c +++ b/sys/arch/macppc/dev/macintr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: macintr.c,v 1.53 2015/09/08 08:29:35 deraadt Exp $ */ +/* $OpenBSD: macintr.c,v 1.54 2017/04/30 16:45:45 mpi Exp $ */ /*- * Copyright (c) 2008 Dale Rahn @@ -249,7 +249,7 @@ macintr_prog_button (void *arg) { #ifdef DDB if (db_console) - Debugger(); + db_enter(); #else printf("programmer button pressed, debugger not available\n"); #endif diff --git a/sys/arch/macppc/dev/openpic.c b/sys/arch/macppc/dev/openpic.c index 5ea2438fa12..70c4c057f73 100644 --- a/sys/arch/macppc/dev/openpic.c +++ b/sys/arch/macppc/dev/openpic.c @@ -1,4 +1,4 @@ -/* $OpenBSD: openpic.c,v 1.83 2015/09/08 08:29:35 deraadt Exp $ */ +/* $OpenBSD: openpic.c,v 1.84 2017/04/30 16:45:45 mpi Exp $ */ /*- * Copyright (c) 2008 Dale Rahn @@ -748,7 +748,7 @@ void openpic_ipi_ddb(void) { #ifdef DDB - Debugger(); + db_enter(); #endif } #endif /* MULTIPROCESSOR */ diff --git a/sys/arch/macppc/dev/pgs.c b/sys/arch/macppc/dev/pgs.c index fe2fe95017e..62aba5a1cb4 100644 --- a/sys/arch/macppc/dev/pgs.c +++ b/sys/arch/macppc/dev/pgs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pgs.c,v 1.3 2013/07/01 16:53:24 jasper Exp $ */ +/* $OpenBSD: pgs.c,v 1.4 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2010 Jasper Lievisse Adriaanse * @@ -89,7 +89,7 @@ pgs_intr(void *v) { #ifdef DDB if (db_console) - Debugger(); + db_enter(); #else printf("programmer-switch pressed, debugger not available.\n"); #endif diff --git a/sys/arch/macppc/dev/sysbutton.c b/sys/arch/macppc/dev/sysbutton.c index 02c7fb70e98..e982d15d58e 100644 --- a/sys/arch/macppc/dev/sysbutton.c +++ b/sys/arch/macppc/dev/sysbutton.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sysbutton.c,v 1.4 2008/06/13 00:31:09 krw Exp $ */ +/* $OpenBSD: sysbutton.c,v 1.5 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2007 Gordon Willem Klok * @@ -85,7 +85,7 @@ sysbutton_intr(void *v) */ #ifdef DDB if (db_console) - Debugger(); + db_enter(); #endif return 1; diff --git a/sys/arch/macppc/dev/zs.c b/sys/arch/macppc/dev/zs.c index cd431bce357..47c3b8f090f 100644 --- a/sys/arch/macppc/dev/zs.c +++ b/sys/arch/macppc/dev/zs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: zs.c,v 1.26 2016/03/14 23:08:05 krw Exp $ */ +/* $OpenBSD: zs.c,v 1.27 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: zs.c,v 1.17 2001/06/19 13:42:15 wiz Exp $ */ /* @@ -1096,7 +1096,7 @@ zs_abort(struct zs_chanstate *channel) extern int db_active; if (!db_active) - Debugger(); + db_enter(); } #endif } diff --git a/sys/arch/macppc/macppc/machdep.c b/sys/arch/macppc/macppc/machdep.c index 8e22d5cfc93..0b6548f9f4f 100644 --- a/sys/arch/macppc/macppc/machdep.c +++ b/sys/arch/macppc/macppc/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.179 2016/10/09 11:25:40 tom Exp $ */ +/* $OpenBSD: machdep.c,v 1.180 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: machdep.c,v 1.4 1996/10/16 19:33:11 ws Exp $ */ /* @@ -311,7 +311,7 @@ initppc(startkernel, endkernel, args) #ifdef DDB if (boothowto & RB_KDB) - Debugger(); + db_enter(); #endif /* diff --git a/sys/arch/mips64/mips64/ipifuncs.c b/sys/arch/mips64/mips64/ipifuncs.c index f5a04f7b0a5..b27245c7ee0 100644 --- a/sys/arch/mips64/mips64/ipifuncs.c +++ b/sys/arch/mips64/mips64/ipifuncs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ipifuncs.c,v 1.13 2017/02/19 08:35:13 visa Exp $ */ +/* $OpenBSD: ipifuncs.c,v 1.14 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: ipifuncs.c,v 1.40 2008/04/28 20:23:10 martin Exp $ */ /*- @@ -237,6 +237,6 @@ void mips64_ipi_ddb(void) { #ifdef DDB - Debugger(); + db_enter(); #endif } diff --git a/sys/arch/mips64/mips64/lcore_ddb.S b/sys/arch/mips64/mips64/lcore_ddb.S index 738b6e85b18..7c40b938346 100644 --- a/sys/arch/mips64/mips64/lcore_ddb.S +++ b/sys/arch/mips64/mips64/lcore_ddb.S @@ -1,4 +1,4 @@ -/* $OpenBSD: lcore_ddb.S,v 1.13 2012/10/03 11:18:23 miod Exp $ */ +/* $OpenBSD: lcore_ddb.S,v 1.14 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2001-2003 Opsycon AB (www.opsycon.se / www.opsycon.com) @@ -177,11 +177,11 @@ LEAF(kdbpokeb, 0) sw zero, PCB_ONFAULT(t0) END(kdbpokeb) -LEAF(Debugger, 0) +LEAF(db_enter, 0) break BREAK_SOVER_VAL jr ra NOP -END(Debugger) +END(db_enter) LEAF(setjmp, 0) MFC0 v0, COP_0_STATUS_REG diff --git a/sys/arch/mips64/mips64/lock_machdep.c b/sys/arch/mips64/mips64/lock_machdep.c index 61c32b51d59..af0bb3db68b 100644 --- a/sys/arch/mips64/mips64/lock_machdep.c +++ b/sys/arch/mips64/mips64/lock_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: lock_machdep.c,v 1.2 2016/03/19 11:34:22 mpi Exp $ */ +/* $OpenBSD: lock_machdep.c,v 1.3 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2007 Artur Grabowski @@ -58,7 +58,7 @@ __mp_lock_spin(struct __mp_lock *mpl) if (nticks == 0) { db_printf("__mp_lock(%p): lock spun out", mpl); - Debugger(); + db_enter(); } #endif } @@ -106,7 +106,7 @@ __mp_unlock(struct __mp_lock *mpl) #ifdef MP_LOCKDEBUG if (mpl->mpl_cpu != curcpu()) { db_printf("__mp_unlock(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif @@ -129,7 +129,7 @@ __mp_release_all(struct __mp_lock *mpl) #ifdef MP_LOCKDEBUG if (mpl->mpl_cpu != curcpu()) { db_printf("__mp_release_all(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif @@ -149,7 +149,7 @@ __mp_release_all_but_one(struct __mp_lock *mpl) #ifdef MP_LOCKDEBUG if (mpl->mpl_cpu != curcpu()) { db_printf("__mp_release_all_but_one(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif diff --git a/sys/arch/mips64/mips64/mutex.c b/sys/arch/mips64/mips64/mutex.c index b0923d9605f..0cd640cc914 100644 --- a/sys/arch/mips64/mips64/mutex.c +++ b/sys/arch/mips64/mips64/mutex.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mutex.c,v 1.5 2017/04/20 13:57:30 visa Exp $ */ +/* $OpenBSD: mutex.c,v 1.6 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2004 Artur Grabowski @@ -64,7 +64,7 @@ __mtx_enter(struct mutex *mtx) #ifdef MP_LOCKDEBUG if (--nticks == 0) { db_printf("%s(%p): lock spun out", __func__, mtx); - Debugger(); + db_enter(); nticks = __mp_lock_spinout; } #endif diff --git a/sys/arch/octeon/octeon/machdep.c b/sys/arch/octeon/octeon/machdep.c index 925a56df0b8..98db3860c0c 100644 --- a/sys/arch/octeon/octeon/machdep.c +++ b/sys/arch/octeon/octeon/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.87 2017/04/24 13:54:28 visa Exp $ */ +/* $OpenBSD: machdep.c,v 1.88 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2009, 2010 Miodrag Vallat. @@ -513,7 +513,7 @@ mips_init(__register_t a0, __register_t a1, __register_t a2 __unused, #ifdef DDB db_machine_init(); if (boothowto & RB_KDB) - Debugger(); + db_enter(); #endif #ifdef MULTIPROCESSOR diff --git a/sys/arch/powerpc/ddb/db_interface.c b/sys/arch/powerpc/ddb/db_interface.c index 40c60d9d5e6..e00cf2a8b86 100644 --- a/sys/arch/powerpc/ddb/db_interface.c +++ b/sys/arch/powerpc/ddb/db_interface.c @@ -1,4 +1,4 @@ -/* $OpenBSD: db_interface.c,v 1.2 2016/03/06 13:41:34 mpi Exp $ */ +/* $OpenBSD: db_interface.c,v 1.3 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: db_interface.c,v 1.12 2001/07/22 11:29:46 wiz Exp $ */ /* @@ -65,7 +65,7 @@ int db_active = 0; int db_trap_glue(struct trapframe *frame); /* called from locore */ void -Debugger() +db_enter() { ddb_trap(); } @@ -189,7 +189,7 @@ db_enter_ddb(void) void ppc_ipi_db(struct cpu_info *ci) { - Debugger(); + db_enter(); } void diff --git a/sys/arch/powerpc/powerpc/lock_machdep.c b/sys/arch/powerpc/powerpc/lock_machdep.c index c1ab6e6c678..3ee3c258afb 100644 --- a/sys/arch/powerpc/powerpc/lock_machdep.c +++ b/sys/arch/powerpc/powerpc/lock_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: lock_machdep.c,v 1.4 2016/03/19 11:34:22 mpi Exp $ */ +/* $OpenBSD: lock_machdep.c,v 1.5 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2007 Artur Grabowski @@ -56,7 +56,7 @@ __mp_lock_spin(struct __mp_lock *mpl) if (nticks == 0) { db_printf("__mp_lock(%p): lock spun out", mpl); - Debugger(); + db_enter(); } #endif } @@ -104,7 +104,7 @@ __mp_unlock(struct __mp_lock *mpl) #ifdef MP_LOCKDEBUG if (mpl->mpl_cpu != curcpu()) { db_printf("__mp_unlock(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif @@ -126,7 +126,7 @@ __mp_release_all(struct __mp_lock *mpl) #ifdef MP_LOCKDEBUG if (mpl->mpl_cpu != curcpu()) { db_printf("__mp_release_all(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif @@ -147,7 +147,7 @@ __mp_release_all_but_one(struct __mp_lock *mpl) #ifdef MP_LOCKDEBUG if (mpl->mpl_cpu != curcpu()) { db_printf("__mp_release_all_but_one(%p): not held lock\n", mpl); - Debugger(); + db_enter(); } #endif diff --git a/sys/arch/powerpc/powerpc/mutex.c b/sys/arch/powerpc/powerpc/mutex.c index 699fad5a6ad..7559371675b 100644 --- a/sys/arch/powerpc/powerpc/mutex.c +++ b/sys/arch/powerpc/powerpc/mutex.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mutex.c,v 1.4 2017/04/20 13:57:30 visa Exp $ */ +/* $OpenBSD: mutex.c,v 1.5 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2004 Artur Grabowski @@ -66,7 +66,7 @@ __mtx_enter(struct mutex *mtx) #if defined(MP_LOCKDEBUG) if (--nticks == 0) { db_printf("%s: %p lock spun out", __func__, mtx); - Debugger(); + db_enter(); } #endif } diff --git a/sys/arch/sgi/hpc/zs.c b/sys/arch/sgi/hpc/zs.c index cc52bb13a0f..624bbdfd5b7 100644 --- a/sys/arch/sgi/hpc/zs.c +++ b/sys/arch/sgi/hpc/zs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: zs.c,v 1.14 2017/04/30 13:04:49 mpi Exp $ */ +/* $OpenBSD: zs.c,v 1.15 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: zs.c,v 1.37 2011/02/20 07:59:50 matt Exp $ */ /*- @@ -559,7 +559,7 @@ void zs_abort(struct zs_chanstate *cs) { #if defined(DDB) - Debugger(); + db_enter(); #endif } diff --git a/sys/arch/sgi/sgi/machdep.c b/sys/arch/sgi/sgi/machdep.c index 2ba1d876f06..db43e7bbf15 100644 --- a/sys/arch/sgi/sgi/machdep.c +++ b/sys/arch/sgi/sgi/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.155 2017/04/02 15:48:19 visa Exp $ */ +/* $OpenBSD: machdep.c,v 1.156 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2003-2004 Opsycon AB (www.opsycon.se / www.opsycon.com) @@ -653,7 +653,7 @@ mips_init(int argc, void *argv, caddr_t boot_esym) #ifdef DDB db_machine_init(); if (boothowto & RB_KDB) - Debugger(); + db_enter(); #endif /* diff --git a/sys/arch/sh/dev/scif.c b/sys/arch/sh/dev/scif.c index 0e29647480f..9a74057433e 100644 --- a/sys/arch/sh/dev/scif.c +++ b/sys/arch/sh/dev/scif.c @@ -1,4 +1,4 @@ -/* $OpenBSD: scif.c,v 1.16 2016/03/05 17:16:33 tobiasu Exp $ */ +/* $OpenBSD: scif.c,v 1.17 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: scif.c,v 1.47 2006/07/23 22:06:06 ad Exp $ */ /*- @@ -1133,7 +1133,7 @@ scifintr(void *arg) #ifdef DDB if (ISSET(sc->sc_hwflags, SCIF_HW_CONSOLE) && db_console != 0) { - Debugger(); + db_enter(); } #endif /* DDB */ } diff --git a/sys/arch/sh/sh/db_interface.c b/sys/arch/sh/sh/db_interface.c index 6c0de3baf2e..ca60506f1a8 100644 --- a/sys/arch/sh/sh/db_interface.c +++ b/sys/arch/sh/sh/db_interface.c @@ -1,4 +1,4 @@ -/* $OpenBSD: db_interface.c,v 1.9 2017/01/21 05:42:03 guenther Exp $ */ +/* $OpenBSD: db_interface.c,v 1.10 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: db_interface.c,v 1.37 2006/09/06 00:11:49 uwe Exp $ */ /*- @@ -147,7 +147,7 @@ db_ktrap(int type, int code, db_regs_t *regs) } void -Debugger(void) +db_enter(void) { __asm volatile("trapa %0" :: "i"(_SH_TRA_BREAK)); } diff --git a/sys/arch/socppc/socppc/machdep.c b/sys/arch/socppc/socppc/machdep.c index ee60550efa9..0e149caebd3 100644 --- a/sys/arch/socppc/socppc/machdep.c +++ b/sys/arch/socppc/socppc/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.71 2016/10/09 11:25:40 tom Exp $ */ +/* $OpenBSD: machdep.c,v 1.72 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: machdep.c,v 1.4 1996/10/16 19:33:11 ws Exp $ */ /* @@ -355,7 +355,7 @@ initppc(u_int startkernel, u_int endkernel, char *args) #ifdef DDB if (boothowto & RB_KDB) - Debugger(); + db_enter(); #endif if (boothowto & RB_CONFIG) { diff --git a/sys/arch/sparc64/dev/consinit.c b/sys/arch/sparc64/dev/consinit.c index 89d7c6878dc..5fcb870620f 100644 --- a/sys/arch/sparc64/dev/consinit.c +++ b/sys/arch/sparc64/dev/consinit.c @@ -1,4 +1,4 @@ -/* $OpenBSD: consinit.c,v 1.15 2016/03/07 13:21:51 naddy Exp $ */ +/* $OpenBSD: consinit.c,v 1.16 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: consinit.c,v 1.9 2000/10/20 05:32:35 mrg Exp $ */ /*- @@ -111,7 +111,7 @@ prom_cngetc(dev_t dev) #ifdef DDB if (ch == '+') { if (nplus++ > 3) - Debugger(); + db_enter(); } else nplus = 0; #endif diff --git a/sys/arch/sparc64/dev/fd.c b/sys/arch/sparc64/dev/fd.c index f79ec2a59e5..8c48b4ee12d 100644 --- a/sys/arch/sparc64/dev/fd.c +++ b/sys/arch/sparc64/dev/fd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: fd.c,v 1.46 2016/06/07 06:37:33 dlg Exp $ */ +/* $OpenBSD: fd.c,v 1.47 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: fd.c,v 1.112 2003/08/07 16:29:35 agc Exp $ */ /*- @@ -1459,7 +1459,7 @@ loop: printf("fdcintr: block %lld != blkno %lld\n", (long long)block, (long long)fd->sc_blkno); #if defined(FD_DEBUG) && defined(DDB) - Debugger(); + db_enter(); #endif } } diff --git a/sys/arch/sparc64/dev/iommu.c b/sys/arch/sparc64/dev/iommu.c index 66316b1844c..b2f02f8f541 100644 --- a/sys/arch/sparc64/dev/iommu.c +++ b/sys/arch/sparc64/dev/iommu.c @@ -1,4 +1,4 @@ -/* $OpenBSD: iommu.c,v 1.73 2016/05/04 18:26:12 kettenis Exp $ */ +/* $OpenBSD: iommu.c,v 1.74 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: iommu.c,v 1.47 2002/02/08 20:03:45 eeh Exp $ */ /* @@ -774,7 +774,7 @@ iommu_dvmamap_load(bus_dma_tag_t t, bus_dma_tag_t t0, bus_dmamap_t map, (int)sgsize, flags); #ifdef DDB if (iommudebug & IDB_BREAK) - Debugger(); + db_enter(); #endif } #endif @@ -843,7 +843,7 @@ iommu_dvmamap_load(bus_dma_tag_t t, bus_dma_tag_t t0, bus_dmamap_t map, iommu_dvmamap_print_map(t, is, map); #ifdef DDB if (iommudebug & IDB_BREAK) - Debugger(); + db_enter(); #endif } #endif @@ -993,7 +993,7 @@ iommu_dvmamap_load_raw(bus_dma_tag_t t, bus_dma_tag_t t0, bus_dmamap_t map, "failed!\n", (int)sgsize, flags); #ifdef DDB if (iommudebug & IDB_BREAK) - Debugger(); + db_enter(); #else panic(""); #endif @@ -1062,7 +1062,7 @@ iommu_dvmamap_load_raw(bus_dma_tag_t t, bus_dma_tag_t t0, bus_dmamap_t map, iommu_dvmamap_print_map(t, is, map); #ifdef DDB if (iommudebug & IDB_BREAK) - Debugger(); + db_enter(); #endif } #endif @@ -1320,7 +1320,7 @@ iommu_dvmamap_unload(bus_dma_tag_t t, bus_dma_tag_t t0, bus_dmamap_t map) printf("iommu_dvmamap_unload: No dvmastart\n"); #ifdef DDB if (iommudebug & IDB_BREAK) - Debugger(); + db_enter(); #endif return; } @@ -1409,7 +1409,7 @@ iommu_dvmamap_validate_map(bus_dma_tag_t t, struct iommu_state *is, iommu_dvmamap_print_map(t, is, map); #if defined(DDB) && defined(DEBUG) if (iommudebug & IDB_BREAK) - Debugger(); + db_enter(); #endif } diff --git a/sys/arch/sparc64/dev/pcons.c b/sys/arch/sparc64/dev/pcons.c index b447fc33d2d..a195e9cd5bc 100644 --- a/sys/arch/sparc64/dev/pcons.c +++ b/sys/arch/sparc64/dev/pcons.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pcons.c,v 1.21 2016/03/07 13:21:51 naddy Exp $ */ +/* $OpenBSD: pcons.c,v 1.22 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: pcons.c,v 1.7 2001/05/02 10:32:20 scw Exp $ */ /*- @@ -93,7 +93,7 @@ typedef struct cnm_state { } cnm_state_t; #ifdef DDB #include -#define cn_trap() do { if (db_console) Debugger(); } while (0) +#define cn_trap() do { if (db_console) db_enter(); } while (0) #else #define cn_trap() #endif diff --git a/sys/arch/sparc64/dev/sab.c b/sys/arch/sparc64/dev/sab.c index 000003495ec..feb9de16f45 100644 --- a/sys/arch/sparc64/dev/sab.c +++ b/sys/arch/sparc64/dev/sab.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sab.c,v 1.31 2013/05/30 16:15:01 deraadt Exp $ */ +/* $OpenBSD: sab.c,v 1.32 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2001 Jason L. Wright (jason@thought.net) @@ -1398,7 +1398,7 @@ sabtty_abort(sc) if (db_console == 0) return; if (db_active == 0) - Debugger(); + db_enter(); else callrom(); #else diff --git a/sys/arch/sparc64/dev/sbbc.c b/sys/arch/sparc64/dev/sbbc.c index c2a9c4f4535..eb4b2bd8444 100644 --- a/sys/arch/sparc64/dev/sbbc.c +++ b/sys/arch/sparc64/dev/sbbc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sbbc.c,v 1.11 2012/10/20 12:00:33 miod Exp $ */ +/* $OpenBSD: sbbc.c,v 1.12 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2008 Mark Kettenis * @@ -424,7 +424,7 @@ sbbc_intr_cons(struct sbbc_softc *sc, uint32_t reason) #ifdef DDB if ((reason & SBBC_SRAM_CONS_BRK) && sc == sbbc_cons_input) { if (db_console) - Debugger(); + db_enter(); } #endif diff --git a/sys/arch/sparc64/dev/vcons.c b/sys/arch/sparc64/dev/vcons.c index da5465685f5..213a134cc1c 100644 --- a/sys/arch/sparc64/dev/vcons.c +++ b/sys/arch/sparc64/dev/vcons.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vcons.c,v 1.14 2014/05/10 11:49:31 kettenis Exp $ */ +/* $OpenBSD: vcons.c,v 1.15 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2008 Mark Kettenis * @@ -140,7 +140,7 @@ vcons_cnlookc(dev_t dev, int *cp) if (hv_cons_getchar(&ch) == H_EOK) { #ifdef DDB if (ch == -1 && db_console) - Debugger(); + db_enter(); #endif *cp = ch; return (1); diff --git a/sys/arch/sparc64/dev/viommu.c b/sys/arch/sparc64/dev/viommu.c index 77362d76eeb..4ded11671eb 100644 --- a/sys/arch/sparc64/dev/viommu.c +++ b/sys/arch/sparc64/dev/viommu.c @@ -1,4 +1,4 @@ -/* $OpenBSD: viommu.c,v 1.17 2016/05/04 18:26:12 kettenis Exp $ */ +/* $OpenBSD: viommu.c,v 1.18 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: iommu.c,v 1.47 2002/02/08 20:03:45 eeh Exp $ */ /* @@ -384,7 +384,7 @@ viommu_dvmamap_load(bus_dma_tag_t t, bus_dma_tag_t t0, bus_dmamap_t map, (int)sgsize, flags); #ifdef DDB if (iommudebug & IDB_BREAK) - Debugger(); + db_enter(); #endif } #endif @@ -579,7 +579,7 @@ viommu_dvmamap_load_raw(bus_dma_tag_t t, bus_dma_tag_t t0, bus_dmamap_t map, "failed!\n", (int)sgsize, flags); #ifdef DDB if (iommudebug & IDB_BREAK) - Debugger(); + db_enter(); #else panic(""); #endif diff --git a/sys/arch/sparc64/dev/zs.c b/sys/arch/sparc64/dev/zs.c index 5c2668a09b8..8b105b7276b 100644 --- a/sys/arch/sparc64/dev/zs.c +++ b/sys/arch/sparc64/dev/zs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: zs.c,v 1.28 2017/04/30 13:04:49 mpi Exp $ */ +/* $OpenBSD: zs.c,v 1.29 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: zs.c,v 1.29 2001/05/30 15:24:24 lukem Exp $ */ /*- @@ -670,8 +670,6 @@ zs_write_data(cs, val) * XXX - I think I like the mvme167 code better. -gwr ****************************************************************/ -extern void Debugger(void); - /* * Handle user request to enter kernel debugger. */ @@ -694,7 +692,7 @@ zs_abort(cs) extern int db_active; if (!db_active) - Debugger(); + db_enter(); else /* Debugger is probably hozed */ callrom(); diff --git a/sys/arch/sparc64/sparc64/autoconf.c b/sys/arch/sparc64/sparc64/autoconf.c index a4bc40bcad2..1a9f711f535 100644 --- a/sys/arch/sparc64/sparc64/autoconf.c +++ b/sys/arch/sparc64/sparc64/autoconf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: autoconf.c,v 1.127 2016/10/18 00:43:57 guenther Exp $ */ +/* $OpenBSD: autoconf.c,v 1.128 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: autoconf.c,v 1.51 2001/07/24 19:32:11 eeh Exp $ */ /* @@ -582,7 +582,7 @@ bootpath_build(void) /* specialties */ if (*cp == 'd') { #if defined(DDB) - Debugger(); + db_enter(); #else printf("kernel has no debugger\n"); #endif diff --git a/sys/arch/sparc64/sparc64/clock.c b/sys/arch/sparc64/sparc64/clock.c index e33aa021f2f..3b053f96023 100644 --- a/sys/arch/sparc64/sparc64/clock.c +++ b/sys/arch/sparc64/sparc64/clock.c @@ -1,4 +1,4 @@ -/* $OpenBSD: clock.c,v 1.58 2016/03/07 13:21:51 naddy Exp $ */ +/* $OpenBSD: clock.c,v 1.59 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: clock.c,v 1.41 2001/07/24 19:29:25 eeh Exp $ */ /* @@ -740,7 +740,7 @@ clockintr(cap) "tick_base %llx\n", (long long)t, (long long)clk, (long long)tk, (long long)tick_base); #ifdef DDB - Debugger(); + db_enter(); #endif tick_base = 0; } diff --git a/sys/arch/sparc64/sparc64/db_interface.c b/sys/arch/sparc64/sparc64/db_interface.c index eb84bb99838..f578bd1a554 100644 --- a/sys/arch/sparc64/sparc64/db_interface.c +++ b/sys/arch/sparc64/sparc64/db_interface.c @@ -1,4 +1,4 @@ -/* $OpenBSD: db_interface.c,v 1.47 2016/11/07 00:26:33 guenther Exp $ */ +/* $OpenBSD: db_interface.c,v 1.48 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: db_interface.c,v 1.61 2001/07/31 06:55:47 eeh Exp $ */ /* @@ -573,7 +573,7 @@ db_write_bytes(addr, size, data) } void -Debugger(void) +db_enter(void) { /* We use the breakpoint to trap into DDB */ asm("ta 1; nop"); diff --git a/sys/arch/sparc64/sparc64/intr.c b/sys/arch/sparc64/sparc64/intr.c index 2947715d45b..f82f6427c28 100644 --- a/sys/arch/sparc64/sparc64/intr.c +++ b/sys/arch/sparc64/sparc64/intr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: intr.c,v 1.55 2016/06/13 01:08:13 dlg Exp $ */ +/* $OpenBSD: intr.c,v 1.56 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: intr.c,v 1.39 2001/07/19 23:38:11 eeh Exp $ */ /* @@ -109,7 +109,7 @@ strayintr(const struct trapframe64 *fp, int vectored) nstray = 1; } #ifdef DDB - Debugger(); + db_enter(); #endif } @@ -213,7 +213,7 @@ intr_establish(int level, struct intrhand *ih) if (!ih->ih_number) { printf("\nintr_establish: NULL vector fun %p arg %p pil %p", ih->ih_fun, ih->ih_arg, ih->ih_number, ih->ih_pil); - Debugger(); + db_enter(); } #endif diff --git a/sys/arch/sparc64/sparc64/lock_machdep.c b/sys/arch/sparc64/sparc64/lock_machdep.c index 0cb1d16b66e..38de1567201 100644 --- a/sys/arch/sparc64/sparc64/lock_machdep.c +++ b/sys/arch/sparc64/sparc64/lock_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: lock_machdep.c,v 1.13 2017/04/04 12:30:04 visa Exp $ */ +/* $OpenBSD: lock_machdep.c,v 1.14 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2007 Artur Grabowski @@ -100,7 +100,7 @@ __mp_lock_spin(struct __mp_lock *mpl, u_int me) if (--nticks <= 0) { db_printf("__mp_lock(%p): lock spun out", mpl); - Debugger(); + db_enter(); nticks = __mp_lock_spinout; } } diff --git a/sys/arch/sparc64/sparc64/locore.s b/sys/arch/sparc64/sparc64/locore.s index 3ae0dadbb1b..c0779d31cf7 100644 --- a/sys/arch/sparc64/sparc64/locore.s +++ b/sys/arch/sparc64/sparc64/locore.s @@ -1,4 +1,4 @@ -/* $OpenBSD: locore.s,v 1.184 2016/10/18 00:43:57 guenther Exp $ */ +/* $OpenBSD: locore.s,v 1.185 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: locore.s,v 1.137 2001/08/13 06:10:10 jdolecek Exp $ */ /* @@ -83,7 +83,7 @@ #undef FPPROC /* Let us use same syntax as C code */ -#define Debugger() ta 1; nop +#define db_enter() ta 1; nop /* use as needed to align things on longword boundaries */ #define _ALIGN .align 8 @@ -2882,7 +2882,7 @@ sun4v_tl1_ptbl_miss: be,pn %icc, ufill_trap nop - Debugger() + db_enter() NOTREACHED flush_others: @@ -3274,7 +3274,7 @@ pcbspill: NOTREACHED pcbspill_fail: - Debugger() + db_enter() NOTREACHED @@ -3858,7 +3858,7 @@ interrupt_vector: jmpl %g2, %g0 nop - Debugger() + db_enter() NOTREACHED #else bgeu,pn %xcc, 3f diff --git a/sys/arch/sparc64/sparc64/pmap.c b/sys/arch/sparc64/sparc64/pmap.c index c8954c3ecfc..2ff45660e03 100644 --- a/sys/arch/sparc64/sparc64/pmap.c +++ b/sys/arch/sparc64/sparc64/pmap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pmap.c,v 1.98 2016/09/15 02:00:17 dlg Exp $ */ +/* $OpenBSD: pmap.c,v 1.99 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: pmap.c,v 1.107 2001/08/31 16:47:41 eeh Exp $ */ #undef NO_VCACHE /* Don't forget the locked TLB in dostart */ /* @@ -58,9 +58,9 @@ #include #include #include -#define Debugger() __asm volatile("ta 1; nop"); +#define db_enter() __asm volatile("ta 1; nop"); #else -#define Debugger() +#define db_enter() #define db_printf printf #endif @@ -1526,7 +1526,7 @@ pmap_release(struct pmap *pm) if (pv != NULL) { printf("pmap_release: pm=%p page %llx still in use\n", pm, (unsigned long long)(((u_int64_t)i<pm_stats.resident_count); @@ -2017,7 +2017,7 @@ pmap_protect(struct pmap *pm, vaddr_t sva, vaddr_t eva, vm_prot_t prot) KDASSERT((data & TLB_NFO) == 0); if (pseg_set(pm, sva, data, 0)) { printf("pmap_protect: gotten pseg empty!\n"); - Debugger(); + db_enter(); /* panic? */ } @@ -2274,7 +2274,7 @@ pmap_clear_modify(struct vm_page *pg) KDASSERT((data & TLB_NFO) == 0); if (pseg_set(pv->pv_pmap, pv->pv_va & PV_VAMASK, data, 0)) { printf("pmap_clear_modify: gotten pseg empty!\n"); - Debugger(); + db_enter(); /* panic? */ } if (pv->pv_pmap->pm_ctx || pv->pv_pmap == pmap_kernel()) { @@ -2325,7 +2325,7 @@ pmap_clear_reference(struct vm_page *pg) KDASSERT((data & TLB_NFO) == 0); if (pseg_set(pv->pv_pmap, pv->pv_va & PV_VAMASK, data, 0)) { printf("pmap_clear_reference: gotten pseg empty!\n"); - Debugger(); + db_enter(); /* panic? */ } if (pv->pv_pmap->pm_ctx || pv->pv_pmap == pmap_kernel()) { @@ -2446,7 +2446,7 @@ pmap_unwire(struct pmap *pmap, vaddr_t va) if (pseg_set(pmap, va & PV_VAMASK, data, 0)) { printf("pmap_unwire: gotten pseg empty!\n"); - Debugger(); + db_enter(); /* panic? */ } mtx_leave(&pmap->pm_mtx); @@ -2501,7 +2501,7 @@ pmap_page_protect(struct vm_page *pg, vm_prot_t prot) KDASSERT((data & TLB_NFO) == 0); if (pseg_set(pv->pv_pmap, pv->pv_va & PV_VAMASK, data, 0)) { printf("pmap_page_protect: gotten pseg empty!\n"); - Debugger(); + db_enter(); /* panic? */ } if (pv->pv_pmap->pm_ctx || pv->pv_pmap == pmap_kernel()) { @@ -2529,7 +2529,7 @@ pmap_page_protect(struct vm_page *pg, vm_prot_t prot) /* Clear mapping */ if (pseg_set(pv->pv_pmap, pv->pv_va & PV_VAMASK, 0, 0)) { printf("pmap_page_protect: gotten pseg empty!\n"); - Debugger(); + db_enter(); /* panic? */ } if (pv->pv_pmap->pm_ctx || pv->pv_pmap == pmap_kernel()) { @@ -2556,7 +2556,7 @@ pmap_page_protect(struct vm_page *pg, vm_prot_t prot) pv->pv_va |= pmap_tte2flags(data); if (pseg_set(pv->pv_pmap, pv->pv_va & PV_VAMASK, 0, 0)) { printf("pmap_page_protect: gotten pseg empty!\n"); - Debugger(); + db_enter(); /* panic? */ } if (pv->pv_pmap->pm_ctx || pv->pv_pmap == pmap_kernel()) { @@ -2647,7 +2647,7 @@ ctx_free(struct pmap *pm) "ctxbusy[%d] = %p, pm(%p)->pm_ctx = %p\n", oldctx, (void *)(u_long)ctxbusy[oldctx], pm, (void *)(u_long)pm->pm_physaddr); - Debugger(); + db_enter(); } #endif /* We should verify it has not been stolen and reallocated... */ @@ -2820,7 +2820,7 @@ pmap_page_cache(struct pmap *pm, paddr_t pa, int mode) pseg_get(pv->pv_pmap, va) & ~(SUN4U_TLB_CV|SUN4U_TLB_CP), 0)) { printf("pmap_page_cache: aliased pseg empty!\n"); - Debugger(); + db_enter(); /* panic? */ } } else if (mode && (!(pv->pv_va & PV_NVC))) { @@ -2828,7 +2828,7 @@ pmap_page_cache(struct pmap *pm, paddr_t pa, int mode) if (pseg_set(pv->pv_pmap, va, pseg_get(pv->pv_pmap, va) | SUN4U_TLB_CV, 0)) { printf("pmap_page_cache: aliased pseg empty!\n"); - Debugger(); + db_enter(); /* panic? */ } } else { @@ -2836,7 +2836,7 @@ pmap_page_cache(struct pmap *pm, paddr_t pa, int mode) if (pseg_set(pv->pv_pmap, va, pseg_get(pv->pv_pmap, va) & ~SUN4U_TLB_CV, 0)) { printf("pmap_page_cache: aliased pseg empty!\n"); - Debugger(); + db_enter(); /* panic? */ } } diff --git a/sys/arch/sparc64/sparc64/vm_machdep.c b/sys/arch/sparc64/sparc64/vm_machdep.c index 18e012ed879..ac3f4514e83 100644 --- a/sys/arch/sparc64/sparc64/vm_machdep.c +++ b/sys/arch/sparc64/sparc64/vm_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vm_machdep.c,v 1.36 2017/02/12 04:55:08 guenther Exp $ */ +/* $OpenBSD: vm_machdep.c,v 1.37 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: vm_machdep.c,v 1.38 2001/06/30 00:02:20 eeh Exp $ */ /* @@ -264,7 +264,7 @@ cpu_fork(struct proc *p1, struct proc *p2, void *stack, void *tcb, printf("cpu_fork: tstate=%lx pc=%lx npc=%lx rsp=%lx\n", (long)tf2->tf_tstate, (long)tf2->tf_pc, (long)tf2->tf_npc, (long)(tf2->tf_out[6])); - Debugger(); + db_enter(); #endif } diff --git a/sys/ddb/db_usrreq.c b/sys/ddb/db_usrreq.c index 40e736d67f4..678680cafe0 100644 --- a/sys/ddb/db_usrreq.c +++ b/sys/ddb/db_usrreq.c @@ -1,4 +1,4 @@ -/* $OpenBSD: db_usrreq.c,v 1.18 2016/09/04 09:22:29 mpi Exp $ */ +/* $OpenBSD: db_usrreq.c,v 1.19 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 1996 Michael Shalayeff. All rights reserved. @@ -96,7 +96,7 @@ ddb_sysctl(int *name, u_int namelen, void *oldp, size_t *oldlenp, void *newp, if (securelevel < 1 || (pr->ps_flags & PS_CONTROLT && cn_tab && cn_tab->cn_dev == pr->ps_session->s_ttyp->t_dev)) { - Debugger(); + db_enter(); newp = NULL; } else return (ENODEV); diff --git a/sys/dev/ic/aic6250.c b/sys/dev/ic/aic6250.c index 67a2bd02e48..d438d82ee3a 100644 --- a/sys/dev/ic/aic6250.c +++ b/sys/dev/ic/aic6250.c @@ -1,4 +1,4 @@ -/* $OpenBSD: aic6250.c,v 1.2 2013/10/23 10:07:14 miod Exp $ */ +/* $OpenBSD: aic6250.c,v 1.3 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2010, 2013 Miodrag Vallat. @@ -126,7 +126,7 @@ #include #ifndef DDB -#define Debugger() panic("should call debugger here (aic6250.c)") +#define db_enter() panic("should call debugger here (aic6250.c)") #endif /* ! DDB */ #ifdef AIC_DEBUG diff --git a/sys/dev/ic/aic6250var.h b/sys/dev/ic/aic6250var.h index f5e49a24015..73259cf434b 100644 --- a/sys/dev/ic/aic6250var.h +++ b/sys/dev/ic/aic6250var.h @@ -1,4 +1,4 @@ -/* $OpenBSD: aic6250var.h,v 1.2 2013/10/23 10:07:14 miod Exp $ */ +/* $OpenBSD: aic6250var.h,v 1.3 2017/04/30 16:45:45 mpi Exp $ */ /* * Copyright (c) 2010, 2013 Miodrag Vallat. @@ -206,13 +206,13 @@ struct aic6250_softc { #define AIC_DOBREAK 0x40 #define AIC_PRINT(b, s) do {if ((aic6250_debug & (b)) != 0) printf s;} while (0) #define AIC_BREAK() \ - do { if ((aic6250_debug & AIC_DOBREAK) != 0) Debugger(); } while (0) + do { if ((aic6250_debug & AIC_DOBREAK) != 0) db_enter(); } while (0) #define AIC_ASSERT(x) \ do { \ if (!(x)) { \ printf("%s at line %d: assertion failed\n", \ sc->sc_dev.dv_xname, __LINE__); \ - Debugger(); \ + db_enter(); \ } \ } while (0) #else diff --git a/sys/dev/ic/aic6360.c b/sys/dev/ic/aic6360.c index 531b187056d..3520ea837e0 100644 --- a/sys/dev/ic/aic6360.c +++ b/sys/dev/ic/aic6360.c @@ -1,4 +1,4 @@ -/* $OpenBSD: aic6360.c,v 1.27 2014/09/14 14:17:24 jsg Exp $ */ +/* $OpenBSD: aic6360.c,v 1.28 2017/04/30 16:45:46 mpi Exp $ */ /* $NetBSD: aic6360.c,v 1.52 1996/12/10 21:27:51 thorpej Exp $ */ #ifdef DDB @@ -145,7 +145,7 @@ #include #ifndef DDB -#define Debugger() panic("should call debugger here (aic6360.c)") +#define db_enter() panic("should call debugger here (aic6360.c)") #endif /* ! DDB */ #ifdef AIC_DEBUG diff --git a/sys/dev/ic/aic6360var.h b/sys/dev/ic/aic6360var.h index d0c4dceb0fe..1f7a033bc2e 100644 --- a/sys/dev/ic/aic6360var.h +++ b/sys/dev/ic/aic6360var.h @@ -1,4 +1,4 @@ -/* $OpenBSD: aic6360var.h,v 1.8 2011/04/06 18:14:35 miod Exp $ */ +/* $OpenBSD: aic6360var.h,v 1.9 2017/04/30 16:45:45 mpi Exp $ */ /* $NetBSD: aic6360.c,v 1.52 1996/12/10 21:27:51 thorpej Exp $ */ /* @@ -194,13 +194,13 @@ struct aic_softc { #define AIC_DOBREAK 0x40 #define AIC_PRINT(b, s) do {if ((aic_debug & (b)) != 0) printf s;} while (0) #define AIC_BREAK() \ - do { if ((aic_debug & AIC_DOBREAK) != 0) Debugger(); } while (0) + do { if ((aic_debug & AIC_DOBREAK) != 0) db_enter(); } while (0) #define AIC_ASSERT(x) \ do { \ if (!(x)) { \ printf("%s at line %d: assertion failed\n", \ sc->sc_dev.dv_xname, __LINE__); \ - Debugger(); \ + db_enter(); \ } \ } while (0) #else diff --git a/sys/dev/ic/com.c b/sys/dev/ic/com.c index 6fa8fe9a925..ba3dfce322a 100644 --- a/sys/dev/ic/com.c +++ b/sys/dev/ic/com.c @@ -1,4 +1,4 @@ -/* $OpenBSD: com.c,v 1.162 2017/04/30 13:04:49 mpi Exp $ */ +/* $OpenBSD: com.c,v 1.163 2017/04/30 16:45:46 mpi Exp $ */ /* $NetBSD: com.c,v 1.82.4.1 1996/06/02 09:08:00 mrg Exp $ */ /* @@ -1088,7 +1088,7 @@ comintr(void *arg) if (ISSET(sc->sc_hwflags, COM_HW_CONSOLE)) { if (db_console) - Debugger(); + db_enter(); goto next; } #endif diff --git a/sys/dev/ic/ncr5380sbc.c b/sys/dev/ic/ncr5380sbc.c index 525f22fe552..ce030d61692 100644 --- a/sys/dev/ic/ncr5380sbc.c +++ b/sys/dev/ic/ncr5380sbc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ncr5380sbc.c,v 1.32 2015/01/15 17:54:14 miod Exp $ */ +/* $OpenBSD: ncr5380sbc.c,v 1.33 2017/04/30 16:45:46 mpi Exp $ */ /* $NetBSD: ncr5380sbc.c,v 1.13 1996/10/13 01:37:25 christos Exp $ */ /* @@ -122,7 +122,7 @@ void ncr5380_cmd_timeout(void *); #ifndef DDB /* This is used only in recoverable places. */ -#define Debugger() printf("Debug: ncr5380.c:%d\n", __LINE__) +#define db_enter() printf("Debug: ncr5380.c:%d\n", __LINE__) #endif #ifdef NCR5380_DEBUG @@ -133,7 +133,7 @@ int ncr5380_debug = NCR_DBG_BREAK|NCR_DBG_CMDS; struct ncr5380_softc *ncr5380_debug_sc; #define NCR_BREAK() \ - do { if (ncr5380_debug & NCR_DBG_BREAK) Debugger(); } while (0) + do { if (ncr5380_debug & NCR_DBG_BREAK) db_enter(); } while (0) static void ncr5380_show_scsi_cmd(struct scsi_xfer *); static void ncr5380_show_sense(struct scsi_xfer *); diff --git a/sys/dev/ic/osiop.c b/sys/dev/ic/osiop.c index 5c874e6bc19..07fa9131676 100644 --- a/sys/dev/ic/osiop.c +++ b/sys/dev/ic/osiop.c @@ -1,4 +1,4 @@ -/* $OpenBSD: osiop.c,v 1.50 2014/12/19 07:23:57 deraadt Exp $ */ +/* $OpenBSD: osiop.c,v 1.51 2017/04/30 16:45:46 mpi Exp $ */ /* $NetBSD: osiop.c,v 1.9 2002/04/05 18:27:54 bouyer Exp $ */ /* @@ -596,7 +596,7 @@ osiop_scsidone(acb, status) if (acb == NULL || acb->xs == NULL) { printf("osiop_scsidone: NULL acb %p or scsi_xfer\n", acb); #if defined(OSIOP_DEBUG) && defined(DDB) - Debugger(); + db_enter(); #endif return; } @@ -1126,7 +1126,7 @@ osiop_checkintr(sc, istat, dstat, sstat0, status) scraddr, scraddr + sizeof(osiop_script)); printf(" istat %x dstat %x sstat0 %x\n", istat, dstat, sstat0); #ifdef DDB - Debugger(); + db_enter(); #endif } #endif @@ -1294,7 +1294,7 @@ osiop_checkintr(sc, istat, dstat, sstat0, status) osiop_read_1(sc, OSIOP_SBCL), osiop_read_4(sc, OSIOP_DSP)); #if defined(OSIOP_DEBUG) && defined(DDB) - /*Debugger(); XXX is*/ + /*db_enter(); XXX is*/ #endif } switch (OSIOP_PHASE(osiop_read_1(sc, OSIOP_SBCL))) { @@ -1473,7 +1473,7 @@ osiop_checkintr(sc, istat, dstat, sstat0, status) "curaddr %lx curlen %lx i %d\n", acb->curaddr, acb->curlen, i); #if defined(OSIOP_DEBUG) && defined(DDB) - Debugger(); + db_enter(); #endif } #ifdef OSIOP_DEBUG diff --git a/sys/dev/ic/wd33c93.c b/sys/dev/ic/wd33c93.c index b0f832aa373..0b37f8e8ff8 100644 --- a/sys/dev/ic/wd33c93.c +++ b/sys/dev/ic/wd33c93.c @@ -1,4 +1,4 @@ -/* $OpenBSD: wd33c93.c,v 1.9 2016/12/26 17:38:14 jca Exp $ */ +/* $OpenBSD: wd33c93.c,v 1.10 2017/04/30 16:45:46 mpi Exp $ */ /* $NetBSD: wd33c93.c,v 1.24 2010/11/13 13:52:02 uebayasi Exp $ */ /* @@ -878,7 +878,7 @@ wd33c93_wait(struct wd33c93_softc *sc, u_char until, int timeo, int line) printf("wd33c93_wait: TIMEO @%d with asr=0x%x csr=0x%x\n", line, val, csr); #ifdef DDB - Debugger(); + db_enter(); #endif #endif return(val); /* Maybe I should abort */ @@ -2144,7 +2144,7 @@ wd33c93_nextstate(struct wd33c93_softc *sc, struct wd33c93_acb *acb, u_char csr, sc->sc_dev.dv_xname, asr, csr); #ifdef DDB - Debugger(); + db_enter(); #endif SET_SBIC_control(sc, SBIC_CTL_EDI | SBIC_CTL_IDI); diff --git a/sys/dev/usb/dwc2/dwc2.c b/sys/dev/usb/dwc2/dwc2.c index 7fb32dcb4ca..80832f45a5b 100644 --- a/sys/dev/usb/dwc2/dwc2.c +++ b/sys/dev/usb/dwc2/dwc2.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dwc2.c,v 1.43 2017/03/10 11:18:48 mpi Exp $ */ +/* $OpenBSD: dwc2.c,v 1.44 2017/04/30 16:45:46 mpi Exp $ */ /* $NetBSD: dwc2.c,v 1.32 2014/09/02 23:26:20 macallan Exp $ */ /*- @@ -1361,7 +1361,7 @@ dwc2_worker(struct task *wk, void *priv) struct dwc2_softc *sc = priv; struct dwc2_hsotg *hsotg = sc->sc_hsotg; -/* Debugger(); */ +/* db_enter(); */ #if 0 struct usbd_xfer *xfer = dwork->xfer; struct dwc2_xfer *dxfer = DWC2_XFER2DXFER(xfer); diff --git a/sys/dev/wscons/wskbd.c b/sys/dev/wscons/wskbd.c index 54342e63317..252b782aaf2 100644 --- a/sys/dev/wscons/wskbd.c +++ b/sys/dev/wscons/wskbd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: wskbd.c,v 1.85 2017/03/11 11:55:03 mpi Exp $ */ +/* $OpenBSD: wskbd.c,v 1.86 2017/04/30 16:45:46 mpi Exp $ */ /* $NetBSD: wskbd.c,v 1.80 2005/05/04 01:52:16 augustss Exp $ */ /* @@ -1504,7 +1504,7 @@ internal_command(struct wskbd_softc *sc, u_int *type, keysym_t ksym, #ifdef DDB if (ksym == KS_Cmd_Debugger) { if (sc->sc_isconsole && db_console) - Debugger(); + db_enter(); /* discard this key (ddb discarded command modifiers) */ *type = WSCONS_EVENT_KEY_UP; return (1); @@ -1542,7 +1542,7 @@ internal_command(struct wskbd_softc *sc, u_int *type, keysym_t ksym, #ifdef DDB case 2: if (sc->sc_isconsole && db_console) - Debugger(); + db_enter(); /* discard this key (ddb discarded command modifiers) */ *type = WSCONS_EVENT_KEY_UP; break; diff --git a/sys/kern/subr_prf.c b/sys/kern/subr_prf.c index d131ca5a187..5e538674a24 100644 --- a/sys/kern/subr_prf.c +++ b/sys/kern/subr_prf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: subr_prf.c,v 1.90 2017/04/30 13:04:49 mpi Exp $ */ +/* $OpenBSD: subr_prf.c,v 1.91 2017/04/30 16:45:46 mpi Exp $ */ /* $NetBSD: subr_prf.c,v 1.45 1997/10/24 18:14:25 chuck Exp $ */ /*- @@ -201,7 +201,7 @@ panic(const char *fmt, ...) #ifdef DDB if (db_panic) - Debugger(); + db_enter(); else db_stack_dump(); #endif @@ -229,7 +229,7 @@ splassert_fail(int wantipl, int haveipl, const char *func) case 3: #ifdef DDB db_stack_dump(); - Debugger(); + db_enter(); #endif break; default: diff --git a/sys/kern/subr_userconf.c b/sys/kern/subr_userconf.c index e79d078d8e6..7a1e245e6e9 100644 --- a/sys/kern/subr_userconf.c +++ b/sys/kern/subr_userconf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: subr_userconf.c,v 1.44 2015/09/11 07:13:58 miod Exp $ */ +/* $OpenBSD: subr_userconf.c,v 1.45 2017/04/30 16:45:46 mpi Exp $ */ /* * Copyright (c) 1996-2001 Mats O Jansson @@ -1256,7 +1256,7 @@ userconf_parse(char *cmd) break; #if defined(DDB) case 'D': - Debugger(); + db_enter(); break; #endif case 'd': diff --git a/sys/kern/subr_witness.c b/sys/kern/subr_witness.c index 5129871ff8c..26839f730e9 100644 --- a/sys/kern/subr_witness.c +++ b/sys/kern/subr_witness.c @@ -1,4 +1,4 @@ -/* $OpenBSD: subr_witness.c,v 1.1 2017/04/20 12:59:36 visa Exp $ */ +/* $OpenBSD: subr_witness.c,v 1.2 2017/04/30 16:45:46 mpi Exp $ */ /*- * Copyright (c) 2008 Isilon Systems, Inc. @@ -30,8 +30,8 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * from BSDI $Id: subr_witness.c,v 1.1 2017/04/20 12:59:36 visa Exp $ - * and BSDI $Id: subr_witness.c,v 1.1 2017/04/20 12:59:36 visa Exp $ + * from BSDI $Id: subr_witness.c,v 1.2 2017/04/30 16:45:46 mpi Exp $ + * and BSDI $Id: subr_witness.c,v 1.2 2017/04/30 16:45:46 mpi Exp $ */ /* @@ -2521,5 +2521,5 @@ witness_debugger(int cond, const char *msg) if (!cond) return; - Debugger(); + db_enter(); } diff --git a/sys/sys/systm.h b/sys/sys/systm.h index 4bb3b7ec9ac..8d925d6294a 100644 --- a/sys/sys/systm.h +++ b/sys/sys/systm.h @@ -1,4 +1,4 @@ -/* $OpenBSD: systm.h,v 1.127 2017/04/30 13:04:49 mpi Exp $ */ +/* $OpenBSD: systm.h,v 1.128 2017/04/30 16:45:46 mpi Exp $ */ /* $NetBSD: systm.h,v 1.50 1996/06/09 04:55:09 briggs Exp $ */ /*- @@ -340,7 +340,7 @@ extern int (*mountroot)(void); #if defined(DDB) /* debugger entry points */ -void Debugger(void); /* in DDB only */ +void db_enter(void); /* in DDB only */ #endif #ifdef BOOT_CONFIG