Jan Engelhardt wrote:
On Thursday 2008-04-03 13:59, Patrick McHardy wrote:
Jan Engelhardt wrote:
For coming Xtables patches, we want to use AF_UNSPEC, but NF_ARP
currently evaluates to the same value so it gets changed.
--- a/include/linux/socket.h
+++ b/include/linux/socket.h
@@ -179,6 +179,7 @@ struct ucred {
#define AF_ASH 18 /* Ash */
#define AF_ECONET 19 /* Acorn Econet */
#define AF_ATMSVC 20 /* ATM SVCs */
+#define AF_ARP 21 /* Address Resolution for IPv4 */
Did you make sure this value wasn't ever used by something else?
There are no traces of 21 in the entire history [/nico/archive.git,
/tglx/history.git].
Is this used by userspace? If not, why change it?
Change, because NF_ARP is used to wrongly index into xt_afinfo -- it
overlaps with PF_UNSPEC. Since NF_ARP is only used very internally in
the kernel, it can be changed. To avoid problems, PF_ARP gets a
proper slot.
I don't like exporting this since, as you say, userspace doesn't
need it and arp isn't an address family. I would suggest to
just define something kernel-internally that doesn't clash,
like using AF_MAX + X as base.
--
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