mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-18 15:30:21 +00:00
Removed "-D" option and made symbols load all the time. They will be
discarded if the kernel isn't built with DDB.
This commit is contained in:
parent
2706402fd9
commit
78dfa6036a
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=7054
@ -24,7 +24,7 @@
|
|||||||
* the rights to redistribute these changes.
|
* the rights to redistribute these changes.
|
||||||
*
|
*
|
||||||
* from: Mach, [92/04/03 16:51:14 rvb]
|
* from: Mach, [92/04/03 16:51:14 rvb]
|
||||||
* $Id: boot.c,v 1.31 1995/01/25 21:37:38 bde Exp $
|
* $Id: boot.c,v 1.32 1995/01/28 03:51:39 davidg Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
@ -65,7 +65,6 @@ struct bootinfo bootinfo;
|
|||||||
extern void init_serial(void);
|
extern void init_serial(void);
|
||||||
extern int probe_keyboard(void);
|
extern int probe_keyboard(void);
|
||||||
int loadflags;
|
int loadflags;
|
||||||
unsigned char loadsyms;
|
|
||||||
|
|
||||||
extern int end;
|
extern int end;
|
||||||
boot(drive)
|
boot(drive)
|
||||||
@ -93,7 +92,7 @@ int drive;
|
|||||||
printf("\n\
|
printf("\n\
|
||||||
>> FreeBSD BOOT @ 0x%x: %d/%d k of memory\n\
|
>> FreeBSD BOOT @ 0x%x: %d/%d k of memory\n\
|
||||||
Use hd(1,a)/kernel to boot sd0 when wd0 is also installed.\n\
|
Use hd(1,a)/kernel to boot sd0 when wd0 is also installed.\n\
|
||||||
Usage: [[[%s(%d,a)]%s][-Dabcdhrsv]]\n\
|
Usage: [[%s(%d,a)]%s][-abcdhrsv]\n\
|
||||||
Use ? for file list or press Enter for defaults\n\n",
|
Use ? for file list or press Enter for defaults\n\n",
|
||||||
ouraddr, bootinfo.bi_basemem, bootinfo.bi_extmem,
|
ouraddr, bootinfo.bi_basemem, bootinfo.bi_extmem,
|
||||||
devs[drive & 0x80 ? 0 : 2], drive & 0x7f, name);
|
devs[drive & 0x80 ? 0 : 2], drive & 0x7f, name);
|
||||||
@ -131,6 +130,7 @@ loadprog(howto)
|
|||||||
long int addr; /* physical address.. not directly useable */
|
long int addr; /* physical address.. not directly useable */
|
||||||
long int bootdev;
|
long int bootdev;
|
||||||
int i;
|
int i;
|
||||||
|
unsigned pad;
|
||||||
#ifdef REDUNDANT
|
#ifdef REDUNDANT
|
||||||
unsigned char tmpbuf[4096]; /* we need to load the first 4k here */
|
unsigned char tmpbuf[4096]; /* we need to load the first 4k here */
|
||||||
#endif
|
#endif
|
||||||
@ -229,49 +229,45 @@ loadprog(howto)
|
|||||||
pbzero(addr,head.a_bss);
|
pbzero(addr,head.a_bss);
|
||||||
#endif
|
#endif
|
||||||
addr += head.a_bss;
|
addr += head.a_bss;
|
||||||
if (loadsyms)
|
|
||||||
{
|
|
||||||
unsigned pad;
|
|
||||||
|
|
||||||
/* Pad to a page boundary. */
|
/* Pad to a page boundary. */
|
||||||
pad = (unsigned)addr % NBPG;
|
pad = (unsigned)addr % NBPG;
|
||||||
if (pad != 0) {
|
if (pad != 0) {
|
||||||
pad = NBPG - pad;
|
pad = NBPG - pad;
|
||||||
addr += pad;
|
addr += pad;
|
||||||
}
|
|
||||||
bootinfo.bi_symtab = addr;
|
|
||||||
|
|
||||||
/********************************************************/
|
|
||||||
/* Copy the symbol table size */
|
|
||||||
/********************************************************/
|
|
||||||
pcpy(&head.a_syms, addr, sizeof(head.a_syms));
|
|
||||||
addr += sizeof(head.a_syms);
|
|
||||||
|
|
||||||
/********************************************************/
|
|
||||||
/* Load the symbol table */
|
|
||||||
/********************************************************/
|
|
||||||
printf("symbols=[+0x%x+0x%x+0x%x", pad, sizeof(head.a_syms),
|
|
||||||
head.a_syms);
|
|
||||||
xread(addr, head.a_syms);
|
|
||||||
addr += head.a_syms;
|
|
||||||
|
|
||||||
/********************************************************/
|
|
||||||
/* Load the string table size */
|
|
||||||
/********************************************************/
|
|
||||||
read(&i, sizeof(int));
|
|
||||||
pcpy(&i, addr, sizeof(int));
|
|
||||||
i -= sizeof(int);
|
|
||||||
addr += sizeof(int);
|
|
||||||
|
|
||||||
/********************************************************/
|
|
||||||
/* Load the string table */
|
|
||||||
/********************************************************/
|
|
||||||
printf("+0x%x+0x%x] ", sizeof(int), i);
|
|
||||||
xread(addr, i);
|
|
||||||
addr += i;
|
|
||||||
|
|
||||||
bootinfo.bi_esymtab = addr;
|
|
||||||
}
|
}
|
||||||
|
bootinfo.bi_symtab = addr;
|
||||||
|
|
||||||
|
/********************************************************/
|
||||||
|
/* Copy the symbol table size */
|
||||||
|
/********************************************************/
|
||||||
|
pcpy(&head.a_syms, addr, sizeof(head.a_syms));
|
||||||
|
addr += sizeof(head.a_syms);
|
||||||
|
|
||||||
|
/********************************************************/
|
||||||
|
/* Load the symbol table */
|
||||||
|
/********************************************************/
|
||||||
|
printf("symbols=[+0x%x+0x%x+0x%x", pad, sizeof(head.a_syms),
|
||||||
|
head.a_syms);
|
||||||
|
xread(addr, head.a_syms);
|
||||||
|
addr += head.a_syms;
|
||||||
|
|
||||||
|
/********************************************************/
|
||||||
|
/* Load the string table size */
|
||||||
|
/********************************************************/
|
||||||
|
read(&i, sizeof(int));
|
||||||
|
pcpy(&i, addr, sizeof(int));
|
||||||
|
i -= sizeof(int);
|
||||||
|
addr += sizeof(int);
|
||||||
|
|
||||||
|
/********************************************************/
|
||||||
|
/* Load the string table */
|
||||||
|
/********************************************************/
|
||||||
|
printf("+0x%x+0x%x] ", sizeof(int), i);
|
||||||
|
xread(addr, i);
|
||||||
|
addr += i;
|
||||||
|
|
||||||
|
bootinfo.bi_esymtab = addr;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* For backwards compatibility, use the previously-unused adaptor
|
* For backwards compatibility, use the previously-unused adaptor
|
||||||
@ -313,8 +309,6 @@ getbootdev(howto)
|
|||||||
if (c=='-')
|
if (c=='-')
|
||||||
while ((c = *++ptr) && c!=' ')
|
while ((c = *++ptr) && c!=' ')
|
||||||
switch (c) {
|
switch (c) {
|
||||||
case 'D':
|
|
||||||
loadsyms = 1; continue;
|
|
||||||
case 'a':
|
case 'a':
|
||||||
*howto |= RB_ASKNAME; continue;
|
*howto |= RB_ASKNAME; continue;
|
||||||
case 'b':
|
case 'b':
|
||||||
|
Loading…
Reference in New Issue
Block a user