Elise Lennion <[email protected]> wrote:
> Because a linear search is used, which is slower.
> 
> This approach demands that the symbol_table have a variable with its
> size, also, it must be sorted by value.

Did Pablo put you up to this?  Bad Pablo, bad!  :-P

because:

>  static const struct symbol_table ethertype_tbl = {
> +     .size           = 4,
>       .symbols        = {
>               SYMBOL("ip",            __constant_htons(ETH_P_IP)),
> +             SYMBOL("vlan",          __constant_htons(ETH_P_8021Q)),
>               SYMBOL("arp",           __constant_htons(ETH_P_ARP)),
>               SYMBOL("ip6",           __constant_htons(ETH_P_IPV6)),
> -             SYMBOL("vlan",          __constant_htons(ETH_P_8021Q)),
>               SYMBOL_LIST_END
>       },

This is unmaintanable.  I have no clue what value ETH_P_8021Q is, and that
this has to be placed at spot #2 to not break things.
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to