- # iterate the physical interfaces and add them to the interfaces list
- for interface in /sys/class/net/eth* /sys/class/net/ath* /sys/class/net/wlan*
- do
- [ -e $interface ] || continue
- i="$(basename $interface)"
+ # iterate the physical interfaces and add them to the interfaces list and also add when ethdevice= called on cmdline
+ if [ "${method}" != dhcp ] || ([ ! -x /root/usr/sbin/NetworkManager ] && [ ! -x /root/usr/sbin/wicd ]) || [ ! -z "${ETHDEVICE}" ]
+ then
+ for interface in /sys/class/net/eth* /sys/class/net/ath* /sys/class/net/wlan*
+ do
+ [ -e ${interface} ] || continue
+ i="$(basename ${interface})"