tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Patch: accept filters for NetBSD



General, I don't think we should get new code using MALLOC/FREE.

> --- /workspaces/vendor/nbsrc/sys/conf/files   2008-01-09 14:44:14.000000000 
> -0500
> +++ sys/conf/files    2008-01-28 16:01:14.000000000 -0500
>  include "dev/pad/files.pad"
> +# Coyote Point Equalizer
> +#
> +include "l7lb/files.EQ"

I don't think you want to commit this.

> --- /workspaces/vendor/nbsrc/sys/kern/uipc_socket.c   2008-01-09 
> 14:44:39.000000000 -0500
> +++ sys/kern/uipc_socket.c    2008-01-28 16:01:30.000000000 -0500
> @@ -70,6 +70,7 @@
>  #include <sys/cdefs.h>
>  __KERNEL_RCSID(0, "$NetBSD: uipc_socket.c,v 1.149 2007/12/05 17:19:59 pooka 
> Exp $");
>  
> +#include "opt_inet.h"
>  #include "opt_sock_counters.h"
>  #include "opt_sosend_loan.h"
>  #include "opt_mbuftrace.h"
> @@ -625,6 +626,11 @@
>       sorflush(so);
>       seldestroy(&so->so_rcv.sb_sel);
>       seldestroy(&so->so_snd.sb_sel);
> +#ifdef INET
> +     /* remove acccept filter if one is present. */
> +     if (so->so_accf != NULL)
> +             do_setopt_accept_filter(so, NULL);
> +#endif

What about inet6? I would like to not see new v4-only options, if
there's no good reason for it. Same for the rest.

Would it be useful to add explicit sizes for filter length and argument
length?

Joerg



Home | Main Index | Thread Index | Old Index