X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=lib%2Flibrte_ethdev%2Fethdev_private.h;h=7b787bf97f0372269f2403dc2a22446081d0dd24;hb=76211f7c4a9925aff3455efd327c942f893d726c;hp=0f5c6d5c45ea0ed3dfd77cdb44673f6338e4290e;hpb=600ce805363601104cf7678eaf30fa409226996a;p=dpdk.git diff --git a/lib/librte_ethdev/ethdev_private.h b/lib/librte_ethdev/ethdev_private.h index 0f5c6d5c45..7b787bf97f 100644 --- a/lib/librte_ethdev/ethdev_private.h +++ b/lib/librte_ethdev/ethdev_private.h @@ -11,6 +11,12 @@ extern "C" { #endif +/* + * Convert rte_eth_dev pointer to port id. + * NULL will be translated to RTE_MAX_ETHPORTS. + */ +uint16_t eth_dev_to_id(const struct rte_eth_dev *dev); + /* Generic rte_eth_dev comparison function. */ typedef int (*rte_eth_cmp_t)(const struct rte_eth_dev *, const void *); @@ -19,6 +25,12 @@ struct rte_eth_dev * eth_find_device(const struct rte_eth_dev *_start, rte_eth_cmp_t cmp, const void *data); +/* Parse devargs value for representor parameter. */ +typedef int (*rte_eth_devargs_callback_t)(char *str, void *data); +int rte_eth_devargs_parse_list(char *str, rte_eth_devargs_callback_t callback, + void *data); +int rte_eth_devargs_parse_representor_ports(char *str, void *data); + #ifdef __cplusplus } #endif