Re: About my ipsec additions

Eddie Kohler <[email protected]> Fri, 22 Jun 2012 12:00:08 -0400
Newsgroups gmane.network.routing.click
Message-ID <CAF0C5S+PJNxjdR0H9vO2e+cOhwtPRO7d5dU2ySbe+av5CK9zkw@mail.gmail.com>
Hi Markku,

Thanks so much for producing this branch! Not only would any vaguely
working IPsec elements be better than what we have now, but also your
code looks quite strong, so I'm inclined to just merge it, with your
blessing.

But I looked through it very briefly for nits. Here are two,
interested in your thoughts.
- IPsec::Mutex: Why? We have Spinlock for this... At least make it a
nested class or call it IPsecMutex.
- dynamic_cast: What you actually want to do here is call "cast()", a
Click-specific function designed for exactly this use. So

IPsecTransform *tr = (IPsecTransform *)
e->output(port).element()->cast("IPsecTransform");

Best,
Eddie



On Fri, Jun 15, 2012 at 2:36 AM, Markku Savela <[email protected]> wrote:
> On 06/14/2012 05:09 PM, Markku Savela wrote:
>> As the whole thing is just additions to mainline, it could also be
>> just merged into it?
>
> On second thought, need to hold on this. I forgot that due my use
> of "dynamic_cast" operator, the code fails to compile into kernel
> module. Thus, including it in mainline as is, would break kernel
> module build, if ipsec is included...
>
> _______________________________________________
> click mailing list
> [email protected]
> https://amsterdam.lcs.mit.edu/mailman/listinfo/click