Commit de3557d9 authored by Alex Elder's avatar Alex Elder Committed by Greg Kroah-Hartman

greybus: rename greybus_cport_in()

This function is associated with a host device (interface), not a
CPort.  Change its name to reflect that, and to match its "sent"
callback counterpart.
Signed-off-by: default avatarAlex Elder <elder@linaro.org>
Signed-off-by: default avatarGreg Kroah-Hartman <greg@kroah.com>
parent d98b52b0
...@@ -29,7 +29,11 @@ struct gb_connection *gb_hd_connection_find(struct greybus_host_device *hd, ...@@ -29,7 +29,11 @@ struct gb_connection *gb_hd_connection_find(struct greybus_host_device *hd,
return connection; return connection;
} }
void greybus_cport_in(struct greybus_host_device *hd, u16 cport_id, /*
* Callback from the host driver to let us know that data has been
* received on the interface.
*/
void greybus_data_rcvd(struct greybus_host_device *hd, u16 cport_id,
u8 *data, size_t length) u8 *data, size_t length)
{ {
struct gb_connection *connection; struct gb_connection *connection;
...@@ -42,7 +46,7 @@ void greybus_cport_in(struct greybus_host_device *hd, u16 cport_id, ...@@ -42,7 +46,7 @@ void greybus_cport_in(struct greybus_host_device *hd, u16 cport_id,
} }
gb_connection_recv(connection, data, length); gb_connection_recv(connection, data, length);
} }
EXPORT_SYMBOL_GPL(greybus_cport_in); EXPORT_SYMBOL_GPL(greybus_data_rcvd);
/* /*
* Allocate an available CPort Id for use for the host side of the * Allocate an available CPort Id for use for the host side of the
......
...@@ -53,7 +53,7 @@ void gb_connection_exit(struct gb_connection *connection); ...@@ -53,7 +53,7 @@ void gb_connection_exit(struct gb_connection *connection);
struct gb_connection *gb_hd_connection_find(struct greybus_host_device *hd, struct gb_connection *gb_hd_connection_find(struct greybus_host_device *hd,
u16 cport_id); u16 cport_id);
void greybus_cport_in(struct greybus_host_device *hd, u16 cport_id, void greybus_data_rcvd(struct greybus_host_device *hd, u16 cport_id,
u8 *data, size_t length); u8 *data, size_t length);
__printf(2, 3) __printf(2, 3)
void gb_connection_err(struct gb_connection *connection, const char *fmt, ...); void gb_connection_err(struct gb_connection *connection, const char *fmt, ...);
......
...@@ -392,7 +392,7 @@ static void cport_in_callback(struct urb *urb) ...@@ -392,7 +392,7 @@ static void cport_in_callback(struct urb *urb)
data = &data[1]; data = &data[1];
/* Pass this data to the greybus core */ /* Pass this data to the greybus core */
greybus_cport_in(hd, cport_id, data, urb->actual_length - 1); greybus_data_rcvd(hd, cport_id, data, urb->actual_length - 1);
exit: exit:
/* put our urb back in the request pool */ /* put our urb back in the request pool */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment