Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 8 May 2013 18:25:46 +0000 (UTC)
From:      David C Somayajulu <davidcs@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r250375 - head/sys/dev/qlxgb
Message-ID:  <201305081825.r48IPk8X027933@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: davidcs
Date: Wed May  8 18:25:46 2013
New Revision: 250375
URL: http://svnweb.freebsd.org/changeset/base/250375

Log:
  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>

Modified:
  head/sys/dev/qlxgb/qla_os.c

Modified: head/sys/dev/qlxgb/qla_os.c
==============================================================================
--- head/sys/dev/qlxgb/qla_os.c	Wed May  8 17:45:22 2013	(r250374)
+++ head/sys/dev/qlxgb/qla_os.c	Wed May  8 18:25:46 2013	(r250375)
@@ -669,8 +669,7 @@ qla_init_ifnet(device_t dev, qla_host_t 
 
 	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 
 				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;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201305081825.r48IPk8X027933>