LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
Search this Thread
Old 05-08-2005, 11:26 AM   #1
introuble
Member
 
Registered: Apr 2004
Distribution: Debian -unstable
Posts: 700

Rep: Reputation: 31
Linux 2.6 Module programming - failed first attempts


Hello !

Ok , I'm reading http://sdn.vlsm.org/share/LDP/lkmpg/2.6/html/index.html in an attempt to learn a bit about Linux Kernerl Module programming .

The programming part is fairly easy to understand .. what I can't understand is how I am supposed to compile the modules ..

Quote:
So, let's look at a simple Makefile for compiling a module named hello-1.c:
.. so .. do I just go "vi Makefile" in the same dirrectory as my hello-1.c and insert there obj-m += hello-1.o ; followed by "make -C /usr/src/linux-`uname -r` SUBDIRS=$PWD modules" ? because it doesn't work ..

Also .. "usual" task as .. writing/reading to/from files/sockets and other tasks .. are they achieved in modules in the same way (same functions) as in normal programs ?

Also , does anyone know of any more , valuable (preferably Free and available Online) resources on this topic ?

Thank you for your attention !
 
Old 05-08-2005, 12:24 PM   #2
btmiller
Senior Member
 
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,134

Rep: Reputation: 320Reputation: 320Reputation: 320Reputation: 320
You might find the 3rd edition of Linux Device Drivers useful. I have to the point that I purchased a paper copy even though it's available for free online from the publisher (thank you, O'Reilly).
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
SSH tricks -- any way to block failed attempts by IP address tensigh Linux - Security 10 06-06-2008 03:46 PM
Failed SSH login attempts Capt_Caveman Linux - Security 38 01-03-2006 03:22 PM
Multiple installation attempts in a laptop failed miserably KLG Ubuntu 1 07-08-2005 06:46 AM
lock password after failed attempts... manudath Linux - Security 2 04-28-2005 10:55 AM
all attempts failed btb103 Linux - General 1 10-23-2001 05:31 PM


All times are GMT -5. The time now is 08:22 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration