diff options
author | Tomas Winkler <tomas.winkler@intel.com> | 2015-02-10 10:39:31 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-03-01 19:36:59 -0800 |
commit | b7d885145538ddedb1ae23b782ab7c7c0a856e9f (patch) | |
tree | 9470b5807362a068e85487a429fb3b3f543af53e /drivers/misc/mei/init.c | |
parent | e9395e3f8952110bda60b54ad03ec52c6e9c7dbd (diff) | |
download | linux-b7d885145538ddedb1ae23b782ab7c7c0a856e9f.tar.bz2 |
mei: revamp me clients list handling
1. Use rw lock to access the me_clients list
2. Reuse already defined find functions also when
removing particular me client
3. Add wrappers for addition and deletion
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc/mei/init.c')
-rw-r--r-- | drivers/misc/mei/init.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/misc/mei/init.c b/drivers/misc/mei/init.c index 9306219d5675..106c054f573f 100644 --- a/drivers/misc/mei/init.c +++ b/drivers/misc/mei/init.c @@ -387,6 +387,7 @@ void mei_device_init(struct mei_device *dev, INIT_LIST_HEAD(&dev->device_list); INIT_LIST_HEAD(&dev->me_clients); mutex_init(&dev->device_lock); + init_rwsem(&dev->me_clients_rwsem); init_waitqueue_head(&dev->wait_hw_ready); init_waitqueue_head(&dev->wait_pg); init_waitqueue_head(&dev->wait_hbm_start); |