RE: need help regarding linux kernel programming

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

 



Hi Jesper,
Where can I get an online book on Understanding Linux Network Internals. Can
you provide me a link to that please.
Thanks in advance.

Regards,
Rajendra Stalekar(extn 2016)
Location:- Akruti
Mobile no:- +91 9860501143
 

-----Original Message-----
From: kernelnewbies-bounce@xxxxxxxxxxxx
[mailto:kernelnewbies-bounce@xxxxxxxxxxxx] On Behalf Of Jesper Juhl
Sent: Saturday, July 07, 2007 3:19 AM
To: Devendra Durgapal
Cc: kernelnewbies@xxxxxxxxxxxx
Subject: Re: need help regarding linux kernel programming

On 06/07/07, Devendra Durgapal <ddlinuxinfo@xxxxxxxxx> wrote:
> Hi All,
>
> I am very much new to kernel programming. I don't have any industry
> experience regarding same. I am amateur fun of linux programming.
> I want to step up on kernel programming. I found lot of legends of kernel
> programming in this mailing-list. Can any body point me as well guide
> me for linux kernel programming.
>
> I want to know following-
> 1) Which document or book shall i follow of basic kernel architecture.

There are many good books to read, but one I can personally recommend
is "Linux Kernel Development, Second Edition" by Robert Love - very
good book and a fairly easy read for a beginner.

Linux Device Drivers is also a good book to read, especially if you
want to dive into some of the driver code. You can buy the book in
paper form or read the freely available online version:
http://lwn.net/Kernel/LDD3/

You should also read the file Documentation/HOWTO in the kernel source
tree. It contains a lot of good info and pointers to more documents to
read. It was actually written specifically to help answer questions
like the ones you pose here.


> 2) How to setup my own dev box.

Well, all you really need is simply a copy of the kernel source, a
text editor and the compiler and other standard tools needed to
compile the kernel. You can get the kernel source via http or ftp from
http://kernel.org/ or you can use git (here's a good starting point
for git: http://linux.yyz.us/git-howto.html). As for a text editor,
well, pick your favorite, they all work - vim, emacs, pico, joe, nano,
mcedit, nedit, etc etc. Your distribution should be able to provide
you with gcc, make and the other tools you need to build the kernel
(nothing out of the ordinary, but you can read Documentation/Changes
in the kernel source if you want a full list).

Ohh and don't remember to keep backups of important stuff if you are
not using a seperate development box :-)

If you have a second computer available, setting up serial console or
or netconsole to capture kernel log messages on that second box can
sometimes be really useful when one of your patches hang the kernel
and log messages don't make it to the disk.


> 3) Should I take the older kernel first then proceed to latest one. Or
> directly jump to latest one
>      with bookies knowledge of basic kernel programming.

Don't waste your time with an old kernel, just dive in where things
are happening now. If you want to make some modifications and submit
patches, then you probably want to track the tip of Linus' git tree
and work against that, or at least the latest git snapshot from
kernel.org or you could grab the latest stable kernel (currently
2.6.21.5) and work against that, but generally patches against
tip-of-tree or latest git snapshot are prefered.


> 4) What all debugging tools shall I need to use as traditional approach.

The best debugging tools are
1) Your brain
2) printk();

It is possible to use debuggers on the kernel (look into kgdb,
debugging a UML kernel etc), but using traditional userspace debugging
tools/techniques on the kernel is often not possible (or at least
difficult), so most of the time debugging actually happens by simply
reading the code and sometimes by sprinkling printk() statements to
printout interresting things from the kernel while it is running.


> 4) Which link or document should I follow linearly to grow up in kernel
> programming.
>
I think Documentation/HOWTO is the closest you can currently get to
such a document.

> I am very very thankful to all of you who are helping me and who are
active
> member of this mailing-list.
>

-- 
Jesper Juhl <jesper.juhl@xxxxxxxxx>
Don't top-post  http://www.catb.org/~esr/jargon/html/T/top-post.html
Plain text mails only, please      http://www.expita.com/nomime.html

--
To unsubscribe from this list: send an email with
"unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx
Please read the FAQ at http://kernelnewbies.org/FAQ



--
To unsubscribe from this list: send an email with
"unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx
Please read the FAQ at http://kernelnewbies.org/FAQ


[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