On 26 January 2016 at 13:00, Simon Glass <[email protected]> wrote:
> On 26 January 2016 at 11:10, Stephen Warren <[email protected]> wrote:
>> From: Stephen Warren <[email protected]>
>>
>> The existing net test executes a list of commands supplied by boardenv
>> variable env__net_pre_commands. The idea was that boardenv would know
>> whether the Ethernet device was attached to USB, PCI, ... and hence was
>> the best place to put any commands required to probe the device.
>>
>> However, this approach doesn't scale well when attempting to use a single
>> boardenv across multiple branches of U-Boot, some of which require "pci
>> enum" to enumerate PCI and others of which don't, or don't /yet/ simply
>> because various upstream changes haven't been merged down.
>>
>> This patch updates the test to require that the boardenv state which HW
>> features are required for Ethernet to work, and lets the test itself map
>> that knowledge to the set of commands to execute. Since this mapping is
>> part of the test script, which is part of the U-Boot code/branch, this
>> approach is more scalable. It also feels cleaner, since again boardenv
>> is only providing data, rather than test logic.
>>
>> Signed-off-by: Stephen Warren <[email protected]>
>> ---
>>  test/py/tests/test_net.py | 28 +++++++++++++++-------------
>>  1 file changed, 15 insertions(+), 13 deletions(-)
>
> Reviewed-by: Simon Glass <[email protected]>

Applied to u-boot-dm, thanks!
_______________________________________________
U-Boot mailing list
[email protected]
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to