Only call aspeednic_init when preparing to use network #4
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 aspeednic driver was calling init from its initialization function and
calling halt later. This left the DMA engine running and writing to
memory when Ethernet traffic arrived when control was handed off
to the operating system.
Remove this call to init and rely on the framework to call
write_hwaddr with the assigned MAC address.
In addition upstream discourages setting the random address in
drivers. Later upstream created a config for this behavior and I
back-ported that patch.
In my testing, the random mac address is about 90% 1 value after a
u-boot reset command but after a kernel reboot it does not repeat.
The code uses rand with timer as the seed source; the network stack
then uses the mac as the seed for random delays. We may prefer
to only configure u-boot setting a random mac only after a better
source of entropy, letting the kernel use its sources to set it when
we do not net-boot.
milton
v2: update README and README.ethaddr with backported CONFIG var name.
This change is