summaryrefslogtreecommitdiff
path: root/sys/ddb
AgeCommit message (Collapse)Author
2017-01-09Revert previous, it's a documented behavior and people might rely on it.Martin Pieuchot
Pointed by deraadt@
2017-01-09Stop and restart the watchdog timer when entering and leaving ddb(4).Martin Pieuchot
From Christian Ludwig.
2016-10-18Add the examine /m format, "display in unsigned hex with characterChristian Weisgerber
dump at the end of each line", which has always been documented but not implemented. Mostly from NetBSD, but I fixed the column alignment code. ok mlarkin@, pirofti@
2016-09-18- inline db_ctf_nsyms() into it's only caller. the value remains cached andJasper Lievisse Adriaanse
won't change, so there's no reason to call it again. - remove explicit return from void function ok mpi@
2016-09-17rename ddb/db_ctf.h to sys/ctf.h which is the expected location for the publicJasper Lievisse Adriaanse
CTF bits. ok kettenis@ mpi@
2016-09-17move the .SUNW_ctf section name definition to exec_elf.h and document it in ↵Jasper Lievisse Adriaanse
elf(5) feedback from guenther@ ok guenther@ kettenis@
2016-09-16teach ddb(4) about CTF. currently it only loads the CTF and uses it on amd64Jasper Lievisse Adriaanse
to lookup the number of function parameters. however having this basic facility allows us to expand it's usage. currently hidden behind the (disabled) DDBCTF kernel option as some of the required tools are not available in base yet. in addition to that one also needs recent bootblocks that load the .SUNW_ctf kernel section. discussed with mpi@ over many a cider and ale in cambridge feedback and ok guenther@ mpi@
2016-09-16drop unneeded casting noiseJasper Lievisse Adriaanse
pointed out by guenther@ in a separate diff
2016-09-04Introduce Dynamic Profiling, a ddb(4) based & gprof compatible kernelMartin Pieuchot
profiling framework. Code patching is used to enable probes when entering functions. The probes will call a mcount()-like function to match the behavior of a GPROF kernel. Currently only available on amd64 and guarded under DDBPROF. Support for other archs will follow soon. A new sysctl knob, ddb.console, need to be set to 1 in securelevel 0 to be able to use this feature. Inputs and ok guenther@
2016-09-03make intrace a volatile, while the compiler does the right thing stillJasper Lievisse Adriaanse
(no change in the generated code), it's more correct and helps the reader. ok deraadt@ guenther@
2016-09-02move links from http to https://www.openbsd.org/Theo Buehler
ok beck
2016-06-07per trending style, add continue to empty loops.Ted Unangst
ok mglocker
2016-05-21<sys/localedef.h> isn't needed for ddb structinfoPhilip Guenther
ok millert@ deraadt@ schwarze@
2016-04-20Collapse db_dwarf.h into db_sym.hMartin Pieuchot
ok matthew@
2016-04-19Do not expose private functions.Martin Pieuchot
2016-04-19Start reducing the dependence on <uvm/uvm_param.h> by using int-1-0Martin Pieuchot
instead of boolean_t-TRUE-FALSE.
2016-04-19Keep db_write_cmd() in the only place where it is used, just like we didMartin Pieuchot
with db_show_regs().
2016-03-09Move db_show_regs() in the only file where it is used and turn it private.Martin Pieuchot
ok mlarkin@
2016-03-07Sync no-argument function declaration and definition by adding (void).Christian Weisgerber
ok mpi@ millert@
2016-03-07boolean_t/FALSE/TRUE -> int/0/1Martin Pieuchot
2016-03-06Merge db_elf_sym_values() into db_symbol_values().Martin Pieuchot
ok stefan@
2016-03-06DDB_REGS -> &ddb_regs.Martin Pieuchot
All our archs use the same define.
2016-03-01db_sym_numargs() has always been defined to FALSE so nuke it with allMartin Pieuchot
its associated dead code. ok mikeb@
2016-03-01Make db_value_of_name() call db_elf_sym_lookup() in order to killMartin Pieuchot
db_lookup() as requested by mlarkin@ While here move the function to db_elf.c do keep db_elf_sym_lookup() private. ok mikeb@ appart from the move the function
2016-03-01DB_SYM_NULL -> NULL.Martin Pieuchot
2016-02-28Remove leftovers from mutliple symbol tables support.Martin Pieuchot
2016-02-27Remove the "symbol table" argument of the functions dealing withMartin Pieuchot
symbols. There's no reason to ask the programmer to supply a specific symbol table since the kernel only have one. ok visa@, guenther@
2016-02-26Remove support for multiple symbol tables in ddb(4), we only have one.Martin Pieuchot
ok mlarkin@, visa@
2016-02-12Kill db_symbol_is_ambiguous(). There's no ambiguous symbol since LKMsMartin Pieuchot
are no longer supported. ok tb@, guenther@
2016-01-27Removes the abstraction layer to support multiple executable binaries.Martin Pieuchot
Simplifies the API to manipulate symbols now that all our architectures are ELF. ok tb@
2016-01-27Remove unused db_sifting().Martin Pieuchot
2016-01-25Do not mix variable declaration and logic.Martin Pieuchot
2016-01-25Kill "#if 0" version of ddb_init().Martin Pieuchot
2016-01-25Kill trailing whitespaces. No object change.Martin Pieuchot
2016-01-15add a "show socket" command to ddbDavid Gwynne
should help inspecting socket issues in the future. enthusiasm from mpi@ bluhm@ deraadt@
2015-12-23assign pointers NULL rather than 0mmcc
2015-09-13On show the ps/o output and ddb.html blurb once, so that we don't get themPhilip Guenther
after each "mach ddbcpu N" ok miod@ deraadt@
2015-09-12show a few more lines of trace; discussed in the roomTheo de Raadt
2015-09-12When panicing, show the non-idle, on-proc threads before showing the stackPhilip Guenther
trace ok deraadt@ miod@ beck@
2015-09-01initialise the width var in db_struct_offset_cmd()Jonathan Gray
ok miod@ deraadt@
2015-08-30Automatically perform traces upon panic. Shrink message aboutTheo de Raadt
reporting bugs to pointing at http://www.openbsd.org/ddb.html, because vertical space becomes more precious. ok beck krw kettenis
2015-08-12Use a linker script when building i386 kernels to allow section padding onMike Larkin
PAGE_SIZE boundaries. This is required to enforce proper separation of sections when adding page protections (coming shortly). This was in snaps before release with no reported side effects. ok deraadt@
2015-07-07Return correct file name entry from DWARF line tableMatthew Dempsky
We run the DWARF line table program to generate each row of the table until we find a row after the one we wanted, and then take the previous row's entries. The code correctly took the previous row's line number entry, but incorrectly took the current row's file name entry. Notably, this caused DDB to report the wrong file names for inlined calls to functions defined in header files. ok mlarkin
2015-05-05emul_native is only used for kernel threads which can't dump core, soPhilip Guenther
delete coredump_trad(), uvm_coredump(), cpu_coredump(), struct md_coredump, and various #includes that are superfluous. This leaves compat_linux processes without a coredump callback. If that ability is desired, someone should update it to use coredump_elf32() and verify the results... ok kettenis@
2015-04-29Also generate db_structinfo.txt with struct member offset and size infoPhilip Guenther
prodded by deraadt@ and miod@
2015-03-14restore systm.h, needed for strcmp. from Steven McDonaldTed Unangst
2015-03-14Remove some includes include-what-you-use claims don'tJonathan Gray
have any direct symbols used. Tested for indirect use by compiling amd64/i386/sparc64 kernels. ok tedu@ deraadt@
2015-01-27remove #include <sys/workq.h>. it wont exist anymore soon.David Gwynne
2014-12-21Prevent writing to the kernel area via the direct map. We do this by paddingMike Larkin
the end of the kernel area to 2MB, so that the direct map pages can then have the W permission removed (X permission was already removed in a previous diff). This creates a VA hole at the end of bss, so adjust for that since that's where symbols get loaded by the bootloader (for now, map that region RO until the boot loader can be updated to place the symbols at "end" instead of "end of bss"). with help from and ok deraadt@
2014-12-19Use <sys/endian.h> instead of <machine/endian.h>Philip Guenther
ok dlg@ mpi@ bcook@ millert@ miod@