-#define foreach_cryptodev_status \
- _(SUCCESS, "success") \
- _(NOT_PROCESSED, "not processed") \
- _(AUTH_FAILED, "auth failed") \
- _(INVALID_SESSION, "invalid session") \
- _(INVALID_ARGS, "invalid arguments") \
- _(ERROR, "error")
-
-static u8 *
-format_cryptodev_status (u8 * s, va_list * args)
-{
- u32 status = va_arg (*args, u32);
- char *str = 0;
-
- switch (status)
- {
-#define _(x, z) case RTE_CRYPTO_OP_STATUS_##x: str = z; break;
- foreach_cryptodev_status
-#undef _
- }
- s = format (s, "%s", str);
-
- return s;
-}
-