summaryrefslogtreecommitdiff
path: root/drivers/staging/greybus/connection.h
diff options
context:
space:
mode:
authorAlex Elder <elder@linaro.org>2014-11-12 15:17:54 -0600
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-11-14 13:11:35 -0800
commit360a8779d96c7c592ee79d035afe9bdf05695204 (patch)
tree7afb98af9e9f7f6d8e385e1b901548a7f80f4184 /drivers/staging/greybus/connection.h
parentb8616da875ea2f36bdeaff49f1373ea1e37406f4 (diff)
greybus: op_cycle doesn't need to be atomic
We can update a connection's operation id counter under spinlock, and thereby avoid the need to maintain it in an atomic variable. Signed-off-by: Alex Elder <elder@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/greybus/connection.h')
-rw-r--r--drivers/staging/greybus/connection.h4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/staging/greybus/connection.h b/drivers/staging/greybus/connection.h
index 861e0661157c..3aa86955b748 100644
--- a/drivers/staging/greybus/connection.h
+++ b/drivers/staging/greybus/connection.h
@@ -35,9 +35,9 @@ struct gb_connection {
enum gb_connection_state state;
+ u16 op_cycle;
struct list_head operations;
struct list_head pending; /* awaiting reponse */
- atomic_t op_cycle;
void *private;
};
@@ -53,8 +53,6 @@ void gb_connection_exit(struct gb_connection *connection);
struct gb_connection *gb_hd_connection_find(struct greybus_host_device *hd,
u16 cport_id);
-u16 gb_connection_operation_id(struct gb_connection *connection);
-
__printf(2, 3)
void gb_connection_err(struct gb_connection *connection, const char *fmt, ...);