lkml.org 
[lkml]   [2006]   [Jul]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Module link
Thanks for all responses. The file was modified from 
drivers/macintosh/therm_adt746x.c, the function call i2c_add_driver() in
static int __init thermostat_init(void) caused a null point. In fact,
all i2c related functions were not linked. The i2c-core.c has been built
in kernel. How does the module therm_adt746x.ko link to i2c? I did not
see that the module therm_adt746x.ko resolved symbol i2c_add_driver. Or,
the symbols are resolved during insmod? I guess I try to figure out
whether this problem is caused by building process in kernel or by
module loading process in insmod (using BusyBox)?

Thank you.

Jim

Dave C Boutcher wrote:
> On Fri, 7 Jul 2006 15:33:43 +1000 (EST), yh@bizmail.com.au said:
>
>>Thanks Randy. Let me clarify it.
>>I have a driver module (NewSerialModule.ko) and I build it for module
>>load. This driver module uses i2c functions. It was fine to init this
>>module in kernel 2.4 as the i2c functions are exported in i2c Makefile.
>>
>>In kernel 2.6, I loaded this module and got NULL point exception. I
>>checked the module map, all i2c functions are not linked. I also checked
>>i2c, there is no export for i2c in kernel 2.6. So, my question is how can
>>I link the dirvers/i2c to my driver module in drivers/char directory? How
>>to export a directory to be a library such as i2c? In general, how to link
>>another directory functions by a module in kernel 2.6?
>
>
> It is difficult for any of us to offer assistance unless you provide a
> pointer to your source code.
>
> However, I will point out that the i2c functions are exported from
> drivers/i2c/i2c-core.c, so you should make sure you have that module
> either built into your kernel or loaded.
>
> Dave B
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/
>

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

\
 
 \ /
  Last update: 2006-07-08 01:37    [W:0.044 / U:0.492 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site