DEPDIRS-librte_ethdev += librte_mbuf
DEPDIRS-librte_ethdev += librte_kvargs
DEPDIRS-librte_ethdev += librte_cmdline
+DEPDIRS-librte_ethdev += librte_meter
DIRS-$(CONFIG_RTE_LIBRTE_BBDEV) += librte_bbdev
DEPDIRS-librte_bbdev := librte_eal librte_mempool librte_mbuf
DIRS-$(CONFIG_RTE_LIBRTE_CRYPTODEV) += librte_cryptodev
CFLAGS += -O3
CFLAGS += $(WERROR_FLAGS)
LDLIBS += -lrte_net -lrte_eal -lrte_mempool -lrte_ring
-LDLIBS += -lrte_mbuf -lrte_kvargs -lrte_cmdline
+LDLIBS += -lrte_mbuf -lrte_kvargs -lrte_cmdline -lrte_meter
EXPORT_MAP := rte_ethdev_version.map
'rte_tm.h',
'rte_tm_driver.h')
-deps += ['net', 'kvargs', 'cmdline']
+deps += ['net', 'kvargs', 'cmdline', 'meter']
#include <stdint.h>
#include <rte_compat.h>
#include <rte_common.h>
+#include <rte_meter.h>
#ifdef __cplusplus
extern "C" {
#endif
-/**
- * Color
- */
-enum rte_mtr_color {
- RTE_MTR_GREEN = 0, /**< Green */
- RTE_MTR_YELLOW, /**< Yellow */
- RTE_MTR_RED, /**< Red */
- RTE_MTR_COLORS /**< Number of colors. */
-};
+/* New rte_color is defined and used to deprecate rte_mtr_color soon. */
+#define rte_mtr_color rte_color
+#define RTE_MTR_GREEN RTE_COLOR_GREEN
+#define RTE_MTR_YELLOW RTE_COLOR_YELLOW
+#define RTE_MTR_RED RTE_COLOR_RED
+#define RTE_MTR_COLORS RTE_COLORS
/**
* Statistics counter type
#include <stdint.h>
#include <rte_common.h>
+#include <rte_meter.h>
#ifdef __cplusplus
extern "C" {
*/
#define RTE_TM_NODE_LEVEL_ID_ANY UINT32_MAX
-/**
- * Color
- */
-enum rte_tm_color {
- RTE_TM_GREEN = 0, /**< Green */
- RTE_TM_YELLOW, /**< Yellow */
- RTE_TM_RED, /**< Red */
- RTE_TM_COLORS /**< Number of colors */
-};
+/* New rte_color is defined and used to deprecate rte_tm_color soon. */
+#define rte_tm_color rte_color
+#define RTE_TM_GREEN RTE_COLOR_GREEN
+#define RTE_TM_YELLOW RTE_COLOR_YELLOW
+#define RTE_TM_RED RTE_COLOR_RED
+#define RTE_TM_COLORS RTE_COLORS
/**
* Node statistics counter type
*
***/
-/** Packet Color Set */
-enum rte_meter_color {
- e_RTE_METER_GREEN = 0, /**< Green */
- e_RTE_METER_YELLOW, /**< Yellow */
- e_RTE_METER_RED, /**< Red */
- e_RTE_METER_COLORS /**< Number of available colors */
+/**
+ * Color
+ */
+enum rte_color {
+ RTE_COLOR_GREEN = 0, /**< Green */
+ RTE_COLOR_YELLOW, /**< Yellow */
+ RTE_COLOR_RED, /**< Red */
+ RTE_COLORS /**< Number of colors */
};
+/* New rte_color is defined and used to deprecate rte_meter_color soon. */
+#define rte_meter_color rte_color
+#define e_RTE_METER_GREEN RTE_COLOR_GREEN
+#define e_RTE_METER_YELLOW RTE_COLOR_YELLOW
+#define e_RTE_METER_RED RTE_COLOR_RED
+#define e_RTE_METER_COLORS RTE_COLORS
+
/** srTCM parameters per metered traffic flow. The CIR, CBS and EBS parameters only
count bytes of IP packets and do not include link specific headers. At least one of
the CBS or EBS parameters has to be greater than zero. */
libraries = [ 'compat', # just a header, used for versioning
'cmdline', # ethdev depends on cmdline for parsing functions
'kvargs', # eal depends on kvargs
- 'eal', 'ring', 'mempool', 'mbuf', 'net', 'ethdev', 'pci', # core
+ 'eal', 'ring', 'mempool', 'mbuf', 'net', 'meter', 'ethdev', 'pci', # core
'metrics', # bitrate/latency stats depends on this
'hash', # efd depends on this
'timer', # eventdev depends on this
'distributor', 'efd', 'eventdev',
'gro', 'gso', 'ip_frag', 'jobstats',
'kni', 'latencystats', 'lpm', 'member',
- 'meter', 'power', 'pdump', 'rawdev',
+ 'power', 'pdump', 'rawdev',
'reorder', 'sched', 'security', 'vhost',
# add pkt framework libs which use other libs from above
'port', 'table', 'pipeline',