commit | ed0a15ed70567aa78a569d1b5fa907628c7b905c | [log] [tgz] |
---|---|---|
author | Patrick Williams <patrick@stwcx.xyz> | Fri Aug 16 15:22:26 2024 -0400 |
committer | Patrick Williams <patrick@stwcx.xyz> | Fri Aug 16 15:22:26 2024 -0400 |
tree | 2129243c99de38d430c2192bc493dc5811c4cf4d | |
parent | efbdace1f928d3e32f468ee1184e7212ef8f9c52 [diff] |
clang-format: re-format for clang-18 clang-format-18 isn't compatible with the clang-format-17 output, so we need to reformat the code with the latest version. The way clang-18 handles lambda formatting also changed, so we have made changes to the organization default style format to better handle lambda formatting. See I5e08687e696dd240402a2780158664b7113def0e for updated style. See Iea0776aaa7edd483fa395e23de25ebf5a6288f71 for clang-18 enablement. Change-Id: Ib9be48e4338d5a39d0d2ccea30e04e5a1fce24ee Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
There is the need to read a specific ethernet-level statistic value from the BMC. This is driven primarily to detect link errors that require hardware swaps during manufacturing.
This command will be well structured such that there is a request and response which mirror to some extent.
The request will specify the ethernet interface by name, as a length-prepended string, and the field they're requesting by identifier (an unsigned byte).
If the command is not supported, the IPMI OEM handler will respond accordingly, however, if the field is not supported or not recognized, the command will return 0xcc (invalid field).
The current ethernet statistics available (all future additions must append):
Identifier | Human Readable Name |
---|---|
0 | rx_bytes |
1 | rx_compressed |
2 | rx_crc_errors |
3 | rx_dropped |
4 | rx_errors |
5 | rx_fifo_errors |
6 | rx_frame_errors |
7 | rx_length_errors |
8 | rx_missed_errors |
9 | rx_nohandler |
10 | rx_over_errors |
11 | rx_packets |
12 | tx_aborted_errors |
13 | tx_bytes |
14 | tx_carrier_errors |
15 | tx_compressed |
16 | tx_dropped |
17 | tx_errors |
18 | tx_fifo_errors |
19 | tx_heartbeat_errors |
20 | tx_packets |
21 | tx_window_errors |
Request
Byte(s) | Value | Data |
---|---|---|
0x00 | Statistic ID | The identifier of the desired statistic. |
0x01 | Length | Length of string (not including null termination). |
0x02.. | The name | The string, not null-terminated. |
Response
Byte(s) | Value | Data |
---|---|---|
0x00 | Stat ID | The identifier of the desired statistic. |
0x01.... | Uint64 | The value. Because these are counters we don't anticipate negative values, and we don't expect overflow. |