Re: [ULOGD2 PATCH 2/4] Add parsing module for raw.mac.

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

 



Eric Leblond wrote:
> This patch adds a module named RAWMAC which is in charge of parsing the
> hardware header to extract source and destination hardware address.

I think that this should be merged with MAC2STR, can you see any other
potential user of this information apart from the string converter?
Also, it would be nice to rename it to HW2STR instead.

Minor glitch below:

> +static int parse_rawmac(struct ulogd_key *ret, struct ulogd_key *inp, int type)
> +{
> +	switch (type) {
> +		case ARPHRD_ETHER:
> +			return parse_ethernet(ret, inp);
> +		default:
> +			ulogd_log(ULOGD_NOTICE, "Unsupported hardware type (%d), "
> +				  "unable to parse.\n", GET_VALUE(ret, KEY_RAW_TYPE).ui16);

This can generate lots of log messages. I prefer to remove this and
document that only ethernet is supported at the moment.

-- 
"Los honestos son inadaptados sociales" -- Les Luthiers
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux