aboutsummaryrefslogtreecommitdiffstats
path: root/sysconfig/network-scripts/ifup-eth
diff options
context:
space:
mode:
Diffstat (limited to 'sysconfig/network-scripts/ifup-eth')
-rwxr-xr-xsysconfig/network-scripts/ifup-eth8
1 files changed, 3 insertions, 5 deletions
diff --git a/sysconfig/network-scripts/ifup-eth b/sysconfig/network-scripts/ifup-eth
index cbea96a2..2cf5d6d1 100755
--- a/sysconfig/network-scripts/ifup-eth
+++ b/sysconfig/network-scripts/ifup-eth
@@ -114,9 +114,7 @@ fi
# Bonding initialization. For DHCP, we need to enslave the devices early,
# so it can actually get an IP.
-if [ "$ISALIAS" = no ] && \
- { [ "${TYPE}" = "Bonding" ] \
- || ethtool -i $DEVICE 2>/dev/null | grep -q "driver: bonding"; } then
+if [ "$ISALIAS" = no ] && is_bonding_device ${DEVICE} ; then
/sbin/ip link set dev ${DEVICE} down
/sbin/ip link set dev ${DEVICE} up
[ -n "${LINKDELAY}" ] && /bin/sleep ${LINKDELAY}
@@ -201,7 +199,7 @@ else
fi
[ -n "${LINKDELAY}" ] && /bin/sleep ${LINKDELAY}
# Bonding initialization part II
- if [ "${TYPE}" = "Bonding" ] || ethtool -i $DEVICE 2>/dev/null| grep -q "driver: bonding" ; then
+ if is_bonding_device ${DEVICE} ; then
for device in `LANG=C grep -l "^[[:space:]]*MASTER=${DEVICE}" /etc/sysconfig/network-scripts/ifcfg-*` ; do
is_ignored_file "$device" && continue
/sbin/ifup ${device##*/}
@@ -278,7 +276,7 @@ fi
# Bonding initialization part II - for static, enslave the devices. For
# DHCP, remove any routes for the slaves.
-if [ "${TYPE}" = "Bonding" ] || ethtool -i $DEVICE 2>/dev/null| grep -q "driver: bonding" ; then
+if is_bonding_device ${DEVICE} ; then
for device in `LANG=C grep -l "^[[:space:]]*MASTER=${DEVICE}" /etc/sysconfig/network-scripts/ifcfg-*` ; do
is_ignored_file "$device" && continue
if [ "$BOOTPROTO" = "dhcp" ]; then