src/dpdk/drivers/net/sfc/sfc_mae.c
int
sfc_mae_flow_verify(struct sfc_adapter *sa,
		    struct rte_flow *flow)
{
	struct sfc_flow_spec *spec = &flow->spec;
	struct sfc_flow_spec_mae *spec_mae = &spec->mae;
	struct sfc_mae_outer_rule *outer_rule = spec_mae->outer_rule;
	int rc;

	SFC_ASSERT(sfc_adapter_is_locked(sa));

	if (sa->state != SFC_ADAPTER_STARTED)
		return EAGAIN;

	if (outer_rule != NULL) {
		rc = sfc_mae_outer_rule_class_verify(sa, outer_rule);
		if (rc != 0)
			return rc;
	}

	return sfc_mae_action_rule_class_verify(sa, spec_mae);
}
/**
 * Confirm that a given flow can be accepted by the FW.
 *
 * @param sa
 *   Software adapter context
 * @param flow
 *   Flow to be verified
 * @return
 *   Zero on success and non-zero in the case of error.
 *   A special value of EAGAIN indicates that the adapter is
 *   not in started state. This state is compulsory because
 *   it only makes sense to compare the rule class of the flow
 *   being validated with classes of the active rules.
 *   Such classes are wittingly supported by the FW.
 */
Confirm that a given flow can be accepted by the FW.
@param sa
Software adapter context
@param flow
Flow to be verified
@return
Zero on success and non-zero in the case of error.
A special value of EAGAIN indicates that the adapter is
not in started state. This state is compulsory because
it only makes sense to compare the rule class of the flow
being validated with classes of the active rules.
Such classes are wittingly supported by the FW.
Confirm that a given flow can be accepted by the FW . @param sa Software adapter context @param flow Flow to be verified @return Zero on success and non - zero in the case of error . A special value of EAGAIN indicates that the adapter is not in started state . This state is compulsory because it only makes sense to compare the rule class of the flow being validated with classes of the active rules . Such classes are wittingly supported by the FW .
int
sfc_mae_flow_verify(struct sfc_adapter *sa,
		    struct rte_flow *flow)
{
	struct sfc_flow_spec *spec = &flow->spec;
	struct sfc_flow_spec_mae *spec_mae = &spec->mae;
	struct sfc_mae_outer_rule *outer_rule = spec_mae->outer_rule;
	int rc;
	SFC_ASSERT(sfc_adapter_is_locked(sa));
	if (sa->state != SFC_ADAPTER_STARTED)
		return EAGAIN;
	if (outer_rule != NULL) {
		rc = sfc_mae_outer_rule_class_verify(sa, outer_rule);
		if (rc != 0)
			return rc;
	}
	return sfc_mae_action_rule_class_verify(sa, spec_mae);
}
int sfc_mae_flow_verify ( struct sfc_adapter * sa , struct rte_flow * flow ) { struct sfc_flow_spec * spec = & flow -> spec ; struct sfc_flow_spec_mae * spec_mae = & spec -> mae ; struct sfc_mae_outer_rule * outer_rule = spec_mae -> outer_rule ; int rc ; SFC_ASSERT ( sfc_adapter_is_locked ( sa ) ) ; if ( sa -> state != SFC_ADAPTER_STARTED ) return EAGAIN ; if ( outer_rule != NULL ) { rc = sfc_mae_outer_rule_class_verify ( sa , outer_rule ) ; if ( rc != 0 ) return rc ; } return sfc_mae_action_rule_class_verify ( sa , spec_mae ) ; }
Confirm that a given flow can be accepted by the FW.
Confirm that a given flow can be accepted by the FW .