cvs commit: src/sbin/ifconfig iftrunk.c src/share/man/man4
trunk.4 src/sys/net ieee8023ad_lacp.c ieee8023ad_lacp.h if.c
if_ethersubr.c if_trunk.c if_trunk.h if_var.h src/sys/sys priv.h
Gleb Smirnoff
glebius at FreeBSD.org
Tue Apr 10 08:31:33 UTC 2007
Andrew and others,
what do you think about using a flags fielf + union field for
different kinds of glue? I mean that if_vlantrunk, if_trunk, if_bridge
and may be some future glues are mutually exclusive.
If we put them under one union and add an integer field that identifies
what is stored in the union, then we will:
1) keep the structure smaller
2) structure won't grow in future, when adding more glues
3) easier to avoid bugs like attaching to bridge and vlan trunk
simultaneously
diff -u src/sys/net/if_var.h:1.112 src/sys/net/if_var.h:1.113
--- src/sys/net/if_var.h:1.112 Tue Mar 20 03:15:43 2007
+++ src/sys/net/if_var.h Tue Apr 10 00:27:25 2007
@@ -186,6 +186,7 @@
TAILQ_HEAD(, ifg_list) if_groups; /* linked list of groups per if */
/* protected by if_addr_mtx */
void *if_pf_kif;
+ void *if_trunk; /* trunk glue */
};
typedef void if_init_f_t(void *);
--
Totus tuus, Glebius.
GLEBIUS-RIPN GLEB-RIPE
More information about the cvs-src
mailing list