To start bnx2fc, we need to run fipvlan only and not dcbtool. DCBX is run
automatically in the hardware, but VLAN discovery needs to be started by
fipvlan.
https://bugzilla.redhat.com/show_bug.cgi?id=736094
ip link set "$netif" up
wait_for_if_up "$netif"
+netdriver=$(readlink -f /sys/class/net/$netif/device/driver)
+netdriver=${netdriver##*/}
+
if [ "$dcb" = "dcb" ]; then
# Note lldpad will stay running after switchroot, the system initscripts
# are to kill it and start a new lldpad to take over. Data is transfered
dcbtool sc "$netif" app:fcoe e:1 a:1 w:1
sleep 1
fipvlan "$netif" -c -s
+elif [ "$netdriver" = "bnx2x" ]; then
+ # If driver is bnx2x, do not use /sys/module/fcoe/parameters/create but fipvlan
+ modprobe 8021q
+ udevadm settle --timeout=30
+ fipvlan "$netif" -c -s
else
echo -n "$netif" > /sys/module/fcoe/parameters/create
fi
inst dcbtool
inst fipvlan
inst lldpad
+ inst readlink
mkdir -m 0755 -p "$initdir/var/lib/lldpad"
# If it's not set we don't continue
[ -z "$fcoe" ] && return
+
+# BRCM: Later, should check whether bnx2x is loaded first before loading bnx2fc so do not load bnx2fc when there are no Broadcom adapters
+[ -e /sys/module/fcoe/parameters/create ] || modprobe -a fcoe || die "FCoE requested but kernel/initrd does not support FCoE"
+
+modprobe bnx2fc >/dev/null 2>&1
+udevadm settle --timeout=30
+
# FCoE actually supported?
[ -e /sys/module/fcoe/parameters/create ] || modprobe fcoe || die "FCoE requested but kernel/initrd does not support FCoE"