ethdev: document error codes of reset
authorLuca Boccassi <bluca@debian.org>
Tue, 24 Oct 2017 13:19:04 +0000 (14:19 +0100)
committerFerruh Yigit <ferruh.yigit@intel.com>
Thu, 26 Oct 2017 00:33:01 +0000 (02:33 +0200)
This new function returns 0 on success and various error codes on
different failures. Attempt to document them.

Signed-off-by: Luca Boccassi <bluca@debian.org>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
lib/librte_ether/rte_ethdev.h

index 028bf11..60a8bae 100644 (file)
@@ -2278,6 +2278,14 @@ void rte_eth_dev_close(uint16_t port_id);
  *
  * @param port_id
  *   The port identifier of the Ethernet device.
+ *
+ * @return
+ *   - (0) if successful.
+ *   - (-EINVAL) if port identifier is invalid.
+ *   - (-ENOTSUP) if hardware doesn't support this function.
+ *   - (-EPERM) if not ran from the primary process.
+ *   - (-EIO) if re-initialisation failed.
+ *   - (-ENOMEM) if the reset failed due to OOM.
  */
 int rte_eth_dev_reset(uint16_t port_id);