feat: add GENET v5 Ethernet driver

This commit is contained in:
daniel committed 2026-10-26 08:10:20 +01:00
1 parent 3310b3d6de
commit 1d00c1c016
10 files changed
+1080 -11

No files matched your search

+12 -6
View File
@@ -250,16 +250,22 @@ extern "C" void _start() {
montauk::service_log("MontaukOS DHCP Client");
// 0. Check if any device with an up link even exists.
// 0. Check if any device with an up link even exists. A wired PHY
// still autonegotiating at boot (a few seconds after its reset) gets
// a grace period; with no wired interface at all there is nothing to
// wait for.
montauk::abi::NetIfInfo ifs[4];
int n = montauk::net_interfaces(ifs, 4);
bool link = false;
for (int i = 0; i < n; i++) {
if (ifs[i].linkUp == true) {
link = true;
for (int attempt = 0; attempt < 40 && !link; attempt++) {
int n = montauk::net_interfaces(ifs, 4);
bool wired = false;
for (int i = 0; i < n; i++) {
if (ifs[i].linkUp) link = true;
if (ifs[i].kind == montauk::abi::NETIF_KIND_ETHERNET) wired = true;
}
if (link || !wired) break;
montauk::sleep_ms(250);
}
if (link == false) {