From 77197f9ce40e611279a280b8dd8f1ab71762a5de Mon Sep 17 00:00:00 2001 From: Andrew Thompson Date: Sat, 10 May 2008 20:25:59 +0000 Subject: [PATCH] Only start the vaps if the init routine completed. --- sys/dev/ipw/if_ipw.c | 3 ++- sys/dev/ral/rt2560.c | 3 ++- sys/dev/ral/rt2661.c | 3 ++- sys/dev/wi/if_wi.c | 3 ++- 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/sys/dev/ipw/if_ipw.c b/sys/dev/ipw/if_ipw.c index b2fda279fa5c..45a418efa3e7 100644 --- a/sys/dev/ipw/if_ipw.c +++ b/sys/dev/ipw/if_ipw.c @@ -2404,7 +2404,8 @@ ipw_init(void *priv) ipw_init_locked(sc); IPW_UNLOCK(sc); - ieee80211_start_all(ic); + if (ifp->if_drv_flags & IFF_DRV_RUNNING) + ieee80211_start_all(ic); /* start all vap's */ } static void diff --git a/sys/dev/ral/rt2560.c b/sys/dev/ral/rt2560.c index 17a72010057c..9fd4346fa3b7 100644 --- a/sys/dev/ral/rt2560.c +++ b/sys/dev/ral/rt2560.c @@ -2726,7 +2726,8 @@ rt2560_init(void *priv) rt2560_init_locked(sc); RAL_UNLOCK(sc); - ieee80211_start_all(ic); + if (ifp->if_drv_flags & IFF_DRV_RUNNING) + ieee80211_start_all(ic); /* start all vap's */ } static void diff --git a/sys/dev/ral/rt2661.c b/sys/dev/ral/rt2661.c index 691ac3881df9..a197f4d983d3 100644 --- a/sys/dev/ral/rt2661.c +++ b/sys/dev/ral/rt2661.c @@ -2471,7 +2471,8 @@ rt2661_init(void *priv) rt2661_init_locked(sc); RAL_UNLOCK(sc); - ieee80211_start_all(ic); + if (ifp->if_drv_flags & IFF_DRV_RUNNING) + ieee80211_start_all(ic); /* start all vap's */ } void diff --git a/sys/dev/wi/if_wi.c b/sys/dev/wi/if_wi.c index 3a84f161bf59..b13d4dcfdb9b 100644 --- a/sys/dev/wi/if_wi.c +++ b/sys/dev/wi/if_wi.c @@ -703,7 +703,8 @@ wi_init(void *arg) wi_init_locked(sc); WI_UNLOCK(sc); - ieee80211_start_all(ic); + if (ifp->if_drv_flags & IFF_DRV_RUNNING) + ieee80211_start_all(ic); /* start all vap's */ } static void