Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 23 Apr 2009 17:33:32 +0000 (UTC)
From:      Andrew Thompson <thompsa@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-user@freebsd.org
Subject:   svn commit: r191431 - user/thompsa/vaptq/sys/dev/ipw
Message-ID:  <200904231733.n3NHXW3Z094825@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: thompsa
Date: Thu Apr 23 17:33:31 2009
New Revision: 191431
URL: http://svn.freebsd.org/changeset/base/191431

Log:
  ieee80211_new_state() can be called directly from the interrupt handler so
  remove the deferred tasks for this.

Modified:
  user/thompsa/vaptq/sys/dev/ipw/if_ipw.c
  user/thompsa/vaptq/sys/dev/ipw/if_ipwvar.h

Modified: user/thompsa/vaptq/sys/dev/ipw/if_ipw.c
==============================================================================
--- user/thompsa/vaptq/sys/dev/ipw/if_ipw.c	Thu Apr 23 17:31:24 2009	(r191430)
+++ user/thompsa/vaptq/sys/dev/ipw/if_ipw.c	Thu Apr 23 17:33:31 2009	(r191431)
@@ -118,8 +118,6 @@ static void	ipw_media_status(struct ifne
 static int	ipw_newstate(struct ieee80211vap *, enum ieee80211_state, int);
 static uint16_t	ipw_read_prom_word(struct ipw_softc *, uint8_t);
 static void	ipw_rx_cmd_intr(struct ipw_softc *, struct ipw_soft_buf *);
-static void	ipw_assocsuccess(void *, int);
-static void	ipw_assocfailed(void *, int);
 static void	ipw_rx_newstate_intr(struct ipw_softc *, struct ipw_soft_buf *);
 static void	ipw_rx_data_intr(struct ipw_softc *, struct ipw_status *,
 		    struct ipw_soft_bd *, struct ipw_soft_buf *);
@@ -504,9 +502,6 @@ ipw_vap_create(struct ieee80211com *ic,
 		return NULL;
 	vap = &ivp->vap;
 
-	TASK_INIT(&ivp->assoc_success_task, 0, ipw_assocsuccess, vap);
-	TASK_INIT(&ivp->assoc_failed_task, 0, ipw_assocfailed, vap);
-
 	ieee80211_vap_setup(ic, vap, name, unit, opmode, flags, bssid, mac);
 	/* override with driver methods */
 	ivp->newstate = vap->iv_newstate;
@@ -1008,22 +1003,6 @@ ipw_rx_cmd_intr(struct ipw_softc *sc, st
 }
 
 static void
-ipw_assocsuccess(void *arg, int npending)
-{
-	struct ieee80211vap *vap = arg;
-
-	ieee80211_new_state(vap, IEEE80211_S_RUN, -1);
-}
-
-static void
-ipw_assocfailed(void *arg, int npending)
-{
-	struct ieee80211vap *vap = arg;
-
-	ieee80211_new_state(vap, IEEE80211_S_SCAN, -1);
-}
-
-static void
 ipw_rx_newstate_intr(struct ipw_softc *sc, struct ipw_soft_buf *sbuf)
 {
 #define	IEEESTATE(vap)	ieee80211_state_name[vap->iv_state]
@@ -1048,8 +1027,7 @@ ipw_rx_newstate_intr(struct ipw_softc *s
 		}
 		sc->flags &= ~IPW_FLAG_ASSOCIATING;
 		sc->flags |= IPW_FLAG_ASSOCIATED;
-		taskqueue_enqueue(taskqueue_swi,
-		    &IPW_VAP(vap)->assoc_success_task);
+		ieee80211_new_state(vap, IEEE80211_S_RUN, -1);
 		break;
 
 	case IPW_STATE_SCANNING:
@@ -1093,8 +1071,7 @@ ipw_rx_newstate_intr(struct ipw_softc *s
 			IEEESTATE(vap), sc->flags));
 		sc->flags &= ~(IPW_FLAG_ASSOCIATING | IPW_FLAG_ASSOCIATED);
 		if (vap->iv_state == IEEE80211_S_RUN)
-			taskqueue_enqueue(taskqueue_swi,
-			    &IPW_VAP(vap)->assoc_failed_task);
+			ieee80211_new_state(vap, IEEE80211_S_SCAN, -1);
 		break;
 
 	case IPW_STATE_DISABLED:

Modified: user/thompsa/vaptq/sys/dev/ipw/if_ipwvar.h
==============================================================================
--- user/thompsa/vaptq/sys/dev/ipw/if_ipwvar.h	Thu Apr 23 17:31:24 2009	(r191430)
+++ user/thompsa/vaptq/sys/dev/ipw/if_ipwvar.h	Thu Apr 23 17:33:31 2009	(r191431)
@@ -78,8 +78,6 @@ struct ipw_tx_radiotap_header {
 
 struct ipw_vap {
 	struct ieee80211vap	vap;
-	struct task		assoc_success_task;
-	struct task		assoc_failed_task;
 
 	int			(*newstate)(struct ieee80211vap *,
 				    enum ieee80211_state, int);
@@ -92,7 +90,6 @@ struct ipw_softc {
 
 	struct mtx			sc_mtx;
 	struct task			sc_init_task;
-	struct task			sc_bmiss_task;
 	struct callout			sc_wdtimer;	/* watchdog timer */
 
 	uint32_t			flags;



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