Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 5 Aug 2003 16:19:28 -0700 (PDT)
From:      Sam Leffler <sam@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 35572 for review
Message-ID:  <200308052319.h75NJS1A073848@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=35572

Change 35572 by sam@sam_ebb on 2003/08/05 16:18:27

	delay creating ic_bss until after the super-class has a chance
	to override the method points for manipulating nodes; this fixes
	a problem where the ic_bss node was not being created properly
	for ath driver causing the driver to scribble on random memory

Affected files ...

.. //depot/projects/netperf/sys/net80211/ieee80211.c#2 edit
.. //depot/projects/netperf/sys/net80211/ieee80211_node.c#2 edit
.. //depot/projects/netperf/sys/net80211/ieee80211_node.h#2 edit

Differences ...

==== //depot/projects/netperf/sys/net80211/ieee80211.c#2 (text+ko) ====

@@ -337,6 +337,7 @@
 
 	if (maxrate)
 		ifp->if_baudrate = IF_Mbps(maxrate);
+	ieee80211_node_lateattach(ifp);		/* XXX */
 #undef ADD
 }
 

==== //depot/projects/netperf/sys/net80211/ieee80211_node.c#2 (text+ko) ====

@@ -86,6 +86,13 @@
 	ic->ic_node_alloc = ieee80211_node_alloc;
 	ic->ic_node_free = ieee80211_node_free;
 	ic->ic_node_copy = ieee80211_node_copy;
+}
+
+void
+ieee80211_node_lateattach(struct ifnet *ifp)
+{
+	struct ieee80211com *ic = (void *)ifp;
+
 	ic->ic_bss = (*ic->ic_node_alloc)(ic);
 	KASSERT(ic->ic_bss != NULL, ("unable to setup inital BSS node"));
 	ic->ic_bss->ni_chan = IEEE80211_CHAN_ANYC;

==== //depot/projects/netperf/sys/net80211/ieee80211_node.h#2 (text+ko) ====

@@ -121,6 +121,7 @@
 struct ieee80211com;
 
 extern	void ieee80211_node_attach(struct ifnet *);
+extern	void ieee80211_node_lateattach(struct ifnet *);
 extern	void ieee80211_node_detach(struct ifnet *);
 
 extern	void ieee80211_begin_scan(struct ifnet *);



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