freebsd-dev/sys/mips/mips
Roger Pau Monné c98a2727cc ddb: allow specifying the exact address of the symtab and strtab
When the FreeBSD kernel is loaded from Xen the symtab and strtab are
not loaded the same way as the native boot loader. This patch adds
three new global variables to ddb that can be used to specify the
exact position and size of those tables, so they can be directly used
as parameters to db_add_symbol_table. A new helper is introduced, so callers
that used to set ksym_start and ksym_end can use this helper to set the new
variables.

It also adds support for loading them from the Xen PVH port, that was
previously missing those tables.

Sponsored by: Citrix Systems R&D
Reviewed by:	kib

ddb/db_main.c:
 - Add three new global variables: ksymtab, kstrtab, ksymtab_size that
   can be used to specify the position and size of the symtab and
   strtab.
 - Use those new variables in db_init in order to call db_add_symbol_table.
 - Move the logic in db_init to db_fetch_symtab in order to set ksymtab,
   kstrtab, ksymtab_size from ksym_start and ksym_end.

ddb/ddb.h:
 - Add prototype for db_fetch_ksymtab.
 - Declate the extern variables ksymtab, kstrtab and ksymtab_size.

x86/xen/pv.c:
 - Add support for finding the symtab and strtab when booted as a Xen
   PVH guest. Since Xen loads the symtab and strtab as NetBSD expects
   to find them we have to adapt and use the same method.

amd64/amd64/machdep.c:
arm/arm/machdep.c:
i386/i386/machdep.c:
mips/mips/machdep.c:
pc98/pc98/machdep.c:
powerpc/aim/machdep.c:
powerpc/booke/machdep.c:
sparc64/sparc64/machdep.c:
 - Use the newly introduced db_fetch_ksymtab in order to set ksymtab,
   kstrtab and ksymtab_size.
2014-09-25 08:28:10 +00:00
..
autoconf.c
bcopy.S Replace uses of the ALEAF macro with XLEAF and remove ALEAF macro to 2013-10-15 04:43:31 +00:00
bus_space_fdt.c Update NetBSD Foundation copyrights to 2-clause BSD 2014-03-18 01:40:25 +00:00
bus_space_generic.c Update NetBSD Foundation copyrights to 2-clause BSD 2014-03-18 01:40:25 +00:00
busdma_machdep.c Add bus_dmamap_load_ma() function to load map with the array of 2013-10-27 21:39:16 +00:00
cache_mipsNN.c o) Use ABI, not ISA_* options, to determine whether to compile bits if libkern 2012-03-12 21:25:32 +00:00
cache.c MFP4: 2013-10-22 21:16:57 +00:00
cpu.c MFP4: 2013-10-22 21:16:57 +00:00
db_disasm.c
db_interface.c Don't include asm.h in non-asm files. 2013-05-01 06:57:46 +00:00
db_trace.c Don't assign the copyright to the FreeBSD foundation for the years 2013-05-29 16:51:03 +00:00
dump_machdep.c Add error return to dumpsys(), and use it in doadump(). 2014-07-25 23:52:53 +00:00
elf_machdep.c
elf_trampoline.c Shuffle the includes around so they occur after opt_global.h is included; 2013-10-09 00:22:21 +00:00
exception.S - For kernel compiled only with KDTRACE_HOOKS and not any lock debugging 2013-11-25 07:38:45 +00:00
fp.S Elminate NON_LEAF and use NESTED instead to unify our assembler 2013-10-15 04:45:09 +00:00
freebsd32_machdep.c o) Use ABI, not ISA_* options, to determine whether to compile bits if libkern 2012-03-12 21:25:32 +00:00
gdb_machdep.c Update NetBSD Foundation copyrights to 2-clause BSD 2014-03-18 01:40:25 +00:00
genassym.c Garbage collect some unused symbols. 2012-03-06 08:40:21 +00:00
in_cksum.c
inckern.S
intr_machdep.c Move PMC hook invocation to cpu_intr. The idea is the same as with ast() 2012-03-22 17:47:52 +00:00
libkern_machdep.c o) Use ABI, not ISA_* options, to determine whether to compile bits if libkern 2012-03-12 21:25:32 +00:00
locore.S At the risk of reducing source compatibility with old NetBSD and Sprite: 2012-03-06 19:01:32 +00:00
machdep.c ddb: allow specifying the exact address of the symtab and strtab 2014-09-25 08:28:10 +00:00
mem.c
minidump_machdep.c
mp_machdep.c Retire smp_active. It was racey and caused demonstrated problems with 2014-04-26 20:27:54 +00:00
mpboot.S Get rid of duplicated versions of the KSU bits. 2012-03-06 23:08:02 +00:00
nexus.c Move Open Firmware device root on PowerPC, ARM, and MIPS systems to 2014-02-05 14:44:22 +00:00
octeon_cop2_swtch.S
octeon_cop2.c
pm_machdep.c More like gone in 11... 2014-04-24 21:17:48 +00:00
pmap.c Change pmap_enter(9) interface to take flags parameter and superpage 2014-08-08 17:12:03 +00:00
ptrace_machdep.c
sc_machdep.c Provide basic glue to allow syscons to be used on MIPS, modelled 2012-08-25 08:09:37 +00:00
stack_machdep.c Fix several typos 2013-05-12 16:43:26 +00:00
stdatomic.c Make support for atomics on ARM complete. 2013-06-15 08:15:22 +00:00
support.S Elminate NON_LEAF and use NESTED instead to unify our assembler 2013-10-15 04:45:09 +00:00
swtch.S Elminate NON_LEAF and use NESTED instead to unify our assembler 2013-10-15 04:45:09 +00:00
sys_machdep.c Remove clause 3 (the advertising clause), per the regent's letter. 2014-03-11 17:20:50 +00:00
tick.c Panics about how things can't be attached should probably happen in the 2013-10-29 20:38:58 +00:00
tlb.c Add pagemask debugging output in "show tlb" in the debugger. 2013-09-29 10:14:16 +00:00
trap.c Invoke the DTrace trap handler before calling trap() on amd64. This matches 2014-07-14 04:38:17 +00:00
uio_machdep.c Delete stray clause 3 (Advertising clause) and renumber while i'm 2014-03-11 23:41:35 +00:00
uma_machdep.c Rename global cnt to vm_cnt to avoid shadowing. 2014-03-22 10:26:09 +00:00
vm_machdep.c Merge all MD sf_buf allocators into one MI, residing in kern/subr_sfbuf.c 2014-08-05 09:44:10 +00:00