numam-dpdk/lib/librte_table/rte_table_array.h
Bruce Richardson 369991d997 lib: use SPDX tag for Intel copyright files
Replace the BSD license header with the SPDX tag for files
with only an Intel copyright on them.

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
2018-01-04 22:41:39 +01:00

48 lines
858 B
C

/* SPDX-License-Identifier: BSD-3-Clause
* Copyright(c) 2010-2014 Intel Corporation
*/
#ifndef __INCLUDE_RTE_TABLE_ARRAY_H__
#define __INCLUDE_RTE_TABLE_ARRAY_H__
#ifdef __cplusplus
extern "C" {
#endif
/**
* @file
* RTE Table Array
*
* Simple array indexing. Lookup key is the array entry index.
*
***/
#include <stdint.h>
#include "rte_table.h"
/** Array table parameters */
struct rte_table_array_params {
/** Number of array entries. Has to be a power of two. */
uint32_t n_entries;
/** Byte offset within input packet meta-data where lookup key (i.e. the
array entry index) is located. */
uint32_t offset;
};
/** Array table key format */
struct rte_table_array_key {
/** Array entry index */
uint32_t pos;
};
/** Array table operations */
extern struct rte_table_ops rte_table_array_ops;
#ifdef __cplusplus
}
#endif
#endif