lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <9ea470500911250945x72052c22hb0ccebf2fe96798a@mail.gmail.com>
Date:	Wed, 25 Nov 2009 18:45:02 +0100
From:	Borislav Petkov <petkovbb@...glemail.com>
To:	Tanya Gornak <errizo@...il.com>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: Kernel module, undefined symbol show_regs

On Wed, Nov 25, 2009 at 1:27 PM, Tanya Gornak <errizo@...il.com> wrote:
> Hello. I can't solve problem that happens while I'm making my kernel module.
>
> part of my module:
> // ...
> #include <linux/sched.h>
> //....
> static u32 task_syscall_entry(enum utrace_resume_action action,
>                                 struct utrace_engine *engine,
>                                 struct task_struct *task,
>                                 struct pt_regs *regs){
>     // ...
>         show_regs(regs);
>
> }
> But, while making I get:
>
> WARNING: "show_regs" [/home/tehhi/module/trace.ko] undefined!
>
> extern void show_regs(struct pt_regs *);  define in header
> linux/sched.h, place of source code is
> linux/arch/x86/kernel/process_32.c
> It use extern void __show_regs(struct pt_regs *); and extern
> asmlinkage void __backtrace(void);
> I think that extern means that I can use it (and there are no static
> symbols in this function).
>
> When trying to insert module, it predictably complains of an unknown
> symbol show_regs.
>
> What am I missing here?

You're using a function in a module which is not exported to modules.
See http://lwn.net/images/pdf/LDD3/ch02.pdf for more details.

-- 
Regards/Gruss,
Boris
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ