break on the physical address of brkfunc
The kernel may panic early when paging is not yet configured. Breaking only on the virtual address of brkfunc does not work in this case and leads to timeouts during 'make grade'. Signed-off-by: Junjie Mao <eternal.n08@gmail.com>
This commit is contained in:
@@ -146,9 +146,13 @@ run_qemu() {
|
||||
if [ -n "$brkfun" ]; then
|
||||
# find the address of the kernel $brkfun function
|
||||
brkaddr=`$grep " $brkfun\$" $sym_table | $sed -e's/ .*$//g'`
|
||||
brkaddr_phys=`echo $brkaddr | sed "s/^c0/00/g"`
|
||||
(
|
||||
echo "target remote localhost:$gdbport"
|
||||
echo "break *0x$brkaddr"
|
||||
if [ "$brkaddr" != "$brkaddr_phys" ]; then
|
||||
echo "break *0x$brkaddr_phys"
|
||||
fi
|
||||
echo "continue"
|
||||
) > $gdb_in
|
||||
|
||||
@@ -578,4 +582,3 @@ run_test -prog 'priority' -check default_check \
|
||||
|
||||
## print final-score
|
||||
show_final
|
||||
|
||||
|
||||
Reference in New Issue
Block a user