Re: kallsyms_lookup_name

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Aug 6, 2011 at 12:55, Venkatram Tummala <venkatram867@xxxxxxxxx> wrote:
> Hi,
>
> I need to use some unexported kernel symbols in my kernel module but in the
> particular kernel version i am based on (2.6.18 - RHEL 5.7),
> kallsyms_lookup_name is not exported and there is no kallsyms_on_each_symbol
> in this kernel. And I can't change the kernel owing to reasons i have no
> control over.
>
> In this scenario, how do i use unexported symbols. Is there any other
> mechanism by which i can lookup the address of a kernel symbol.

I think it's a bit dirty, but how about scanning the kernel ".text"
area and find the start of "code fingerprint" of
kallsyms_on_each_symbol?

What I meant by fingerprint is actually few first bytes of the
function, likely ones that did stack pop and does initial looping.

Or if possible, use debuginfo repository and use the debug symbols to
see where the symbol is located. Then do direct "call".

Just a thought....

-- 
regards,

Mulyadi Santosa
Freelance Linux trainer and consultant

blog: the-hydra.blogspot.com
training: mulyaditraining.blogspot.com

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@xxxxxxxxxxxxxxxxx
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux