Commit b9e7fc0
igc: Fix double reset adapter triggered from a single taprio cmd
Following the implementation of "igc: Add TransmissionOverrun counter"
patch, when a taprio command is triggered by user, igc processes two
commands: TAPRIO_CMD_REPLACE followed by TAPRIO_CMD_STATS. However, both
commands unconditionally pass through igc_tsn_offload_apply() which
evaluates and triggers reset adapter. The double reset causes issues in
the calculation of adapter->qbv_count in igc.
TAPRIO_CMD_REPLACE command is expected to reset the adapter since it
activates qbv. It's unexpected for TAPRIO_CMD_STATS to do the same
because it doesn't configure any driver-specific TSN settings. So, the
evaluation in igc_tsn_offload_apply() isn't needed for TAPRIO_CMD_STATS.
To address this, commands parsing are relocated to
igc_tsn_enable_qbv_scheduling(). Commands that don't require an adapter
reset will exit after processing, thus avoiding igc_tsn_offload_apply().
Fixes: d375007 ("igc: Add TransmissionOverrun counter")
Signed-off-by: Faizal Rahim <[email protected]>
Acked-by: Vinicius Costa Gomes <[email protected]>
Reviewed-by: Vladimir Oltean <[email protected]>
Tested-by: Mor Bar-Gabay <[email protected]>
Signed-off-by: Tony Nguyen <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Jakub Kicinski <[email protected]>1 parent 4efce72 commit b9e7fc0
1 file changed
+17
-16
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6306 | 6306 | | |
6307 | 6307 | | |
6308 | 6308 | | |
6309 | | - | |
6310 | | - | |
6311 | | - | |
6312 | | - | |
6313 | | - | |
6314 | | - | |
6315 | | - | |
6316 | | - | |
6317 | | - | |
6318 | | - | |
6319 | | - | |
6320 | | - | |
6321 | | - | |
6322 | | - | |
6323 | | - | |
6324 | 6309 | | |
6325 | 6310 | | |
6326 | 6311 | | |
| |||
6429 | 6414 | | |
6430 | 6415 | | |
6431 | 6416 | | |
6432 | | - | |
| 6417 | + | |
| 6418 | + | |
| 6419 | + | |
| 6420 | + | |
| 6421 | + | |
| 6422 | + | |
| 6423 | + | |
| 6424 | + | |
| 6425 | + | |
| 6426 | + | |
| 6427 | + | |
| 6428 | + | |
| 6429 | + | |
| 6430 | + | |
| 6431 | + | |
| 6432 | + | |
| 6433 | + | |
6433 | 6434 | | |
6434 | 6435 | | |
6435 | 6436 | | |
| |||
0 commit comments