[U-Boot] [PATCH 5/5] net: sandbox-raw: Allow interface to be specified by index

Simon Glass sjg at chromium.org
Tue Jun 26 23:18:29 UTC 2018


Hi Joe,

On 26 June 2018 at 14:19, Joe Hershberger <joe.hershberger at ni.com> wrote:
> With systemd stable interface names, eth0 will almost never exist.
> Instead of using that name in the sandbox.dts, use index 2 (the first
> interface after "lo"). Enumerate the interfaces on the system to choose
> a valid interace name.
>
> Signed-off-by: Joe Hershberger <joe.hershberger at ni.com>
> ---
>
>  arch/sandbox/cpu/eth-raw-os.c         | 28 ++++++++++++++++++++++++++++
>  arch/sandbox/dts/sandbox.dts          |  2 +-
>  arch/sandbox/include/asm/eth-raw-os.h |  4 +++-
>  drivers/net/sandbox-raw.c             |  8 +++++++-
>  4 files changed, 39 insertions(+), 3 deletions(-)
>

This seems brittle too. A name seems better to me. I might be missing
something though. Can we ask the OS for a name, etc?

Regards,
Simon


More information about the U-Boot mailing list