/* The most significant bit being set in the version field indicates an
* experimental OpenFlow version.
*/
-#define OFP_VERSION 0x87
+#define OFP_VERSION 0x88
#define OFP_MAX_TABLE_NAME_LEN 32
#define OFP_MAX_PORT_NAME_LEN 16
};
OFP_ASSERT(sizeof(struct ofp_table_stats) == 56);
-/* Statistics about a particular port */
+/* Statistics about a particular port. If a counter is unsupported, set
+ * the field to all ones. */
struct ofp_port_stats {
uint16_t port_no;
- uint8_t pad[6]; /* Align to 64-bits */
- uint64_t rx_count; /* Number of received packets */
- uint64_t tx_count; /* Number of transmitted packets */
- uint64_t drop_count; /* Number of packets dropped by interface */
-};
-OFP_ASSERT(sizeof(struct ofp_port_stats) == 32);
+ uint8_t pad[6]; /* Align to 64-bits. */
+ uint64_t rx_packets; /* Number of received packets. */
+ uint64_t tx_packets; /* Number of transmitted packets. */
+ uint64_t rx_bytes; /* Number of received bytes. */
+ uint64_t tx_bytes; /* Number of transmitted bytes. */
+ uint64_t rx_dropped; /* Number of packets dropped by RX. */
+ uint64_t tx_dropped; /* Number of packets dropped by TX. */
+ uint64_t rx_errors; /* Number of receive errors. This is a super-set
+ of receive errors and should be great than or
+ equal to the sum of al rx_*_err values. */
+ uint64_t tx_errors; /* Number of transmit errors. This is a super-set
+ of transmit errors. */
+ uint64_t rx_frame_err; /* Number of frame alignment errors. */
+ uint64_t rx_over_err; /* Number of packets with RX overrun. */
+ uint64_t rx_crc_err; /* Number of CRC errors. */
+ uint64_t collisions; /* Number of collisions. */
+};
+OFP_ASSERT(sizeof(struct ofp_port_stats) == 104);
#endif /* openflow.h */