summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordavidcs <davidcs@FreeBSD.org>2013-05-08 18:25:46 +0000
committerdavidcs <davidcs@FreeBSD.org>2013-05-08 18:25:46 +0000
commitd59507806675c29c427a3989dacb5d4f12da6be3 (patch)
tree013d2c19944b8e2f20b5d60daf9113f54a12c345
parent55fe0cb833adb732625dc8457434d8e8ed2e799b (diff)
downloadFreeBSD-src-d59507806675c29c427a3989dacb5d4f12da6be3.zip
FreeBSD-src-d59507806675c29c427a3989dacb5d4f12da6be3.tar.gz
No need to set if_mtu since it automatically updated by ether_ifattach().
Use if_initbaudrate() to set baudrate. Add IFCAP_LINKSTATE to if_capabilities. Submitted by: David C Somayajulu <davidcs@freebsd.org> Approved by: George Neville-Neil <gnn@freebsd.org>
-rw-r--r--sys/dev/qlxgb/qla_os.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/qlxgb/qla_os.c b/sys/dev/qlxgb/qla_os.c
index 7f622e3..a9472bf 100644
--- a/sys/dev/qlxgb/qla_os.c
+++ b/sys/dev/qlxgb/qla_os.c
@@ -669,8 +669,7 @@ qla_init_ifnet(device_t dev, qla_host_t *ha)
if_initname(ifp, device_get_name(dev), device_get_unit(dev));
- ifp->if_mtu = ETHERMTU;
- ifp->if_baudrate = (1 * 1000 * 1000 *1000);
+ if_initbaudrate(ifp, IF_Gbps(10));
ifp->if_init = qla_init;
ifp->if_softc = ha;
ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST;
@@ -690,6 +689,7 @@ qla_init_ifnet(device_t dev, qla_host_t *ha)
IFCAP_JUMBO_MTU;
ifp->if_capabilities |= IFCAP_VLAN_HWTAGGING | IFCAP_VLAN_MTU;
+ ifp->if_capabilities |= IFCAP_LINKSTATE;
#if defined(__FreeBSD_version) && (__FreeBSD_version < 900002)
ifp->if_timer = 0;
OpenPOWER on IntegriCloud