mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* Basic question
@ 2002-07-18 22:31 nejhdeh
  2002-07-25 12:53 ` Bill Davidsen
  2002-08-23  1:44 ` nejhdeh
  0 siblings, 2 replies; 8+ messages in thread
From: nejhdeh @ 2002-07-18 22:31 UTC (permalink / raw)
  To: linux-kernel

Hi,

Thanks to your reply erlier. I successfult compiled my device driver separatly 
as module.o and then ran a script to insmod into the kernel.

I have another basic question.

I have two PC systems. First one acts as my development system which I 
develope code using KDevelop running Red Hat linux (2.4.18). When I compile 
my application code (say app.0) and my device driver code (say module.o) then 
I FTP these files into my target system which is a scalled down single-board 
computer (with minimal RAM and disk) which runs linux 2.2.20.

Most of the time everything is O.K. However, when it comes to the device 
driver module (module.o), I get some kernel mismatch problems (obvisouly).

E.g. the file_operations struct in 2.2.20 is different to 2.4.18

My question is: How can I tell gcc or even within the module itself (e.g. 
KERNEL_VERSION) to compile for lower version kernel (i.e tell kernel 2.4.18 
to compile for 2.2.20)

Regards

Nejhdeh Ghevondian


^ permalink raw reply	[flat|nested] 8+ messages in thread
* Basic question
@ 2002-07-16  1:08 nejhdeh
  2002-07-16 12:47 ` Erik Mouw
  0 siblings, 1 reply; 8+ messages in thread
From: nejhdeh @ 2002-07-16  1:08 UTC (permalink / raw)
  To: linux-kernel

I end up getting all the required source codes from kernel-source-2.4.18-5.RPM
> 

> Now, it appears for me to use the kernel routines such as enable_irq 
(defined 
> in (/usr/src/linux-2.4.18-5/arch/i386/kernel/irq.c) I have to make the 
entire 
> kernel.o, since there are a lot of dependencies.
> 

> Do I need to go this far?? 
> 

> What is a simpler way to use these routines (in irq.c) with my application??
> 

> How do I link this module (i.e irq.o) with my application?? I get heaps of 
> unresoleved errors.


^ permalink raw reply	[flat|nested] 8+ messages in thread
* Basic question..
@ 2001-08-01 20:44 Raghava Raju
  2001-08-01 20:55 ` Richard B. Johnson
  2001-08-01 21:04 ` Robert Love
  0 siblings, 2 replies; 8+ messages in thread
From: Raghava Raju @ 2001-08-01 20:44 UTC (permalink / raw)
  To: linux-kernel



   Hi

        I am new to kernel programming. I have
   just written a module consisting of init and
cleanup
   functions. I call init function of the module in
   kernel initialization function. So when system
   comes up, it shows that it entered module init 
   function(printk in "init" print some string), but 
   when I do lsmod it is not there in  list of 
   modules. But if I do insmod module, the module is
   listed in lsmod output. So is it that calling init
   module and insmod are not equivalent?

   Thank You
   Raghava.



__________________________________________________
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2002-08-23  1:42 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-07-18 22:31 Basic question nejhdeh
2002-07-25 12:53 ` Bill Davidsen
2002-08-23  1:44 ` nejhdeh
  -- strict thread matches above, loose matches on Subject: below --
2002-07-16  1:08 nejhdeh
2002-07-16 12:47 ` Erik Mouw
2001-08-01 20:44 Raghava Raju
2001-08-01 20:55 ` Richard B. Johnson
2001-08-01 21:04 ` Robert Love

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome