Hi,

We are currently working on implementing the Forward Error Correction (FEC) feature in our driver, but we have encountered some difficulties in understanding the interpretation of the semantics of 'fec_capa', a bitmask of allowed FEC modes. Specifically, we are unclear about the meaning of various bit combinations.

In rte_ethdev.h, 'fec_capa' is defined as follows:

```
 * @param fec_capa
 *   A bitmask of allowed FEC modes. If AUTO bit is set, other
 *   bits specify FEC modes which may be negotiated. If AUTO
 *   bit is clear, specify FEC modes to be used (only one valid
 *   mode per speed may be set).
```

We have a few questions regarding this definition:
* Is it possible for the AUTO bit to be set without any other bits?
* Can both RS and BASER bits be set together without the AUTO bit?

Based on our understanding, we have come up with the following interpretations for different bit combinations:

* NOFEC overrides any other bits, and means "disable all FEC";
* AUTO on its own implies using cable requirements and link partner autoneg with firmware-default preferences for the cable type; * AUTO combined with either RS or BASER signifies using the specified FEC type if the cable and link partner support it; otherwise, autoneg/firmware-default is used; * RS or BASER alone means using the specified FEC type if the cable and link partner support it and either requests it; otherwise, no FEC is employed; * Both RS and BASER, with or without AUTO, indicate using FEC if the cable and link partner support it, preferring RS to BASER.

We would greatly appreciate any assistance in clarifying our understanding and ensuring that our interpretations are accurate.

Thank you in advance for your help.

Sincerely,
Denis

Reply via email to