MPLS support for DragonFly

Nuno Antunes nuno.antunes at gmail.com
Wed Jul 2 01:28:53 PDT 2008


On Wed, Jul 2, 2008 at 9:42 AM, Jeffrey Hsu <hsu at freebsd.org> wrote:
> I like it.  Some comments:
>
> 1. rt_setshim() should be static.
>
> 2. Make that rt_setshims(rt, rtinfo->rt_info) to simplify the calling
> interface.
>
> 3. Remove all the null checks in rt_setshims(), because it's only called
> from one place and after a bzero().
>
> 3. There's an extra newline at the end of sbin/route.c.
>
> 4. Don't need MPLS config file.  Just add to LINT config file.
>
> 5. What's the multiplexing strategy in terms of distributing work
> and avoiding locking by using per-cpu data structures?
>
> 6. Instead of a separate mpls_output(), can you factor out the MPLS
> output process from the call to the underlying interface, as in
> something like
>
> #ifdef MPLS
>  struct rtentry *send_route = ro->ro_rt;       /* copy-in/copy-out parameter */
>
>  if (!mpls_output_process(ifp, m, &dst, &send_route))
>        goto done;
> #endif
>
>  error = ifp->if_output(ifp, m, (struct sockaddr *)dst, send_route);
>
>  /*
>   * Returns FALSE if no further output processing required.
>   */
>  bool_t
>  mpls_output_process()
>  {
>
>        if (!(send_route->rt_flags & RTF_MPLSOPS))
>                return TRUE;
>
>        do MPLS processing
>        return FALSE if stack empty or on mpls_push() or mpls_swap() error
>
>        return TRUE;
>  }
>

Wow, so many feedback from everyone, great! I'll have to address this
after work later today. But with regards to the kernel config file,
that got in the patch inadvertently, i don't intend to commit it.

Thanks
nuno





More information about the Submit mailing list