PERFORCE change 139363 for review

Sam Leffler sam at FreeBSD.org
Fri Apr 4 18:55:52 UTC 2008


http://perforce.freebsd.org/chv.cgi?CH=139363

Change 139363 by sam at sam_ebb on 2008/04/04 18:54:56

	o change ieee80211_vap_setup to return an errno on failure and zero
	  on success
	o add a printf if unable to allocate an ifnet in ieee80211_vap_setup

Affected files ...

.. //depot/projects/vap/sys/net80211/ieee80211.c#37 edit

Differences ...

==== //depot/projects/vap/sys/net80211/ieee80211.c#37 (text+ko) ====

@@ -302,8 +302,9 @@
 
 	ifp = if_alloc(IFT_ETHER);
 	if (ifp == NULL) {
-		/* XXX msg,stat? */
-		return 0;
+		if_printf(ic->ic_ifp, "%s: unable to allocate ifnet\n",
+		    __func__);
+		return ENOMEM;
 	}
 	if_initname(ifp, name, unit);
 	ifp->if_softc = vap;			/* back pointer */
@@ -400,7 +401,7 @@
 	ieee80211_scan_vattach(vap);
 	ieee80211_regdomain_vattach(vap);
 
-	return 1;
+	return 0;
 #undef IEEE80211_C_OPMODE
 }
 


More information about the p4-projects mailing list