mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 19:21:31 -04:00
pcmcia: simplify locking
replace pcmcia_socket->lock and pcmcia_dev_list_lock by using the per-socket "ops_mutex", as we do neither need different locks nor a spinlock here. Tested-by: Wolfram Sang <[email protected]> Signed-off-by: Dominik Brodowski <[email protected]>
This commit is contained in:
parent
3d3de32fad
commit
00ce99ff50
7 changed files with 51 additions and 77 deletions
|
|
@ -134,7 +134,6 @@ struct pccard_operations {
|
|||
|
||||
struct pcmcia_socket {
|
||||
struct module *owner;
|
||||
spinlock_t lock;
|
||||
socket_state_t socket;
|
||||
u_int state;
|
||||
u_int suspended_state; /* state before suspend */
|
||||
|
|
@ -201,10 +200,12 @@ struct pcmcia_socket {
|
|||
struct task_struct *thread;
|
||||
struct completion thread_done;
|
||||
unsigned int thread_events;
|
||||
/* protects socket h/w state */
|
||||
|
||||
/* For the non-trivial interaction between these locks,
|
||||
* see Documentation/pcmcia/locking.txt */
|
||||
struct mutex skt_mutex;
|
||||
/* protects PCMCIA state */
|
||||
struct mutex ops_mutex;
|
||||
|
||||
/* protects thread_events */
|
||||
spinlock_t thread_lock;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue