Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (37 commits) smc91c92_cs: fix the problem of "Unable to find hardware address" r8169: clean up my printk uglyness net: Hook up cxgb4 to Kconfig and Makefile cxgb4: Add main driver file and driver Makefile cxgb4: Add remaining driver headers and L2T management cxgb4: Add packet queues and packet DMA code cxgb4: Add HW and FW support code cxgb4: Add register, message, and FW definitions netlabel: Fix several rcu_dereference() calls used without RCU read locks bonding: fix potential deadlock in bond_uninit() net: check the length of the socket address passed to connect(2) stmmac: add documentation for the driver. stmmac: fix kconfig for crc32 build error be2net: fix bug in vlan rx path for big endian architecture be2net: fix flashing on big endian architectures be2net: fix a bug in flashing the redboot section bonding: bond_xmit_roundrobin() fix drivers/net: Add missing unlock net: gianfar - align BD ring size console messages net: gianfar - initialize per-queue statistics ...
This commit is contained in:
@@ -325,7 +325,7 @@ struct reg_regdb_search_request {
|
||||
};
|
||||
|
||||
static LIST_HEAD(reg_regdb_search_list);
|
||||
static DEFINE_SPINLOCK(reg_regdb_search_lock);
|
||||
static DEFINE_MUTEX(reg_regdb_search_mutex);
|
||||
|
||||
static void reg_regdb_search(struct work_struct *work)
|
||||
{
|
||||
@@ -333,7 +333,7 @@ static void reg_regdb_search(struct work_struct *work)
|
||||
const struct ieee80211_regdomain *curdom, *regdom;
|
||||
int i, r;
|
||||
|
||||
spin_lock(®_regdb_search_lock);
|
||||
mutex_lock(®_regdb_search_mutex);
|
||||
while (!list_empty(®_regdb_search_list)) {
|
||||
request = list_first_entry(®_regdb_search_list,
|
||||
struct reg_regdb_search_request,
|
||||
@@ -347,18 +347,16 @@ static void reg_regdb_search(struct work_struct *work)
|
||||
r = reg_copy_regd(®dom, curdom);
|
||||
if (r)
|
||||
break;
|
||||
spin_unlock(®_regdb_search_lock);
|
||||
mutex_lock(&cfg80211_mutex);
|
||||
set_regdom(regdom);
|
||||
mutex_unlock(&cfg80211_mutex);
|
||||
spin_lock(®_regdb_search_lock);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
kfree(request);
|
||||
}
|
||||
spin_unlock(®_regdb_search_lock);
|
||||
mutex_unlock(®_regdb_search_mutex);
|
||||
}
|
||||
|
||||
static DECLARE_WORK(reg_regdb_work, reg_regdb_search);
|
||||
@@ -376,9 +374,9 @@ static void reg_regdb_query(const char *alpha2)
|
||||
|
||||
memcpy(request->alpha2, alpha2, 2);
|
||||
|
||||
spin_lock(®_regdb_search_lock);
|
||||
mutex_lock(®_regdb_search_mutex);
|
||||
list_add_tail(&request->list, ®_regdb_search_list);
|
||||
spin_unlock(®_regdb_search_lock);
|
||||
mutex_unlock(®_regdb_search_mutex);
|
||||
|
||||
schedule_work(®_regdb_work);
|
||||
}
|
||||
|
Reference in New Issue
Block a user