greybus: connection: make connection enable/disable thread safe
authorJohan Hovold <johan@hovoldconsulting.com>
Tue, 19 Jan 2016 11:51:06 +0000 (12:51 +0100)
committerGreg Kroah-Hartman <gregkh@google.com>
Tue, 19 Jan 2016 20:12:40 +0000 (12:12 -0800)
commit23268785b288c25ab5ee2ec523982546b5353880
tree48256ebfa0e72a2de740cfd6f7a214e6a59d498a
parent192bee4b1a7adbf16d12721c77d6268c76428323
greybus: connection: make connection enable/disable thread safe

Add connection mutex to protect connection enabling and disabling.

This is needed to eventually allow drivers to manage the state of their
connections during operation (i.e. post probe and pre disconnect).

Reviewed-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Johan Hovold <johan@hovoldconsulting.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
drivers/staging/greybus/connection.c
drivers/staging/greybus/connection.h