diff options
author | Dominik Brodowski <linux@dominikbrodowski.net> | 2010-01-12 15:42:51 -0500 |
---|---|---|
committer | Dominik Brodowski <linux@dominikbrodowski.net> | 2010-02-17 11:48:13 -0500 |
commit | 6b8e087b86c59c3941e125738d30cf38014089e0 (patch) | |
tree | 08f77e50e5237e3bbe5e4c8f114fddc09f242628 /drivers/pcmcia/cs.c | |
parent | c6958fdb041db6ed77f24e871dd4af5f059d1a2b (diff) |
pcmcia: add locking to set_mem_map()
Protect the pccard_operations callback "set_mem_map" by a new
mutex ops_mutex. This mutex also protects the following values
in struct pcmcia_socket:
pccard_mem_map win[]
pccard_mem_map cis_mem
void __iomem *cis_virt
Tested-by: Wolfram Sang <w.sang@pengutronix.de>
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Diffstat (limited to 'drivers/pcmcia/cs.c')
-rw-r--r-- | drivers/pcmcia/cs.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/pcmcia/cs.c b/drivers/pcmcia/cs.c index 43c90f69a7a5..91aa1f284068 100644 --- a/drivers/pcmcia/cs.c +++ b/drivers/pcmcia/cs.c | |||
@@ -222,6 +222,7 @@ int pcmcia_register_socket(struct pcmcia_socket *socket) | |||
222 | init_completion(&socket->socket_released); | 222 | init_completion(&socket->socket_released); |
223 | init_completion(&socket->thread_done); | 223 | init_completion(&socket->thread_done); |
224 | mutex_init(&socket->skt_mutex); | 224 | mutex_init(&socket->skt_mutex); |
225 | mutex_init(&socket->ops_mutex); | ||
225 | spin_lock_init(&socket->thread_lock); | 226 | spin_lock_init(&socket->thread_lock); |
226 | 227 | ||
227 | if (socket->resource_ops->init) { | 228 | if (socket->resource_ops->init) { |