This is the mail archive of the gdb@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: gdb 6.5 does not open linux kernel core file properly


* Bernhard Walle <bernhard.walle@gmx.de> [2007-06-03 11:27]:
> Vivek Goyal wrote:
> > I am using GNU gdb Red Hat Linux (6.5-5.fc6rh).
> > 
> > This problem is not present in gdb 6.4. It works perfectly fine.
> 
> I found out that the error appeared with following change:
> 
> cvs diff -u -D "2006-01-24 22:30:00 -0000" -D "2006-01-24 22:40:00 -0000"
> 
> The problem is svr4_solib_create_inferior_hook() -> svr4_relocate_main_executable().
> If I comment out this function, everything works fine. ;-)

Should the kernel not mark it's ELF type to ET_DYN (but then it's
difficult to distinguish between a relocatable kernel and a
unrelocatable kernel)? Or should we add a .interp section to the
kernel (but I don't think it's a good idea, it would be more a
workaround, IMO).

However, the PC which is used to relocate the binary is completely
wrong because it's in physical virtual space and the start address
is in physical address space. And even if it would be transferred to
physical address space, it would not mark the beginning of the kernel
(entry point), so it's unusable for relocation.



Thanks,
   Bernhard


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]