netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "David S. Miller" <davem@redhat.com>
To: Kazunori.Miyazawa@jp.yokogawa.com
Cc: netdev@oss.sgi.com, usagi-core@linux-ipv6.org, kuznet@ms2.inr.ac.ru
Subject: Re: [PATCH] IPv6 IPsec support
Date: Tue, 18 Feb 2003 23:13:24 -0800 (PST)	[thread overview]
Message-ID: <20030218.231324.44469350.davem@redhat.com> (raw)
In-Reply-To: <20030219134850.5f203ea7.Kazunori.Miyazawa@jp.yokogawa.com>

   From: Kazunori MIyazawa <Kazunori.Miyazawa@jp.yokogawa.com>
   Date: Wed, 19 Feb 2003 13:48:50 +0900

   Please let me know if you have some ideas and/or comments.

Hello again Miyazawa-san, I give you my initial comment.

I see very quickly that the ipv6 side of implementation will
give lots of opportunity for code sharing.  But we must plan
it correctly :-)
   
I also wish to avoid exporting internal xfrm objects to ipv6 module.

So, let us discuss one example:
   
   diff -urN linux-2.5.62/net/ipv4/xfrm_input.c linux25_for_patch/net/ipv4/xfrm_input.c
   --- linux-2.5.62/net/ipv4/xfrm_input.c	2003-02-18 07:55:50.000000000 +0900
   +++ linux25_for_patch/net/ipv4/xfrm_input.c	2003-02-19 02:36:53.000000000 +0900
   @@ -1,7 +1,7 @@
    #include <net/ip.h>
    #include <net/xfrm.h>
    
   -static kmem_cache_t *secpath_cachep;
   +kmem_cache_t *secpath_cachep;
    
    void __secpath_destroy(struct sec_path *sp)
    {

I understand why you need this, for xfrm6_rcv().  This is fine.

However, it would be even better to put xfrm6_rcv() into
net/ipv4/xfrm_input.c, protected by CONFIG_IPV6 || CONFIG_IPV6_MODULE
ifdef.

In this way we may split out identical pieces of code which
occur in xfrm4_rcv() and xfrm6_rcv().  Then we merely need
to export the xfrm6_rcv symbol for sake of ipv6 as module.

In fact, nearly %90 of these two functions are identical.

  parent reply	other threads:[~2003-02-19  7:13 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-02-19  4:48 [PATCH] IPv6 IPsec support Kazunori MIyazawa
2003-02-19  4:50 ` David S. Miller
2003-02-19  5:10   ` Kunihiro Ishiguro
2003-02-19  5:17     ` Mitsuru KANDA / 神田 充
2003-02-19  5:58       ` Kazunori Miyazawa
2003-02-19  5:30   ` YOSHIFUJI Hideaki / 吉藤英明
2003-02-19  5:57 ` Kunihiro Ishiguro
2003-02-19  7:02   ` David S. Miller
2003-02-19  9:13     ` Kunihiro Ishiguro
2003-02-19  7:13 ` David S. Miller [this message]
2003-02-19  7:33 ` David S. Miller
2003-02-19 14:39   ` (usagi-core 11926) " Kazunori MIyazawa
2003-02-19 21:27     ` David S. Miller
2003-02-19 16:56   ` Mitsuru KANDA / 神田 充
2003-02-19 21:43     ` David S. Miller
2003-02-19 23:10     ` Kunihiro Ishiguro
2003-02-20  0:37       ` David S. Miller
  -- strict thread matches above, loose matches on Subject: below --
2003-02-22 11:26 [PATCH] IPv6 IPSEC support Kazunori Miyazawa
2003-02-22 11:13 ` David S. Miller
2003-02-22 12:15   ` Kazunori Miyazawa
2003-02-22 12:49   ` YOSHIFUJI Hideaki / 吉藤英明
2003-02-22 23:47     ` David S. Miller
2003-02-23  0:44       ` YOSHIFUJI Hideaki / 吉藤英明
2003-02-23 15:35   ` Kazunori Miyazawa

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=20030218.231324.44469350.davem@redhat.com \
    --to=davem@redhat.com \
    --cc=Kazunori.Miyazawa@jp.yokogawa.com \
    --cc=kuznet@ms2.inr.ac.ru \
    --cc=netdev@oss.sgi.com \
    --cc=usagi-core@linux-ipv6.org \
    /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;
as well as URLs for NNTP newsgroup(s).