lag: address review, single arg-count check and "d" only

Fold the "group with no ports" case into the argument-count guard
(cmd_words_len < 3) instead of a separate check, and accept only "d" for
delete, dropping the longer "delete" spelling. Update the serial-console
docs to match.
This commit is contained in:
d00f committed 2026-09-06 18:41:27 +02:00
1 parent ecac6d1934
commit 078a446cee
2 files changed
+8 -9

No files matched your search

+5 -3
View File
@@ -48,9 +48,11 @@ void port_lag_hash_set(__xdata uint8_t lag, __xdata uint8_t hash_bits) __banked;
## LAG configuration on the Serial Console
For testing the following commands are provided on the serial console:
```
> lag <LAG-ID> [p1] [p2]...
Create or set a LAG. Trunk-ID is 1 or 2. Ports are physical ports
If only the LAG-ID is given but no members, the LAG is deleted
> lag <LAG-ID> <p1> [p2]...
Create or set a LAG. LAG-ID is 1 to 4. Ports are physical ports.
> lag <LAG-ID> d
Delete the LAG.
> lag show
Shows information on all 4 lags