Looks good to me, /* A MAC learning table entry. > - * Guarded by owning 'mac_learning''s rwlock */ > + * Guarded by owning 'mac_learning''s rwlock. */ > struct mac_entry { > struct hmap_node hmap_node; /* Node in a mac_learning hmap. */ > time_t expires; /* Expiration time. */ > @@ -47,14 +108,30 @@ struct mac_entry { > uint16_t vlan; /* VLAN tag. */ > > /* The following are marked guarded to prevent users from iterating > over or > - * accessing a mac_entry without hodling the parent mac_learning > rwlock. */ > + * accessing a mac_entry without holding the parent mac_learning > rwlock. */ > struct ovs_list lru_node OVS_GUARDED; /* Element in 'lrus' list. */ > > - /* Learned port. */ > - union { > - void *p; > - ofp_port_t ofp_port; > - } port OVS_GUARDED; > + /* Learned port. > + * > + * The client-specified data is mlport->port. */ > + struct mac_learning_port *mlport; >
Simple C question, why don't we need to forward declare the struct 'mac_learning_port'? _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev