netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Fwd: Network Core
       [not found] <530d01580811050939q1c1dc52fra6fc2078d86d36e@mail.gmail.com>
@ 2008-11-05 17:40 ` Diego .
  2008-11-05 17:52   ` Rémi Denis-Courmont
                     ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Diego . @ 2008-11-05 17:40 UTC (permalink / raw)
  To: netdev

Hello!

I'm a kernel newbie.

I'm trying to figure how hard it will be build some SMA protocol
inside linux kernel. But i coud'nt  find any information about linux
network layer/core. I started looking at source code inside net/ dir
before asking here.

Could you point me to somewhere i can find some info about howto to
port/create a network protocol to/on linux? ( i mean, some basic info
like the one we can find with the fs layer. I'm not asking about a
magic tutorial about how to port my protocol ). Or some basic network
layer info.

Thanks!

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

* Re: Fwd: Network Core
  2008-11-05 17:40 ` Fwd: Network Core Diego .
@ 2008-11-05 17:52   ` Rémi Denis-Courmont
  2008-11-05 18:38   ` Jesper Dangaard Brouer
  2008-11-05 20:11   ` Chris Snook
  2 siblings, 0 replies; 6+ messages in thread
From: Rémi Denis-Courmont @ 2008-11-05 17:52 UTC (permalink / raw)
  To: Diego .; +Cc: netdev

	Hello!

Le mercredi 5 novembre 2008 19:40:45 Diego ., vous avez écrit :
> Could you point me to somewhere i can find some info about howto to
> port/create a network protocol to/on linux? ( i mean, some basic info
> like the one we can find with the fs layer. I'm not asking about a
> magic tutorial about how to port my protocol ). Or some basic network
> layer info.

My experience with taking over maintainance of the Nokia Phonet stack is that 
there is no such documentation.

http://vger.kernel.org/~davem/ contains some basic infos, especially useful 
w.r.t. network buffer management. Other I stick to the Linux Cross Reference 
at http://lxr.linux.no/ and read the source code. Some of the simpler network 
layers (_not_ IPv4 neither IPv6) can be useful as a basic reference (I read 
through CAN quite a abut).

Hope this helps,

-- 
Rémi Denis-Courmont
http://www.remlab.net/

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

* Re: Fwd: Network Core
  2008-11-05 17:40 ` Fwd: Network Core Diego .
  2008-11-05 17:52   ` Rémi Denis-Courmont
@ 2008-11-05 18:38   ` Jesper Dangaard Brouer
  2008-11-05 20:11   ` Chris Snook
  2 siblings, 0 replies; 6+ messages in thread
From: Jesper Dangaard Brouer @ 2008-11-05 18:38 UTC (permalink / raw)
  To: Diego .; +Cc: netdev

On Wed, 5 Nov 2008, Diego . wrote:

> I'm a kernel newbie.
>
> I'm trying to figure how hard it will be build some SMA protocol
> inside linux kernel. But i coud'nt  find any information about linux
> network layer/core. I started looking at source code inside net/ dir
> before asking here.
>
> Could you point me to somewhere i can find some info about howto to
> port/create a network protocol to/on linux? ( i mean, some basic info
> like the one we can find with the fs layer. I'm not asking about a
> magic tutorial about how to port my protocol ). Or some basic network
> layer info.

I'll recommend the following book:

  "Understanding Linux Network Internals"
  Publisher: O'Reilly
  Author: Christian Benvenuti

Its from 2006 and is about 2.6.x kernel.  I mainly used it when writing a 
Ethernet DSA protocol handler, although for a 2.4.20 kernel on an embedded 
system.  Stephen Hemminger browsed through the book, at my house, and 
noted that it was not quite up-to-date, but close enough.

Cheers,
   Jesper Brouer

--
-------------------------------------------------------------------
MSc. Master of Computer Science
Dept. of Computer Science, University of Copenhagen
Author of http://www.adsl-optimizer.dk
-------------------------------------------------------------------

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

* Re: Fwd: Network Core
  2008-11-05 17:40 ` Fwd: Network Core Diego .
  2008-11-05 17:52   ` Rémi Denis-Courmont
  2008-11-05 18:38   ` Jesper Dangaard Brouer
@ 2008-11-05 20:11   ` Chris Snook
  2008-11-05 20:46     ` Lovich, Vitali
  2 siblings, 1 reply; 6+ messages in thread
From: Chris Snook @ 2008-11-05 20:11 UTC (permalink / raw)
  To: Diego .; +Cc: netdev

Diego . wrote:
> Hello!

Hi.

> I'm a kernel newbie.

Welcome.

> I'm trying to figure how hard it will be build some SMA protocol
> inside linux kernel. But i coud'nt  find any information about linux
> network layer/core. I started looking at source code inside net/ dir
> before asking here.

If you've never worked with kernel code before, it's extremely difficult.  I 
highly recommend that you get involved with development of existing kernel 
networking code before you try to make this leap.

> Could you point me to somewhere i can find some info about howto to
> port/create a network protocol to/on linux? ( i mean, some basic info
> like the one we can find with the fs layer. I'm not asking about a
> magic tutorial about how to port my protocol ). Or some basic network
> layer info.

There are a few O'Reilly books about the kernel networking stack, and anything 
written in the past few years should be recent enough for your purposes.  It 
would probably also be helpful to read articles (such as those on lwn.net) about 
new network stack features that have been added.  The commentary there will give 
you a general idea of the challenges you'll face, but you'll need to complement 
that with experience working with the network code.

-- Chris

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

* RE: Fwd: Network Core
  2008-11-05 20:11   ` Chris Snook
@ 2008-11-05 20:46     ` Lovich, Vitali
  2008-11-05 23:03       ` Diego .
  0 siblings, 1 reply; 6+ messages in thread
From: Lovich, Vitali @ 2008-11-05 20:46 UTC (permalink / raw)
  To: Chris Snook, Diego .; +Cc: netdev@vger.kernel.org



> -----Original Message-----
> From: netdev-owner@vger.kernel.org [mailto:netdev-
> owner@vger.kernel.org] On Behalf Of Chris Snook
> Sent: November-05-08 12:12 PM
> To: Diego .
> Cc: netdev@vger.kernel.org
> Subject: Re: Fwd: Network Core
> 
> Diego . wrote:
> There are a few O'Reilly books about the kernel networking stack, and
> anything
> written in the past few years should be recent enough for your
> purposes.  It
> would probably also be helpful to read articles (such as those on
> lwn.net) about
> new network stack features that have been added.  The commentary there
> will give
> you a general idea of the challenges you'll face, but you'll need to
> complement
> that with experience working with the network code.
> 
> -- Chris
Another idea, at least perhaps from a starting point is to determine whether or not it actually needs to be in user space.  With the addition of the tx ring buffer to af_packet, it should be possible to experiment with your network stack in user space.  Once you're comfortable and feel confident with the stack itself, you can port it to kernel space eventually if you want to.

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

* Re: Fwd: Network Core
  2008-11-05 20:46     ` Lovich, Vitali
@ 2008-11-05 23:03       ` Diego .
  0 siblings, 0 replies; 6+ messages in thread
From: Diego . @ 2008-11-05 23:03 UTC (permalink / raw)
  To: Lovich, Vitali; +Cc: Chris Snook, netdev@vger.kernel.org

wow men!

thank all of you for the answears. Very usefull information..

thanks once again!!

On Wed, Nov 5, 2008 at 9:46 PM, Lovich, Vitali <vlovich@qualcomm.com> wrote:
>
>
>> -----Original Message-----
>> From: netdev-owner@vger.kernel.org [mailto:netdev-
>> owner@vger.kernel.org] On Behalf Of Chris Snook
>> Sent: November-05-08 12:12 PM
>> To: Diego .
>> Cc: netdev@vger.kernel.org
>> Subject: Re: Fwd: Network Core
>>
>> Diego . wrote:
>> There are a few O'Reilly books about the kernel networking stack, and
>> anything
>> written in the past few years should be recent enough for your
>> purposes.  It
>> would probably also be helpful to read articles (such as those on
>> lwn.net) about
>> new network stack features that have been added.  The commentary there
>> will give
>> you a general idea of the challenges you'll face, but you'll need to
>> complement
>> that with experience working with the network code.
>>
>> -- Chris
> Another idea, at least perhaps from a starting point is to determine whether or not it actually needs to be in user space.  With the addition of the tx ring buffer to af_packet, it should be possible to experiment with your network stack in user space.  Once you're comfortable and feel confident with the stack itself, you can port it to kernel space eventually if you want to.
>

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

end of thread, other threads:[~2008-11-05 23:09 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <530d01580811050939q1c1dc52fra6fc2078d86d36e@mail.gmail.com>
2008-11-05 17:40 ` Fwd: Network Core Diego .
2008-11-05 17:52   ` Rémi Denis-Courmont
2008-11-05 18:38   ` Jesper Dangaard Brouer
2008-11-05 20:11   ` Chris Snook
2008-11-05 20:46     ` Lovich, Vitali
2008-11-05 23:03       ` Diego .

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).