-
Notifications
You must be signed in to change notification settings - Fork 3k
Corrected STM eth driver flagging, memory allocation and thread init #6241
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@kjbracey-arm Please review. |
Updated cliapp tests which are now passing. |
/morph build |
Build : FAILUREBuild number : 1331 |
Hmm, mbed-os-example-sockets removes With the feature-emac branch and this commit, that actually kills the Ethernet interface, which is now EMAC-based. Make a feature-emac branch for that socket example and modify CI to test that? Possible/easy @tommikas ? |
Okay, this is a bit of a mess. Basic problem stems from re-using That doesn't scale anyway - we want something similar for other factories - see #6108, and that covers factories not provided by the target. In this particular case, as the driver for the target, we are specifically relying on the "targetness", so couldn't use any proposed "system has default EMAC" flag - someone providing that via a plug-in module and defining it would then trip up STM builds. I think target drivers should be looking at something target-specific - in this case it could be The remaining point is "does the STM driver provide weak EMAC::get_default_instance()"? That would need separate target-specific flagging anyway to cover the case where a target had a separate off-chip EMAC and didn't want to use the STM driver. Neither In short - change |
K64F driver works the same way, but doesn't suffer from apps undefining its |
As @mikaleppanen is away this week, added a change to not use DEVICE_EMAC in a replacement PR #6266. |
Description
Changed STM EMAC ethernet driver RX memory allocation back to pool allocation. It was changed to heap during early phases of EMAC development when pool buffers were not yet implemented. Changed LWIP ethernet enabled flag to DEVICE_EMAC used in feature branch. Added check to RX callback function to check if RX thread has already been created.
Pull request type