diff options
author | Bill Nottingham <notting@redhat.com> | 2011-08-31 14:51:38 -0400 |
---|---|---|
committer | Lukas Nykryn <lnykryn@redhat.com> | 2012-10-08 13:32:49 +0200 |
commit | 3486899bd3a2e835c444fe966acb30c5193e990e (patch) | |
tree | 0e5fe0208fe08de8c80a2ee905ce98b2aef4ce68 /sysconfig/network-scripts | |
parent | f00f8d9e9f6a7382011166dbbef59eedce990b48 (diff) | |
download | initscripts-3486899bd3a2e835c444fe966acb30c5193e990e.tar initscripts-3486899bd3a2e835c444fe966acb30c5193e990e.tar.gz initscripts-3486899bd3a2e835c444fe966acb30c5193e990e.tar.bz2 initscripts-3486899bd3a2e835c444fe966acb30c5193e990e.tar.xz initscripts-3486899bd3a2e835c444fe966acb30c5193e990e.zip |
Add support for setting random bridge options via BRIDGING_OPTS. (#734045, #665378)
Diffstat (limited to 'sysconfig/network-scripts')
-rwxr-xr-x | sysconfig/network-scripts/ifup-eth | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/sysconfig/network-scripts/ifup-eth b/sysconfig/network-scripts/ifup-eth index d3adb143..1c09fd76 100755 --- a/sysconfig/network-scripts/ifup-eth +++ b/sysconfig/network-scripts/ifup-eth @@ -61,6 +61,12 @@ if [ "${TYPE}" = "Bridge" ]; then fi [ -n "${DELAY}" ] && /usr/sbin/brctl setfd ${DEVICE} ${DELAY} [ -n "${STP}" ] && /usr/sbin/brctl stp ${DEVICE} ${STP} + # add the bits to setup driver parameters here + for arg in $BRIDGING_OPTS ; do + key=${arg%%=*}; + value=${arg##*=}; + echo $value > /sys/class/net/${DEVICE}/bridge/$key + done fi # If the device is a tap device, create it with tunctl, if available. @@ -164,6 +170,12 @@ if [ -n "${BRIDGE}" -a -x /usr/sbin/brctl ]; then ethtool_set [ -n "${LINKDELAY}" ] && /bin/sleep ${LINKDELAY} /usr/sbin/brctl addif ${BRIDGE} ${DEVICE} + # add the bits to setup driver parameters here + for arg in $BRIDGING_OPTS ; do + key=${arg%%=*}; + value=${arg##*=}; + echo $value > /sys/class/net/${DEVICE}/brport/$key + done # Upon adding a device to a bridge, # it's necessary to make radvd reload its config [ -r /var/run/radvd/radvd.pid ] && kill -HUP $(cat /var/run/radvd/radvd.pid) |