mirror of
https://github.com/logicog/RTLPlayground.git
synced 2026-10-29 17:54:14 +08:00
The speed selector on the Ports tab was filled with its options and never given a value, so it read "auto" on every load whatever the port was set to. Forcing a port to 1G and reloading showed "auto" in the selector beside a link badge reading 1G. The advertisement bits ports.json already reports say what the port is set to: phy_set_speed() writes the same three registers the JSON reads back, and every forced speed leaves exactly one of the six bits standing while auto leaves the lot. Map those to the selector, and leave it alone while it has focus, as the MTU field does. Values with no entry in the table, such as the 100M setting that advertises both duplex modes, leave the selector untouched rather than claim a setting the list cannot express.