Say which of the two addresses actually wakes the device - #842
Merged
Conversation
The description of GET /v1/info tells a caller that `ethernet_mac` and `wifi_mac` are "what a caller sends a Wake-on-LAN magic packet to". That is true of one of them. The only magic packet matcher in the tree is `software/u64ctrl/main/wol_magic.c`, and it is reached from a single place, `wifi_modem.c:164` on the ESP32. The setting is `CFG_WAKE_ON_WIFI`, "Wake On Wi-Fi". Nothing equivalent listens on the wired side, so a packet sent to `ethernet_mac` wakes nothing, and a caller who reads the current wording and builds against it gets a feature that does not exist. The same paragraph now also states what the loop below it already does but never said: only the first interface of each kind is reported. The two OpenAPI documents are regenerated from this string rather than edited, so `make openapi_check` still passes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The description of
GET /v1/infoadded in #827 says thatethernet_macandwifi_macare "what a caller sends a Wake-on-LAN magic packet to". That holds for one of the two.The only magic packet matcher in the tree is
software/u64ctrl/main/wol_magic.c, and it is reached from exactly one place,wifi_modem.c:164on the ESP32. The setting isCFG_WAKE_ON_WIFI, "Wake On Wi-Fi", added in #815. There is nothing equivalent on the RMII side — no config item, no matcher, no caller. So a magic packet sent toethernet_macwakes nothing, and someone reading the current wording and building against it gets a feature that does not exist.My fault, and I would rather fix it than leave it: I wrote that sentence.
While the paragraph is open it also gains something the code has always done but never said — only the first interface of each kind is reported,
routes.ccskips any later one withif (reported[kind]) continue;.Both OpenAPI documents are regenerated from the changed string rather than hand-edited, so
make openapi_checkstill passes.Verified
make openapi_check— 2 documents match the sources.make openapi_test— 191 tests, OK.make u64ii_no_espinghcr.io/gideonz/riscv, from a tree with everyoutput/andresult/undertarget/removed first: exit 0, zero errors,routes.cccompiles for both the application and the updater,update.ue2andupdate.cfwproduced.The companion change is GideonZ/1541u-documentation#33, which documents these fields for the first time and now says the same thing. Merging one without the other leaves the two sources disagreeing, which is what prompted this.