net: on ifup -a only detect devices when necessary
For network boot we once used to hardcode eth0, but in latest changes
this was changed to work with different network devices and the 'ifup
eth0' was replaced with 'ifup -a' which lead to the result that we now
detect all devices in order to eventually also bring up USB network
adapters. In most of the cases this is not desired. When a board has
internal network support this is likely to be used. With this patch
we only detect all devices when we do not have a network device already.
For the unusual case in which a USB network adapter shall be used
even when an internal network interface is present we introduce the
global variable "global.net.ifup_force_detect" which can be used to
force detection of devices.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
1 parent bd9ad3a commit b0f7425f922d371737804a5a9a213232c6fe0265
@Sascha Hauer Sascha Hauer authored on 6 Apr 2018
Showing 2 changed files
View
Documentation/user/networking.rst
View
net/ifup.c