" Flush (default) or don't flush RX streams before"
" forwarding. Mainly used with PCAP drivers.\n\n"
- #ifdef RTE_NIC_BYPASS
"set bypass mode (normal|bypass|isolate) (port_id)\n"
" Set the bypass mode for the lowest port on bypass enabled"
" NIC.\n\n"
"show bypass config (port_id)\n"
" Show the bypass configuration for a bypass enabled NIC"
" using the lowest port on the NIC.\n\n"
-#endif
+
#ifdef RTE_LIBRTE_PMD_BOND
"create bonded device (mode) (socket)\n"
" Create a new bonded device with specific bonding mode and socket.\n\n"
},
};
-#ifdef RTE_NIC_BYPASS
/* *** SET NIC BYPASS MODE *** */
struct cmd_set_bypass_mode_result {
cmdline_fixed_string_t set;
{
struct cmd_set_bypass_mode_result *res = parsed_result;
portid_t port_id = res->port_id;
- uint32_t bypass_mode = RTE_BYPASS_MODE_NORMAL;
+ int32_t rc = -EINVAL;
+
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
+ uint32_t bypass_mode = RTE_PMD_IXGBE_BYPASS_MODE_NORMAL;
if (!strcmp(res->value, "bypass"))
- bypass_mode = RTE_BYPASS_MODE_BYPASS;
+ bypass_mode = RTE_PMD_IXGBE_BYPASS_MODE_BYPASS;
else if (!strcmp(res->value, "isolate"))
- bypass_mode = RTE_BYPASS_MODE_ISOLATE;
+ bypass_mode = RTE_PMD_IXGBE_BYPASS_MODE_ISOLATE;
else
- bypass_mode = RTE_BYPASS_MODE_NORMAL;
+ bypass_mode = RTE_PMD_IXGBE_BYPASS_MODE_NORMAL;
/* Set the bypass mode for the relevant port. */
- if (0 != rte_eth_dev_bypass_state_set(port_id, &bypass_mode)) {
+ rc = rte_pmd_ixgbe_bypass_state_set(port_id, &bypass_mode);
+#endif
+ if (rc != 0)
printf("\t Failed to set bypass mode for port = %d.\n", port_id);
- }
}
cmdline_parse_token_string_t cmd_setbypass_mode_set =
__attribute__((unused)) struct cmdline *cl,
__attribute__((unused)) void *data)
{
- int32_t rc;
+ int32_t rc = -EINVAL;
struct cmd_set_bypass_event_result *res = parsed_result;
portid_t port_id = res->port_id;
- uint32_t bypass_event = RTE_BYPASS_EVENT_NONE;
- uint32_t bypass_mode = RTE_BYPASS_MODE_NORMAL;
+
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
+ uint32_t bypass_event = RTE_PMD_IXGBE_BYPASS_EVENT_NONE;
+ uint32_t bypass_mode = RTE_PMD_IXGBE_BYPASS_MODE_NORMAL;
if (!strcmp(res->event_value, "timeout"))
- bypass_event = RTE_BYPASS_EVENT_TIMEOUT;
+ bypass_event = RTE_PMD_IXGBE_BYPASS_EVENT_TIMEOUT;
else if (!strcmp(res->event_value, "os_on"))
- bypass_event = RTE_BYPASS_EVENT_OS_ON;
+ bypass_event = RTE_PMD_IXGBE_BYPASS_EVENT_OS_ON;
else if (!strcmp(res->event_value, "os_off"))
- bypass_event = RTE_BYPASS_EVENT_OS_OFF;
+ bypass_event = RTE_PMD_IXGBE_BYPASS_EVENT_OS_OFF;
else if (!strcmp(res->event_value, "power_on"))
- bypass_event = RTE_BYPASS_EVENT_POWER_ON;
+ bypass_event = RTE_PMD_IXGBE_BYPASS_EVENT_POWER_ON;
else if (!strcmp(res->event_value, "power_off"))
- bypass_event = RTE_BYPASS_EVENT_POWER_OFF;
+ bypass_event = RTE_PMD_IXGBE_BYPASS_EVENT_POWER_OFF;
else
- bypass_event = RTE_BYPASS_EVENT_NONE;
+ bypass_event = RTE_PMD_IXGBE_BYPASS_EVENT_NONE;
if (!strcmp(res->mode_value, "bypass"))
- bypass_mode = RTE_BYPASS_MODE_BYPASS;
+ bypass_mode = RTE_PMD_IXGBE_BYPASS_MODE_BYPASS;
else if (!strcmp(res->mode_value, "isolate"))
- bypass_mode = RTE_BYPASS_MODE_ISOLATE;
+ bypass_mode = RTE_PMD_IXGBE_BYPASS_MODE_ISOLATE;
else
- bypass_mode = RTE_BYPASS_MODE_NORMAL;
+ bypass_mode = RTE_PMD_IXGBE_BYPASS_MODE_NORMAL;
/* Set the watchdog timeout. */
- if (bypass_event == RTE_BYPASS_EVENT_TIMEOUT) {
+ if (bypass_event == RTE_PMD_IXGBE_BYPASS_EVENT_TIMEOUT) {
rc = -EINVAL;
- if (!RTE_BYPASS_TMT_VALID(bypass_timeout) ||
- (rc = rte_eth_dev_wd_timeout_store(port_id,
- bypass_timeout)) != 0) {
+ if (RTE_PMD_IXGBE_BYPASS_TMT_VALID(bypass_timeout)) {
+ rc = rte_pmd_ixgbe_bypass_wd_timeout_store(port_id,
+ bypass_timeout);
+ }
+ if (rc != 0) {
printf("Failed to set timeout value %u "
- "for port %d, errto code: %d.\n",
- bypass_timeout, port_id, rc);
+ "for port %d, errto code: %d.\n",
+ bypass_timeout, port_id, rc);
}
}
/* Set the bypass event to transition to bypass mode. */
- if (0 != rte_eth_dev_bypass_event_store(port_id,
- bypass_event, bypass_mode)) {
- printf("\t Failed to set bypass event for port = %d.\n", port_id);
- }
+ rc = rte_pmd_ixgbe_bypass_event_store(port_id, bypass_event,
+ bypass_mode);
+#endif
+ if (rc != 0)
+ printf("\t Failed to set bypass event for port = %d.\n",
+ port_id);
}
cmdline_parse_token_string_t cmd_setbypass_event_set =
__attribute__((unused)) struct cmdline *cl,
__attribute__((unused)) void *data)
{
- struct cmd_set_bypass_timeout_result *res = parsed_result;
+ __rte_unused struct cmd_set_bypass_timeout_result *res = parsed_result;
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
if (!strcmp(res->value, "1.5"))
- bypass_timeout = RTE_BYPASS_TMT_1_5_SEC;
+ bypass_timeout = RTE_PMD_IXGBE_BYPASS_TMT_1_5_SEC;
else if (!strcmp(res->value, "2"))
- bypass_timeout = RTE_BYPASS_TMT_2_SEC;
+ bypass_timeout = RTE_PMD_IXGBE_BYPASS_TMT_2_SEC;
else if (!strcmp(res->value, "3"))
- bypass_timeout = RTE_BYPASS_TMT_3_SEC;
+ bypass_timeout = RTE_PMD_IXGBE_BYPASS_TMT_3_SEC;
else if (!strcmp(res->value, "4"))
- bypass_timeout = RTE_BYPASS_TMT_4_SEC;
+ bypass_timeout = RTE_PMD_IXGBE_BYPASS_TMT_4_SEC;
else if (!strcmp(res->value, "8"))
- bypass_timeout = RTE_BYPASS_TMT_8_SEC;
+ bypass_timeout = RTE_PMD_IXGBE_BYPASS_TMT_8_SEC;
else if (!strcmp(res->value, "16"))
- bypass_timeout = RTE_BYPASS_TMT_16_SEC;
+ bypass_timeout = RTE_PMD_IXGBE_BYPASS_TMT_16_SEC;
else if (!strcmp(res->value, "32"))
- bypass_timeout = RTE_BYPASS_TMT_32_SEC;
+ bypass_timeout = RTE_PMD_IXGBE_BYPASS_TMT_32_SEC;
else
- bypass_timeout = RTE_BYPASS_TMT_OFF;
+ bypass_timeout = RTE_PMD_IXGBE_BYPASS_TMT_OFF;
+#endif
}
cmdline_parse_token_string_t cmd_setbypass_timeout_set =
__attribute__((unused)) void *data)
{
struct cmd_show_bypass_config_result *res = parsed_result;
+ portid_t port_id = res->port_id;
+ int rc = -EINVAL;
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
uint32_t event_mode;
uint32_t bypass_mode;
- portid_t port_id = res->port_id;
uint32_t timeout = bypass_timeout;
int i;
- static const char * const timeouts[RTE_BYPASS_TMT_NUM] =
+ static const char * const timeouts[RTE_PMD_IXGBE_BYPASS_TMT_NUM] =
{"off", "1.5", "2", "3", "4", "8", "16", "32"};
- static const char * const modes[RTE_BYPASS_MODE_NUM] =
+ static const char * const modes[RTE_PMD_IXGBE_BYPASS_MODE_NUM] =
{"UNKNOWN", "normal", "bypass", "isolate"};
- static const char * const events[RTE_BYPASS_EVENT_NUM] = {
+ static const char * const events[RTE_PMD_IXGBE_BYPASS_EVENT_NUM] = {
"NONE",
"OS/board on",
"power supply on",
int num_events = (sizeof events) / (sizeof events[0]);
/* Display the bypass mode.*/
- if (0 != rte_eth_dev_bypass_state_show(port_id, &bypass_mode)) {
+ if (rte_pmd_ixgbe_bypass_state_show(port_id, &bypass_mode) != 0) {
printf("\tFailed to get bypass mode for port = %d\n", port_id);
return;
}
else {
- if (!RTE_BYPASS_MODE_VALID(bypass_mode))
- bypass_mode = RTE_BYPASS_MODE_NONE;
+ if (!RTE_PMD_IXGBE_BYPASS_MODE_VALID(bypass_mode))
+ bypass_mode = RTE_PMD_IXGBE_BYPASS_MODE_NONE;
printf("\tbypass mode = %s\n", modes[bypass_mode]);
}
/* Display the bypass timeout.*/
- if (!RTE_BYPASS_TMT_VALID(timeout))
- timeout = RTE_BYPASS_TMT_OFF;
+ if (!RTE_PMD_IXGBE_BYPASS_TMT_VALID(timeout))
+ timeout = RTE_PMD_IXGBE_BYPASS_TMT_OFF;
printf("\tbypass timeout = %s\n", timeouts[timeout]);
/* Display the bypass events and associated modes. */
- for (i = RTE_BYPASS_EVENT_START; i < num_events; i++) {
+ for (i = RTE_PMD_IXGBE_BYPASS_EVENT_START; i < num_events; i++) {
- if (0 != rte_eth_dev_bypass_event_show(port_id, i, &event_mode)) {
+ if (rte_pmd_ixgbe_bypass_event_show(port_id, i, &event_mode)) {
printf("\tFailed to get bypass mode for event = %s\n",
events[i]);
} else {
- if (!RTE_BYPASS_MODE_VALID(event_mode))
- event_mode = RTE_BYPASS_MODE_NONE;
+ if (!RTE_PMD_IXGBE_BYPASS_MODE_VALID(event_mode))
+ event_mode = RTE_PMD_IXGBE_BYPASS_MODE_NONE;
printf("\tbypass event: %-16s = %s\n", events[i],
modes[event_mode]);
}
}
+#endif
+ if (rc != 0)
+ printf("\tFailed to get bypass configuration for port = %d\n",
+ port_id);
}
cmdline_parse_token_string_t cmd_showbypass_config_show =
NULL,
},
};
-#endif
#ifdef RTE_LIBRTE_PMD_BOND
/* *** SET BONDING MODE *** */
(cmdline_parse_inst_t *)&cmd_set_allmulti_mode_all,
(cmdline_parse_inst_t *)&cmd_set_flush_rx,
(cmdline_parse_inst_t *)&cmd_set_link_check,
-#ifdef RTE_NIC_BYPASS
(cmdline_parse_inst_t *)&cmd_set_bypass_mode,
(cmdline_parse_inst_t *)&cmd_set_bypass_event,
(cmdline_parse_inst_t *)&cmd_set_bypass_timeout,
(cmdline_parse_inst_t *)&cmd_show_bypass_config,
-#endif
#ifdef RTE_LIBRTE_PMD_BOND
(cmdline_parse_inst_t *) &cmd_set_bonding_mode,
(cmdline_parse_inst_t *) &cmd_show_bonding_config,
#include <rte_ethdev.h>
#include <rte_dev.h>
#include <rte_string_fns.h>
+#ifdef RTE_LIBRTE_IXGBE_PMD
+#include <rte_pmd_ixgbe.h>
+#endif
#ifdef RTE_LIBRTE_PMD_XENVIRT
#include <rte_eth_xenvirt.h>
#endif
/*
* NIC bypass mode configuration options.
*/
-#ifdef RTE_NIC_BYPASS
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
/* The NIC bypass watchdog timeout. */
-uint32_t bypass_timeout = RTE_BYPASS_TMT_OFF;
-
+uint32_t bypass_timeout = RTE_PMD_IXGBE_BYPASS_TMT_OFF;
#endif
+
#ifdef RTE_LIBRTE_LATENCY_STATS
/*
rte_eth_macaddr_get(pid, &port->eth_addr);
map_port_queue_stats_mapping_registers(pid, port);
-#ifdef RTE_NIC_BYPASS
- rte_eth_dev_bypass_init(pid);
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
+ rte_pmd_ixgbe_bypass_init(pid);
#endif
if (lsc_interrupt &&
extern uint32_t event_print_mask;
/**< set by "--print-event xxxx" and "--mask-event xxxx parameters */
-#ifdef RTE_NIC_BYPASS
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
extern uint32_t bypass_timeout; /**< Store the NIC bypass watchdog timeout */
#endif
#
CONFIG_RTE_ETHDEV_TX_PREPARE_NOOP=n
-#
-# Support NIC bypass logic
-#
-CONFIG_RTE_NIC_BYPASS=n
-
#
# Compile burst-oriented Amazon ENA PMD driver
#
CONFIG_RTE_LIBRTE_IXGBE_DEBUG_DRIVER=n
CONFIG_RTE_LIBRTE_IXGBE_PF_DISABLE_STRIP_CRC=n
CONFIG_RTE_IXGBE_INC_VECTOR=y
+CONFIG_RTE_LIBRTE_IXGBE_BYPASS=n
#
# Compile burst-oriented I40E PMD driver
``_rte_eth_dev_callback_process``. In 17.08 the function will return an ``int``
instead of ``void`` and a fourth parameter ``void *ret_param`` will be added.
-* ethdev: for 17.08 it is planned to deprecate the following nine rte_eth_dev_*
- functions and move them into the ixgbe PMD:
-
- ``rte_eth_dev_bypass_init``, ``rte_eth_dev_bypass_state_set``,
- ``rte_eth_dev_bypass_state_show``, ``rte_eth_dev_bypass_event_store``,
- ``rte_eth_dev_bypass_event_show``, ``rte_eth_dev_wd_timeout_store``,
- ``rte_eth_dev_bypass_wd_timeout_show``, ``rte_eth_dev_bypass_ver_show``,
- ``rte_eth_dev_bypass_wd_reset``.
-
- The following fields will be removed from ``struct eth_dev_ops``:
-
- ``bypass_init_t``, ``bypass_state_set_t``, ``bypass_state_show_t``,
- ``bypass_event_set_t``, ``bypass_event_show_t``, ``bypass_wd_timeout_set_t``,
- ``bypass_wd_timeout_show_t``, ``bypass_ver_show_t``, ``bypass_wd_reset_t``.
-
- The functions will be renamed to the following, and moved to the ``ixgbe`` PMD:
-
- ``rte_pmd_ixgbe_bypass_init``, ``rte_pmd_ixgbe_bypass_state_set``,
- ``rte_pmd_ixgbe_bypass_state_show``, ``rte_pmd_ixgbe_bypass_event_set``,
- ``rte_pmd_ixgbe_bypass_event_show``, ``rte_pmd_ixgbe_bypass_wd_timeout_set``,
- ``rte_pmd_ixgbe_bypass_wd_timeout_show``, ``rte_pmd_ixgbe_bypass_ver_show``,
- ``rte_pmd_ixgbe_bypass_wd_reset``.
-
* The mbuf flags PKT_RX_VLAN_PKT and PKT_RX_QINQ_PKT are deprecated and
are respectively replaced by PKT_RX_VLAN_STRIPPED and
PKT_RX_QINQ_STRIPPED, that are better described. The old flags and
SRCS-$(CONFIG_RTE_IXGBE_INC_VECTOR) += ixgbe_rxtx_vec_sse.c
endif
-ifeq ($(CONFIG_RTE_NIC_BYPASS),y)
+ifeq ($(CONFIG_RTE_LIBRTE_IXGBE_BYPASS),y)
SRCS-$(CONFIG_RTE_LIBRTE_IXGBE_PMD) += ixgbe_bypass.c
SRCS-$(CONFIG_RTE_LIBRTE_IXGBE_PMD) += ixgbe_82599_bypass.c
endif
#include <rte_ethdev.h>
#include "ixgbe_ethdev.h"
#include "ixgbe_bypass_api.h"
+#include "rte_pmd_ixgbe.h"
#define BYPASS_STATUS_OFF_MASK 3
FUNC_PTR_OR_ERR_RET(adapter->bps.ops.bypass_set, -ENOTSUP);
/* disable the timer with timeout of zero */
- if (timeout == RTE_BYPASS_TMT_OFF) {
+ if (timeout == RTE_PMD_IXGBE_BYPASS_TMT_OFF) {
status = 0x0; /* WDG enable off */
mask = BYPASS_WDT_ENABLE_M;
} else {
wdg = by_ctl & BYPASS_WDT_ENABLE_M;
if (!wdg)
- *wd_timeout = RTE_BYPASS_TMT_OFF;
+ *wd_timeout = RTE_PMD_IXGBE_BYPASS_TMT_OFF;
else
*wd_timeout = (by_ctl >> BYPASS_WDT_TIME_SHIFT) &
BYPASS_WDT_MASK;
#ifndef _IXGBE_BYPASS_H_
#define _IXGBE_BYPASS_H_
-#ifdef RTE_NIC_BYPASS
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
struct ixgbe_bypass_mac_ops {
s32 (*bypass_rw)(struct ixgbe_hw *hw, u32 cmd, u32 *status);
s32 ixgbe_bypass_init_shared_code(struct ixgbe_hw *hw);
s32 ixgbe_bypass_init_hw(struct ixgbe_hw *hw);
-#endif /* RTE_NIC_BYPASS */
+#endif /* RTE_LIBRTE_IXGBE_BYPASS */
#endif /* _IXGBE_BYPASS_H_ */
#ifndef _IXGBE_BYPASS_API_H_
#define _IXGBE_BYPASS_API_H_
-#ifdef RTE_NIC_BYPASS
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
#include "ixgbe_bypass_defines.h"
/**
return 0;
}
-#endif /* RTE_NIC_BYPASS */
+#endif /* RTE_LIBRTE_IXGBE_BYPASS */
#endif /* _IXGBE_BYPASS_API_H_ */
#ifndef _IXGBE_BYPASS_DEFINES_H_
#define _IXGBE_BYPASS_DEFINES_H_
-#ifdef RTE_NIC_BYPASS
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
#define msleep(x) rte_delay_us(x*1000)
#define usleep_range(min, max) rte_delay_us(min)
#define IXGBE_BYPASS_FW_WRITE_FAILURE -35
-#endif /* RTE_NIC_BYPASS */
+#endif /* RTE_LIBRTE_IXGBE_BYPASS */
#endif /* _IXGBE_BYPASS_DEFINES_H_ */
{ RTE_PCI_DEVICE(IXGBE_INTEL_VENDOR_ID, IXGBE_DEV_ID_X550EM_A_1G_T_L) },
{ RTE_PCI_DEVICE(IXGBE_INTEL_VENDOR_ID, IXGBE_DEV_ID_X550EM_X_KX4) },
{ RTE_PCI_DEVICE(IXGBE_INTEL_VENDOR_ID, IXGBE_DEV_ID_X550EM_X_KR) },
-#ifdef RTE_NIC_BYPASS
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
{ RTE_PCI_DEVICE(IXGBE_INTEL_VENDOR_ID, IXGBE_DEV_ID_82599_BYPASS) },
#endif
{ .vendor_id = 0, /* sentinel */ },
.set_queue_rate_limit = ixgbe_set_queue_rate_limit,
.reta_update = ixgbe_dev_rss_reta_update,
.reta_query = ixgbe_dev_rss_reta_query,
-#ifdef RTE_NIC_BYPASS
- .bypass_init = ixgbe_bypass_init,
- .bypass_state_set = ixgbe_bypass_state_store,
- .bypass_state_show = ixgbe_bypass_state_show,
- .bypass_event_set = ixgbe_bypass_event_store,
- .bypass_event_show = ixgbe_bypass_event_show,
- .bypass_wd_timeout_set = ixgbe_bypass_wd_timeout_store,
- .bypass_wd_timeout_show = ixgbe_bypass_wd_timeout_show,
- .bypass_ver_show = ixgbe_bypass_ver_show,
- .bypass_wd_reset = ixgbe_bypass_wd_reset,
-#endif /* RTE_NIC_BYPASS */
.rss_hash_update = ixgbe_dev_rss_hash_update,
.rss_hash_conf_get = ixgbe_dev_rss_hash_conf_get,
.filter_ctrl = ixgbe_dev_filter_ctrl,
hw->allow_unsupported_sfp = 1;
/* Initialize the shared code (base driver) */
-#ifdef RTE_NIC_BYPASS
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
diag = ixgbe_bypass_init_shared_code(hw);
#else
diag = ixgbe_init_shared_code(hw);
-#endif /* RTE_NIC_BYPASS */
+#endif /* RTE_LIBRTE_IXGBE_BYPASS */
if (diag != IXGBE_SUCCESS) {
PMD_INIT_LOG(ERR, "Shared code init failed: %d", diag);
return -EIO;
}
-#ifdef RTE_NIC_BYPASS
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
diag = ixgbe_bypass_init_hw(hw);
#else
diag = ixgbe_init_hw(hw);
-#endif /* RTE_NIC_BYPASS */
+#endif /* RTE_LIBRTE_IXGBE_BYPASS */
/*
* Devices with copper phys will fail to initialise if ixgbe_init_hw()
struct ixgbe_hw *hw =
IXGBE_DEV_PRIVATE_TO_HW(dev->data->dev_private);
if (hw->mac.type == ixgbe_mac_82599EB) {
-#ifdef RTE_NIC_BYPASS
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
if (hw->device_id == IXGBE_DEV_ID_82599_BYPASS) {
/* Not suported in bypass mode */
PMD_INIT_LOG(ERR, "Set link up is not supported "
struct ixgbe_hw *hw =
IXGBE_DEV_PRIVATE_TO_HW(dev->data->dev_private);
if (hw->mac.type == ixgbe_mac_82599EB) {
-#ifdef RTE_NIC_BYPASS
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
if (hw->device_id == IXGBE_DEV_ID_82599_BYPASS) {
/* Not suported in bypass mode */
PMD_INIT_LOG(ERR, "Set link down is not supported "
struct ixgbe_mirror_info mr_data;
struct ixgbe_vf_info *vfdata;
struct ixgbe_uta_info uta_info;
-#ifdef RTE_NIC_BYPASS
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
struct ixgbe_bypass_info bps;
-#endif /* RTE_NIC_BYPASS */
+#endif /* RTE_LIBRTE_IXGBE_BYPASS */
struct ixgbe_filter_info filter;
struct ixgbe_l2_tn_info l2_tn;
struct ixgbe_bw_conf bw_conf;
return 0;
}
+
+#ifdef RTE_LIBRTE_IXGBE_BYPASS
+int
+rte_pmd_ixgbe_bypass_init(uint8_t port_id)
+{
+ struct rte_eth_dev *dev;
+
+ RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
+
+ dev = &rte_eth_devices[port_id];
+ if (!is_ixgbe_supported(dev))
+ return -ENOTSUP;
+
+ ixgbe_bypass_init(dev);
+ return 0;
+}
+
+int
+rte_pmd_ixgbe_bypass_state_show(uint8_t port_id, uint32_t *state)
+{
+ struct rte_eth_dev *dev;
+
+ RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
+
+ dev = &rte_eth_devices[port_id];
+ if (!is_ixgbe_supported(dev))
+ return -ENOTSUP;
+
+ return ixgbe_bypass_state_show(dev, state);
+}
+
+int
+rte_pmd_ixgbe_bypass_state_set(uint8_t port_id, uint32_t *new_state)
+{
+ struct rte_eth_dev *dev;
+
+ RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
+
+ dev = &rte_eth_devices[port_id];
+ if (!is_ixgbe_supported(dev))
+ return -ENOTSUP;
+
+ return ixgbe_bypass_state_store(dev, new_state);
+}
+
+int
+rte_pmd_ixgbe_bypass_event_show(uint8_t port_id,
+ uint32_t event,
+ uint32_t *state)
+{
+ struct rte_eth_dev *dev;
+
+ RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
+
+ dev = &rte_eth_devices[port_id];
+ if (!is_ixgbe_supported(dev))
+ return -ENOTSUP;
+
+ return ixgbe_bypass_event_show(dev, event, state);
+}
+
+int
+rte_pmd_ixgbe_bypass_event_store(uint8_t port_id,
+ uint32_t event,
+ uint32_t state)
+{
+ struct rte_eth_dev *dev;
+
+ RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
+
+ dev = &rte_eth_devices[port_id];
+ if (!is_ixgbe_supported(dev))
+ return -ENOTSUP;
+
+ return ixgbe_bypass_event_store(dev, event, state);
+}
+
+int
+rte_pmd_ixgbe_bypass_wd_timeout_store(uint8_t port_id, uint32_t timeout)
+{
+ struct rte_eth_dev *dev;
+
+ RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
+
+ dev = &rte_eth_devices[port_id];
+ if (!is_ixgbe_supported(dev))
+ return -ENOTSUP;
+
+ return ixgbe_bypass_wd_timeout_store(dev, timeout);
+}
+
+int
+rte_pmd_ixgbe_bypass_ver_show(uint8_t port_id, uint32_t *ver)
+{
+ struct rte_eth_dev *dev;
+
+ RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
+
+ dev = &rte_eth_devices[port_id];
+ if (!is_ixgbe_supported(dev))
+ return -ENOTSUP;
+
+ return ixgbe_bypass_ver_show(dev, ver);
+}
+
+int
+rte_pmd_ixgbe_bypass_wd_timeout_show(uint8_t port_id, uint32_t *wd_timeout)
+{
+ struct rte_eth_dev *dev;
+
+ RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
+
+ dev = &rte_eth_devices[port_id];
+ if (!is_ixgbe_supported(dev))
+ return -ENOTSUP;
+
+ return ixgbe_bypass_wd_timeout_show(dev, wd_timeout);
+}
+
+int
+rte_pmd_ixgbe_bypass_wd_reset(uint8_t port_id)
+{
+ struct rte_eth_dev *dev;
+
+ RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
+
+ dev = &rte_eth_devices[port_id];
+ if (!is_ixgbe_supported(dev))
+ return -ENOTSUP;
+
+ return ixgbe_bypass_wd_reset(dev);
+}
+#endif
uint8_t tc_num,
uint8_t *bw_weight);
+
+/**
+ * Initialize bypass logic. This function needs to be called before
+ * executing any other bypass API.
+ *
+ * @param port
+ * The port identifier of the Ethernet device.
+ * @return
+ * - (0) if successful.
+ * - (-ENOTSUP) if hardware doesn't support.
+ * - (-EINVAL) if bad parameter.
+ */
+int rte_pmd_ixgbe_bypass_init(uint8_t port);
+
+/**
+ * Return bypass state.
+ *
+ * @param port
+ * The port identifier of the Ethernet device.
+ * @param state
+ * The return bypass state.
+ * - (1) Normal mode
+ * - (2) Bypass mode
+ * - (3) Isolate mode
+ * @return
+ * - (0) if successful.
+ * - (-ENOTSUP) if hardware doesn't support.
+ * - (-EINVAL) if bad parameter.
+ */
+int rte_pmd_ixgbe_bypass_state_show(uint8_t port, uint32_t *state);
+
+/**
+ * Set bypass state
+ *
+ * @param port
+ * The port identifier of the Ethernet device.
+ * @param new_state
+ * The current bypass state.
+ * - (1) Normal mode
+ * - (2) Bypass mode
+ * - (3) Isolate mode
+ * @return
+ * - (0) if successful.
+ * - (-ENOTSUP) if hardware doesn't support.
+ * - (-EINVAL) if bad parameter.
+ */
+int rte_pmd_ixgbe_bypass_state_set(uint8_t port, uint32_t *new_state);
+
+/**
+ * Return bypass state when given event occurs.
+ *
+ * @param port
+ * The port identifier of the Ethernet device.
+ * @param event
+ * The bypass event
+ * - (1) Main power on (power button is pushed)
+ * - (2) Auxiliary power on (power supply is being plugged)
+ * - (3) Main power off (system shutdown and power supply is left plugged in)
+ * - (4) Auxiliary power off (power supply is being unplugged)
+ * - (5) Display or set the watchdog timer
+ * @param state
+ * The bypass state when given event occurred.
+ * - (1) Normal mode
+ * - (2) Bypass mode
+ * - (3) Isolate mode
+ * @return
+ * - (0) if successful.
+ * - (-ENOTSUP) if hardware doesn't support.
+ * - (-EINVAL) if bad parameter.
+ */
+int rte_pmd_ixgbe_bypass_event_show(uint8_t port,
+ uint32_t event,
+ uint32_t *state);
+
+/**
+ * Set bypass state when given event occurs.
+ *
+ * @param port
+ * The port identifier of the Ethernet device.
+ * @param event
+ * The bypass event
+ * - (1) Main power on (power button is pushed)
+ * - (2) Auxiliary power on (power supply is being plugged)
+ * - (3) Main power off (system shutdown and power supply is left plugged in)
+ * - (4) Auxiliary power off (power supply is being unplugged)
+ * - (5) Display or set the watchdog timer
+ * @param state
+ * The assigned state when given event occurs.
+ * - (1) Normal mode
+ * - (2) Bypass mode
+ * - (3) Isolate mode
+ * @return
+ * - (0) if successful.
+ * - (-ENOTSUP) if hardware doesn't support.
+ * - (-EINVAL) if bad parameter.
+ */
+int rte_pmd_ixgbe_bypass_event_store(uint8_t port,
+ uint32_t event,
+ uint32_t state);
+
+/**
+ * Set bypass watchdog timeout count.
+ *
+ * @param port
+ * The port identifier of the Ethernet device.
+ * @param timeout
+ * The timeout to be set.
+ * - (0) 0 seconds (timer is off)
+ * - (1) 1.5 seconds
+ * - (2) 2 seconds
+ * - (3) 3 seconds
+ * - (4) 4 seconds
+ * - (5) 8 seconds
+ * - (6) 16 seconds
+ * - (7) 32 seconds
+ * @return
+ * - (0) if successful.
+ * - (-ENOTSUP) if hardware doesn't support.
+ * - (-EINVAL) if bad parameter.
+ */
+int rte_pmd_ixgbe_bypass_wd_timeout_store(uint8_t port, uint32_t timeout);
+
+/**
+ * Get bypass firmware version.
+ *
+ * @param port
+ * The port identifier of the Ethernet device.
+ * @param ver
+ * The firmware version
+ * @return
+ * - (0) if successful.
+ * - (-ENOTSUP) if hardware doesn't support.
+ * - (-EINVAL) if bad parameter.
+ */
+int rte_pmd_ixgbe_bypass_ver_show(uint8_t port, uint32_t *ver);
+
+/**
+ * Return bypass watchdog timeout in seconds
+ *
+ * @param port
+ * The port identifier of the Ethernet device.
+ * @param wd_timeout
+ * The return watchdog timeout. "0" represents timer expired
+ * - (0) 0 seconds (timer is off)
+ * - (1) 1.5 seconds
+ * - (2) 2 seconds
+ * - (3) 3 seconds
+ * - (4) 4 seconds
+ * - (5) 8 seconds
+ * - (6) 16 seconds
+ * - (7) 32 seconds
+ * @return
+ * - (0) if successful.
+ * - (-ENOTSUP) if hardware doesn't support.
+ * - (-EINVAL) if bad parameter.
+ */
+int rte_pmd_ixgbe_bypass_wd_timeout_show(uint8_t port, uint32_t *wd_timeout);
+
+/**
+ * Reset bypass watchdog timer
+ *
+ * @param port
+ * The port identifier of the Ethernet device.
+ * @return
+ * - (0) if successful.
+ * - (-ENOTSUP) if hardware doesn't support.
+ * - (-EINVAL) if bad parameter.
+ */
+int rte_pmd_ixgbe_bypass_wd_reset(uint8_t port);
+
+
/**
* Response sent back to ixgbe driver from user app after callback
*/
uint16_t retval; /**< return value */
void *msg; /**< pointer to message */
};
+enum {
+ RTE_PMD_IXGBE_BYPASS_MODE_NONE,
+ RTE_PMD_IXGBE_BYPASS_MODE_NORMAL,
+ RTE_PMD_IXGBE_BYPASS_MODE_BYPASS,
+ RTE_PMD_IXGBE_BYPASS_MODE_ISOLATE,
+ RTE_PMD_IXGBE_BYPASS_MODE_NUM,
+};
+
+#define RTE_PMD_IXGBE_BYPASS_MODE_VALID(x) \
+ ((x) > RTE_PMD_IXGBE_BYPASS_MODE_NONE && \
+ (x) < RTE_PMD_IXGBE_BYPASS_MODE_NUM)
+
+enum {
+ RTE_PMD_IXGBE_BYPASS_EVENT_NONE,
+ RTE_PMD_IXGBE_BYPASS_EVENT_START,
+ RTE_PMD_IXGBE_BYPASS_EVENT_OS_ON = RTE_PMD_IXGBE_BYPASS_EVENT_START,
+ RTE_PMD_IXGBE_BYPASS_EVENT_POWER_ON,
+ RTE_PMD_IXGBE_BYPASS_EVENT_OS_OFF,
+ RTE_PMD_IXGBE_BYPASS_EVENT_POWER_OFF,
+ RTE_PMD_IXGBE_BYPASS_EVENT_TIMEOUT,
+ RTE_PMD_IXGBE_BYPASS_EVENT_NUM
+};
+
+#define RTE_PMD_IXGBE_BYPASS_EVENT_VALID(x) \
+ ((x) > RTE_PMD_IXGBE_BYPASS_EVENT_NONE && \
+ (x) < RTE_PMD_IXGBE_BYPASS_MODE_NUM)
+
+enum {
+ RTE_PMD_IXGBE_BYPASS_TMT_OFF, /* timeout disabled. */
+ RTE_PMD_IXGBE_BYPASS_TMT_1_5_SEC, /* timeout for 1.5 seconds */
+ RTE_PMD_IXGBE_BYPASS_TMT_2_SEC, /* timeout for 2 seconds */
+ RTE_PMD_IXGBE_BYPASS_TMT_3_SEC, /* timeout for 3 seconds */
+ RTE_PMD_IXGBE_BYPASS_TMT_4_SEC, /* timeout for 4 seconds */
+ RTE_PMD_IXGBE_BYPASS_TMT_8_SEC, /* timeout for 8 seconds */
+ RTE_PMD_IXGBE_BYPASS_TMT_16_SEC, /* timeout for 16 seconds */
+ RTE_PMD_IXGBE_BYPASS_TMT_32_SEC, /* timeout for 32 seconds */
+ RTE_PMD_IXGBE_BYPASS_TMT_NUM
+};
+
+#define RTE_PMD_IXGBE_BYPASS_TMT_VALID(x) \
+ ((x) == RTE_PMD_IXGBE_BYPASS_TMT_OFF || \
+ ((x) > RTE_PMD_IXGBE_BYPASS_TMT_OFF && \
+ (x) < RTE_PMD_IXGBE_BYPASS_TMT_NUM))
+
#endif /* _PMD_IXGBE_H_ */
rte_pmd_ixgbe_ping_vf;
rte_pmd_ixgbe_set_tc_bw_alloc;
} DPDK_17.02;
+
+DPDK_17.08 {
+ global:
+
+ rte_pmd_ixgbe_bypass_event_show;
+ rte_pmd_ixgbe_bypass_event_store;
+ rte_pmd_ixgbe_bypass_init;
+ rte_pmd_ixgbe_bypass_state_set;
+ rte_pmd_ixgbe_bypass_state_show;
+ rte_pmd_ixgbe_bypass_ver_show;
+ rte_pmd_ixgbe_bypass_wd_reset;
+ rte_pmd_ixgbe_bypass_wd_timeout_show;
+ rte_pmd_ixgbe_bypass_wd_timeout_store;
+} DPDK_17.05;
return (*dev->dev_ops->rx_queue_intr_disable)(dev, queue_id);
}
-#ifdef RTE_NIC_BYPASS
-int rte_eth_dev_bypass_init(uint8_t port_id)
-{
- struct rte_eth_dev *dev;
-
- RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
-
- dev = &rte_eth_devices[port_id];
- RTE_FUNC_PTR_OR_ERR_RET(*dev->dev_ops->bypass_init, -ENOTSUP);
- (*dev->dev_ops->bypass_init)(dev);
- return 0;
-}
-
-int
-rte_eth_dev_bypass_state_show(uint8_t port_id, uint32_t *state)
-{
- struct rte_eth_dev *dev;
-
- RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
-
- dev = &rte_eth_devices[port_id];
- RTE_FUNC_PTR_OR_ERR_RET(*dev->dev_ops->bypass_state_show, -ENOTSUP);
- (*dev->dev_ops->bypass_state_show)(dev, state);
- return 0;
-}
-
-int
-rte_eth_dev_bypass_state_set(uint8_t port_id, uint32_t *new_state)
-{
- struct rte_eth_dev *dev;
-
- RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
-
- dev = &rte_eth_devices[port_id];
- RTE_FUNC_PTR_OR_ERR_RET(*dev->dev_ops->bypass_state_set, -ENOTSUP);
- (*dev->dev_ops->bypass_state_set)(dev, new_state);
- return 0;
-}
-
-int
-rte_eth_dev_bypass_event_show(uint8_t port_id, uint32_t event, uint32_t *state)
-{
- struct rte_eth_dev *dev;
-
- RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
-
- dev = &rte_eth_devices[port_id];
- RTE_FUNC_PTR_OR_ERR_RET(*dev->dev_ops->bypass_state_show, -ENOTSUP);
- (*dev->dev_ops->bypass_event_show)(dev, event, state);
- return 0;
-}
-
-int
-rte_eth_dev_bypass_event_store(uint8_t port_id, uint32_t event, uint32_t state)
-{
- struct rte_eth_dev *dev;
-
- RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
-
- dev = &rte_eth_devices[port_id];
-
- RTE_FUNC_PTR_OR_ERR_RET(*dev->dev_ops->bypass_event_set, -ENOTSUP);
- (*dev->dev_ops->bypass_event_set)(dev, event, state);
- return 0;
-}
-
-int
-rte_eth_dev_wd_timeout_store(uint8_t port_id, uint32_t timeout)
-{
- struct rte_eth_dev *dev;
-
- RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
-
- dev = &rte_eth_devices[port_id];
-
- RTE_FUNC_PTR_OR_ERR_RET(*dev->dev_ops->bypass_wd_timeout_set, -ENOTSUP);
- (*dev->dev_ops->bypass_wd_timeout_set)(dev, timeout);
- return 0;
-}
-
-int
-rte_eth_dev_bypass_ver_show(uint8_t port_id, uint32_t *ver)
-{
- struct rte_eth_dev *dev;
-
- RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
-
- dev = &rte_eth_devices[port_id];
-
- RTE_FUNC_PTR_OR_ERR_RET(*dev->dev_ops->bypass_ver_show, -ENOTSUP);
- (*dev->dev_ops->bypass_ver_show)(dev, ver);
- return 0;
-}
-
-int
-rte_eth_dev_bypass_wd_timeout_show(uint8_t port_id, uint32_t *wd_timeout)
-{
- struct rte_eth_dev *dev;
-
- RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
-
- dev = &rte_eth_devices[port_id];
-
- RTE_FUNC_PTR_OR_ERR_RET(*dev->dev_ops->bypass_wd_timeout_show, -ENOTSUP);
- (*dev->dev_ops->bypass_wd_timeout_show)(dev, wd_timeout);
- return 0;
-}
-
-int
-rte_eth_dev_bypass_wd_reset(uint8_t port_id)
-{
- struct rte_eth_dev *dev;
-
- RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
-
- dev = &rte_eth_devices[port_id];
-
- RTE_FUNC_PTR_OR_ERR_RET(*dev->dev_ops->bypass_wd_reset, -ENOTSUP);
- (*dev->dev_ops->bypass_wd_reset)(dev);
- return 0;
-}
-#endif
int
rte_eth_dev_filter_supported(uint8_t port_id, enum rte_filter_type filter_type)
uint8_t en);
/**< @internal enable/disable the l2 tunnel offload functions */
-#ifdef RTE_NIC_BYPASS
-
-enum {
- RTE_BYPASS_MODE_NONE,
- RTE_BYPASS_MODE_NORMAL,
- RTE_BYPASS_MODE_BYPASS,
- RTE_BYPASS_MODE_ISOLATE,
- RTE_BYPASS_MODE_NUM,
-};
-
-#define RTE_BYPASS_MODE_VALID(x) \
- ((x) > RTE_BYPASS_MODE_NONE && (x) < RTE_BYPASS_MODE_NUM)
-
-enum {
- RTE_BYPASS_EVENT_NONE,
- RTE_BYPASS_EVENT_START,
- RTE_BYPASS_EVENT_OS_ON = RTE_BYPASS_EVENT_START,
- RTE_BYPASS_EVENT_POWER_ON,
- RTE_BYPASS_EVENT_OS_OFF,
- RTE_BYPASS_EVENT_POWER_OFF,
- RTE_BYPASS_EVENT_TIMEOUT,
- RTE_BYPASS_EVENT_NUM
-};
-
-#define RTE_BYPASS_EVENT_VALID(x) \
- ((x) > RTE_BYPASS_EVENT_NONE && (x) < RTE_BYPASS_MODE_NUM)
-
-enum {
- RTE_BYPASS_TMT_OFF, /* timeout disabled. */
- RTE_BYPASS_TMT_1_5_SEC, /* timeout for 1.5 seconds */
- RTE_BYPASS_TMT_2_SEC, /* timeout for 2 seconds */
- RTE_BYPASS_TMT_3_SEC, /* timeout for 3 seconds */
- RTE_BYPASS_TMT_4_SEC, /* timeout for 4 seconds */
- RTE_BYPASS_TMT_8_SEC, /* timeout for 8 seconds */
- RTE_BYPASS_TMT_16_SEC, /* timeout for 16 seconds */
- RTE_BYPASS_TMT_32_SEC, /* timeout for 32 seconds */
- RTE_BYPASS_TMT_NUM
-};
-
-#define RTE_BYPASS_TMT_VALID(x) \
- ((x) == RTE_BYPASS_TMT_OFF || \
- ((x) > RTE_BYPASS_TMT_OFF && (x) < RTE_BYPASS_TMT_NUM))
-
-typedef void (*bypass_init_t)(struct rte_eth_dev *dev);
-typedef int32_t (*bypass_state_set_t)(struct rte_eth_dev *dev, uint32_t *new_state);
-typedef int32_t (*bypass_state_show_t)(struct rte_eth_dev *dev, uint32_t *state);
-typedef int32_t (*bypass_event_set_t)(struct rte_eth_dev *dev, uint32_t state, uint32_t event);
-typedef int32_t (*bypass_event_show_t)(struct rte_eth_dev *dev, uint32_t event_shift, uint32_t *event);
-typedef int32_t (*bypass_wd_timeout_set_t)(struct rte_eth_dev *dev, uint32_t timeout);
-typedef int32_t (*bypass_wd_timeout_show_t)(struct rte_eth_dev *dev, uint32_t *wd_timeout);
-typedef int32_t (*bypass_ver_show_t)(struct rte_eth_dev *dev, uint32_t *ver);
-typedef int32_t (*bypass_wd_reset_t)(struct rte_eth_dev *dev);
-#endif
typedef int (*eth_filter_ctrl_t)(struct rte_eth_dev *dev,
enum rte_filter_type filter_type,
eth_get_eeprom_t get_eeprom; /**< Get eeprom data. */
eth_set_eeprom_t set_eeprom; /**< Set eeprom. */
- /* bypass control */
-#ifdef RTE_NIC_BYPASS
- bypass_init_t bypass_init;
- bypass_state_set_t bypass_state_set;
- bypass_state_show_t bypass_state_show;
- bypass_event_set_t bypass_event_set;
- bypass_event_show_t bypass_event_show;
- bypass_wd_timeout_set_t bypass_wd_timeout_set;
- bypass_wd_timeout_show_t bypass_wd_timeout_show;
- bypass_ver_show_t bypass_ver_show;
- bypass_wd_reset_t bypass_wd_reset;
-#endif
eth_filter_ctrl_t filter_ctrl; /**< common filter control. */
int rte_eth_set_queue_rate_limit(uint8_t port_id, uint16_t queue_idx,
uint16_t tx_rate);
-/**
- * Initialize bypass logic. This function needs to be called before
- * executing any other bypass API.
- *
- * @param port
- * The port identifier of the Ethernet device.
- * @return
- * - (0) if successful.
- * - (-ENOTSUP) if hardware doesn't support.
- * - (-EINVAL) if bad parameter.
- */
-int rte_eth_dev_bypass_init(uint8_t port);
-
-/**
- * Return bypass state.
- *
- * @param port
- * The port identifier of the Ethernet device.
- * @param state
- * The return bypass state.
- * - (1) Normal mode
- * - (2) Bypass mode
- * - (3) Isolate mode
- * @return
- * - (0) if successful.
- * - (-ENOTSUP) if hardware doesn't support.
- * - (-EINVAL) if bad parameter.
- */
-int rte_eth_dev_bypass_state_show(uint8_t port, uint32_t *state);
-
-/**
- * Set bypass state
- *
- * @param port
- * The port identifier of the Ethernet device.
- * @param new_state
- * The current bypass state.
- * - (1) Normal mode
- * - (2) Bypass mode
- * - (3) Isolate mode
- * @return
- * - (0) if successful.
- * - (-ENOTSUP) if hardware doesn't support.
- * - (-EINVAL) if bad parameter.
- */
-int rte_eth_dev_bypass_state_set(uint8_t port, uint32_t *new_state);
-
-/**
- * Return bypass state when given event occurs.
- *
- * @param port
- * The port identifier of the Ethernet device.
- * @param event
- * The bypass event
- * - (1) Main power on (power button is pushed)
- * - (2) Auxiliary power on (power supply is being plugged)
- * - (3) Main power off (system shutdown and power supply is left plugged in)
- * - (4) Auxiliary power off (power supply is being unplugged)
- * - (5) Display or set the watchdog timer
- * @param state
- * The bypass state when given event occurred.
- * - (1) Normal mode
- * - (2) Bypass mode
- * - (3) Isolate mode
- * @return
- * - (0) if successful.
- * - (-ENOTSUP) if hardware doesn't support.
- * - (-EINVAL) if bad parameter.
- */
-int rte_eth_dev_bypass_event_show(uint8_t port, uint32_t event, uint32_t *state);
-
-/**
- * Set bypass state when given event occurs.
- *
- * @param port
- * The port identifier of the Ethernet device.
- * @param event
- * The bypass event
- * - (1) Main power on (power button is pushed)
- * - (2) Auxiliary power on (power supply is being plugged)
- * - (3) Main power off (system shutdown and power supply is left plugged in)
- * - (4) Auxiliary power off (power supply is being unplugged)
- * - (5) Display or set the watchdog timer
- * @param state
- * The assigned state when given event occurs.
- * - (1) Normal mode
- * - (2) Bypass mode
- * - (3) Isolate mode
- * @return
- * - (0) if successful.
- * - (-ENOTSUP) if hardware doesn't support.
- * - (-EINVAL) if bad parameter.
- */
-int rte_eth_dev_bypass_event_store(uint8_t port, uint32_t event, uint32_t state);
-
-/**
- * Set bypass watchdog timeout count.
- *
- * @param port
- * The port identifier of the Ethernet device.
- * @param timeout
- * The timeout to be set.
- * - (0) 0 seconds (timer is off)
- * - (1) 1.5 seconds
- * - (2) 2 seconds
- * - (3) 3 seconds
- * - (4) 4 seconds
- * - (5) 8 seconds
- * - (6) 16 seconds
- * - (7) 32 seconds
- * @return
- * - (0) if successful.
- * - (-ENOTSUP) if hardware doesn't support.
- * - (-EINVAL) if bad parameter.
- */
-int rte_eth_dev_wd_timeout_store(uint8_t port, uint32_t timeout);
-
-/**
- * Get bypass firmware version.
- *
- * @param port
- * The port identifier of the Ethernet device.
- * @param ver
- * The firmware version
- * @return
- * - (0) if successful.
- * - (-ENOTSUP) if hardware doesn't support.
- * - (-EINVAL) if bad parameter.
- */
-int rte_eth_dev_bypass_ver_show(uint8_t port, uint32_t *ver);
-
-/**
- * Return bypass watchdog timeout in seconds
- *
- * @param port
- * The port identifier of the Ethernet device.
- * @param wd_timeout
- * The return watchdog timeout. "0" represents timer expired
- * - (0) 0 seconds (timer is off)
- * - (1) 1.5 seconds
- * - (2) 2 seconds
- * - (3) 3 seconds
- * - (4) 4 seconds
- * - (5) 8 seconds
- * - (6) 16 seconds
- * - (7) 32 seconds
- * @return
- * - (0) if successful.
- * - (-ENOTSUP) if hardware doesn't support.
- * - (-EINVAL) if bad parameter.
- */
-int rte_eth_dev_bypass_wd_timeout_show(uint8_t port, uint32_t *wd_timeout);
-
-/**
- * Reset bypass watchdog timer
- *
- * @param port
- * The port identifier of the Ethernet device.
- * @return
- * - (0) if successful.
- * - (-ENOTSUP) if hardware doesn't support.
- * - (-EINVAL) if bad parameter.
- */
-int rte_eth_dev_bypass_wd_reset(uint8_t port);
-
/**
* Configuration of Receive Side Scaling hash computation of Ethernet device.
*
rte_eth_dev_allocate;
rte_eth_dev_allocated;
rte_eth_dev_attach;
- rte_eth_dev_bypass_event_show;
- rte_eth_dev_bypass_event_store;
- rte_eth_dev_bypass_init;
- rte_eth_dev_bypass_state_set;
- rte_eth_dev_bypass_state_show;
- rte_eth_dev_bypass_ver_show;
- rte_eth_dev_bypass_wd_reset;
- rte_eth_dev_bypass_wd_timeout_show;
rte_eth_dev_callback_register;
rte_eth_dev_callback_unregister;
rte_eth_dev_close;
rte_eth_dev_uc_all_hash_table_set;
rte_eth_dev_uc_hash_table_set;
rte_eth_dev_vlan_filter;
- rte_eth_dev_wd_timeout_store;
rte_eth_dma_zone_reserve;
rte_eth_led_off;
rte_eth_led_on;