flow: Record the pifs for each side of each flow
Currently we have no generic information flows apart from the type and state, everything else is specific to the flow type. Start introducing generic flow information by recording the pifs which the flow connects. To keep track of what information is valid, introduce new flow states: INI for when the initiating side information is complete, and TGT for when both sides information is complete, but we haven't chosen the flow type yet. For now, these states don't do an awful lot, but they'll become more important as we add more generic information. Signed-off-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
This commit is contained in:

committed by
Stefano Brivio

parent
43571852e6
commit
8a2accb847
@@ -107,6 +107,9 @@ static inline flow_sidx_t flow_sidx(const struct flow_common *f,
|
||||
union flow *flow_alloc(void);
|
||||
void flow_alloc_cancel(union flow *flow);
|
||||
|
||||
void flow_initiate(union flow *flow, uint8_t pif);
|
||||
void flow_target(union flow *flow, uint8_t pif);
|
||||
|
||||
union flow *flow_set_type(union flow *flow, enum flow_type type);
|
||||
#define FLOW_SET_TYPE(flow_, t_, var_) (&flow_set_type((flow_), (t_))->var_)
|
||||
|
||||
|
Reference in New Issue
Block a user