diff options
author | Greg Kroah-Hartman <gregkh@google.com> | 2016-03-22 14:30:35 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@google.com> | 2016-03-22 16:47:28 -0400 |
commit | 0ec306324423444d3ee0222708ef9de7f5586b93 (patch) | |
tree | 3d6ad3817d35074b12b8d92162437e03f6ce2372 /drivers/staging/greybus/i2c.c | |
parent | 418f3dab841f85e24beb6e30858cafce5cf1f87c (diff) |
greybus: convert drivers to use connection->private set/get
This converts all drivers to use the gb_connection_get_data() and
gb_connection_set_data() functions to make it a bit more explicit as to
what is going on.
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Reviewed-by: Alex Elder <elder@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Diffstat (limited to 'drivers/staging/greybus/i2c.c')
-rw-r--r-- | drivers/staging/greybus/i2c.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/greybus/i2c.c b/drivers/staging/greybus/i2c.c index 4b96f69318bd..73b85815d1eb 100644 --- a/drivers/staging/greybus/i2c.c +++ b/drivers/staging/greybus/i2c.c @@ -251,7 +251,7 @@ static int gb_i2c_connection_init(struct gb_connection *connection) return -ENOMEM; gb_i2c_dev->connection = connection; /* refcount? */ - connection->private = gb_i2c_dev; + gb_connection_set_data(connection, gb_i2c_dev); ret = gb_i2c_device_setup(gb_i2c_dev); if (ret) @@ -282,7 +282,7 @@ out_err: static void gb_i2c_connection_exit(struct gb_connection *connection) { - struct gb_i2c_device *gb_i2c_dev = connection->private; + struct gb_i2c_device *gb_i2c_dev = gb_connection_get_data(connection); i2c_del_adapter(&gb_i2c_dev->adapter); /* kref_put(gb_i2c_dev->connection) */ |