This is the mail archive of the binutils@sourceware.org mailing list for the binutils 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: objdump -d -r doesn't always show reloc symbol


On Sun, 2008-10-05 at 14:43 +0200, Andreas Schwab wrote:
> Richard Kennedy <richard@rsk.demon.co.uk> writes:
> 
> > Hi,
> > I've been seeing an issue on linux x86_64 when running objdump -d -r on
> > some kernel modules.
> >
> > Occasionally some of the relocated symbols don't get resolved.
> 
> What do you mean with "resolved"?  objdump just uses the symbol that is
> recorded with the relocation info and does not interpret it in any way.
> 
> > e.g
> > objdump -d -r sound/drivers/snd-dummy.ko
> >
> > most of it is as expected, except this :- 
> >
> > Disassembly of section .exit.text:
> > 0000000000000000 <cleanup_module>:
> >    0:   e9 00 00 00 00          jmpq   5 <snd_card_dummy_pcm_pointer+0x5>
> >                         1: R_X86_64_PC32        .text+0x4e
> > but I expected to see
> >                         1: R_X86_64_PC32        snd_dummy_unregister_all-0x04
> 
> That would be a different relocation.
> 
> Andreas.
> 
Andreas,
Thanks for that. I'm obviously just confused.

the code is this :-

static void __exit alsa_card_dummy_exit(void)
{
	snd_dummy_unregister_all();
}

and I guess I was expecting the reloc record to point to 
snd_dummy_unregister_all rather than .text+0x4e.

sorry for the noise

regards
Richard






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