#define _ULP_UTILS_H_
#include "bnxt.h"
-#include "ulp_template_db.h"
+#include "ulp_template_db_enum.h"
/*
* Macros for bitmap sets and gets
#define ULP_BITS_2_BYTE_NR(bits_x) ((bits_x) / 8)
/* Macros to read the computed fields */
-#define ULP_UTIL_CHF_IDX_RD(params, idx) \
+#define ULP_COMP_FLD_IDX_RD(params, idx) \
rte_be_to_cpu_32((params)->comp_fld[(idx)])
-#define ULP_UTIL_CHF_IDX_WR(params, idx, val) \
+#define ULP_COMP_FLD_IDX_WR(params, idx, val) \
((params)->comp_fld[(idx)] = rte_cpu_to_be_32((val)))
/*
* Making the blob statically sized to 128 bytes for now.
*
* datalen [in] The number of bits of pad to add
*
- * returns the number of pad bits added, zero on failure
+ * returns the number of pad bits added, -1 on failure
*/
-uint32_t
+int32_t
ulp_blob_pad_push(struct ulp_blob *blob,
uint32_t datalen);
void
ulp_blob_perform_encap_swap(struct ulp_blob *blob);
+/*
+ * Perform the blob buffer reversal byte wise.
+ * This api makes the first byte the last and
+ * vice-versa.
+ *
+ * blob [in] The blob's data to be used for swap.
+ *
+ * returns void.
+ */
+void
+ulp_blob_perform_byte_reverse(struct ulp_blob *blob);
+
/*
* Read data from the operand
*