MCPcopy Create free account
hub / github.com/F-Stack/f-stack / rte_mtr_error_set

Function rte_mtr_error_set

dpdk/lib/ethdev/rte_mtr_driver.h:237–253  ·  view source on GitHub ↗

* Initialize generic error structure. * * This function also sets rte_errno to a given value. * * @param[out] error * Pointer to error structure (may be NULL). * @param[in] code * Related error code (rte_errno). * @param[in] type * Cause field and error type. * @param[in] cause * Object responsible for the error. * @param[in] message * Human-readable error message. * * @re

Source from the content-addressed store, hash-verified

235 * Error code.
236 */
237static inline int
238rte_mtr_error_set(struct rte_mtr_error *error,
239 int code,
240 enum rte_mtr_error_type type,
241 const void *cause,
242 const char *message)
243{
244 if (error) {
245 *error = (struct rte_mtr_error){
246 .type = type,
247 .cause = cause,
248 .message = message,
249 };
250 }
251 rte_errno = code;
252 return code;
253}
254
255/**
256 * Get generic traffic metering and policing operations structure from a port

Callers 15

rte_mtr_ops_getFunction · 0.85
nfp_mtr_cap_getFunction · 0.85
nfp_mtr_profile_validateFunction · 0.85
nfp_mtr_profile_insertFunction · 0.85
nfp_mtr_profile_modFunction · 0.85
nfp_mtr_profile_deleteFunction · 0.85
nfp_mtr_policy_validateFunction · 0.85
nfp_mtr_policy_addFunction · 0.85
nfp_mtr_policy_deleteFunction · 0.85
nfp_mtr_validateFunction · 0.85
nfp_mtr_createFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected