Netdev List
 help / color / mirror / Atom feed
From: "kalash nainwal" <kalash.nainwal@gmail.com>
To: "Tej Parkash" <tejparkash.d@gmail.com>
Cc: netdev@vger.kernel.org
Subject: Re: extra layer below inet layer.
Date: Thu, 7 Jun 2007 16:00:33 +0530	[thread overview]
Message-ID: <416aa1ad0706070330i12fe211dn25cd2d174f3a7100@mail.gmail.com> (raw)
In-Reply-To: <2bd9ebfa0706062140vfddf3etfc8fd17749c9ad12@mail.gmail.com>

On 6/7/07, Tej Parkash <tejparkash.d@gmail.com> wrote:
> hi
>
> i just want to have something like tcp layer sitting below inet layer.
> so that i can directly offload everything to NIC
> and i want it to be placed dynamically. so depending on the nic i can
> offload the feature or can make it normal flow.
> i.e. both layer should exist and normal functionality should not break.
>
> this code is in af_inet.c
>
> static struct inet_protosw inetsw_array[] =
> {
>        {
>                .type =       SOCK_STREAM,
>                .protocol =   IPPROTO_TCP,
>                .prot =       &tcp_prot,
>                .ops =        &inet_stream_ops,
>                .capability = -1,
>                .no_check =   0,
>                .flags =      INET_PROTOSW_PERMANENT |
>                              INET_PROTOSW_ICSK,
>        },
>
>        {
>                .type =       SOCK_DGRAM,
>                .protocol =   IPPROTO_UDP,
>                .prot =       &udp_prot,
>                .ops =        &inet_dgram_ops,
>                .capability = -1,
>                .no_check =   UDP_CSUM_DEFAULT,
>                .flags =      INET_PROTOSW_PERMANENT,
>       },
>
>
>       {
>               .type =       SOCK_RAW,
>               .protocol =   IPPROTO_IP,        /* wild card */
>               .prot =       &raw_prot,
>               .ops =        &inet_sockraw_ops,
>               .capability = CAP_NET_RAW,
>               .no_check =   UDP_CSUM_DEFAULT,
>               .flags =      INET_PROTOSW_REUSE,
>       }
> };
>
> i was just going through the code i found that if i can regsiter above
> kind of registration dynamically i will be able to do that.
> i have tried to do that but since normal tcp registered this at boot
> up time i am not able to unregister this dynamically
>
> so is it possible to unregister tcp and register my protocol dynamically.

inet_unregister_protosw()/inet_register_protosw().

-Kalash

  parent reply	other threads:[~2007-06-07 10:30 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-07  4:40 extra layer below inet layer Tej Parkash
2007-06-07  5:25 ` Stephen Hemminger
2007-06-07 10:30 ` kalash nainwal [this message]
2007-06-07 10:33   ` kalash nainwal

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=416aa1ad0706070330i12fe211dn25cd2d174f3a7100@mail.gmail.com \
    --to=kalash.nainwal@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=tejparkash.d@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox