Yang Zhiguo wrote:
hi,
i run crash with gdb.
[root@rhel51rc2 crash-4.0-6.1]# gdb ./crash
GNU gdb Red Hat Linux (6.5-25.el5rh)
Copyright (C) 2006 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "ia64-redhat-linux-gnu"...Using host libthread_db
library "/lib/libthread_db.so.1".
(gdb) b search
Breakpoint 1 at 0x40000000000f8e11: file memory.c, line 11025.
(gdb) r -s
Starting program: /home/yangzg/crash-4.0-6.1/crash -s
crash> search -k 12345
Breakpoint 1, search (start=11529215046068469760, end=18446744073709551615, mask=0,
memtype=1, value=0x60000fffffe3eab0, vcnt=1) at memory.c:11025
11025 if (start & (sizeof(long)-1)) {
(gdb) n
11030 pagebuf = GETBUF(PAGESIZE());
(gdb)
11031 next = start;
(gdb)
11033 for (pp = VIRTPAGEBASE(start); next < end; next = pp) {
(gdb)
11034 lastpage = (VIRTPAGEBASE(next) == VIRTPAGEBASE(end));
(gdb)
11035 if (LKCD_DUMPFILE())
(gdb)
11038 switch (memtype)
(gdb)
11050 if (!kvtop(CURRENT_CONTEXT(), pp, &paddr, 0) ||
(gdb) s
kvtop (tc=0x6000000001ec1c50, kvaddr=11529215046068469760, paddr=0x60000fffffe368e8,
verbose=0) at memory.c:2306
2306 return (machdep->kvtop(tc ? tc : CURRENT_CONTEXT(), kvaddr,
(gdb) s
ia64_kvtop (tc=0x6000000001ec1c50, kvaddr=11529215046068469760, paddr=0x60000fffffe368e8,
verbose=0) at ia64.c:1031
1031 if (!IS_KVADDR(kvaddr))
(gdb) n
1034 if (!vt->vmalloc_start) {
(gdb)
1039 switch (VADDR_REGION(kvaddr))
(gdb)
1054 if (ia64_IS_VMALLOC_ADDR(kvaddr))
(gdb)
1056 *paddr = ia64_VTOP(kvaddr);
(gdb) s
ia64_VTOP (vaddr=11529215046068469760) at ia64.c:3501
3501 ms = &ia64_machine_specific;
(gdb) n
3503 switch (VADDR_REGION(vaddr))
(gdb)
3522 if (ia64_IS_VMALLOC_ADDR(vaddr) ||
(gdb)
3531 paddr = vaddr - ms->kernel_start +
(gdb)
3533 break;
(gdb) p/x paddr
$1 = 0xffffffff04000000 ======>error occured
(gdb) p/x vaddr
$2 = 0xa000000000000000
(gdb) p/x ms->kernel_start
$3 = 0xa000000100000000
(gdb) p/x ms->phys_start
$4 = 0x4000000
(gdb)
Best Regards,
yang
I can reproduce it on a bare-metal RHEL5 kernel, so let me
figure out what's going on...
Thanks,
Dave