diff options
author | Paul Kocialkowski <contact@paulk.fr> | 2014-02-24 14:57:48 +0100 |
---|---|---|
committer | Paul Kocialkowski <contact@paulk.fr> | 2014-02-24 14:57:48 +0100 |
commit | 738b07dfd6ef709e0802a33ab3d66fdf22d3a68a (patch) | |
tree | e70d6e503cd83704308f64ff77c2dc459d7ed321 | |
parent | 121ae6d21c18dd79ed1dc7df4c86a681d70a337a (diff) | |
download | external_libsamsung-ipc-738b07dfd6ef709e0802a33ab3d66fdf22d3a68a.zip external_libsamsung-ipc-738b07dfd6ef709e0802a33ab3d66fdf22d3a68a.tar.gz external_libsamsung-ipc-738b07dfd6ef709e0802a33ab3d66fdf22d3a68a.tar.bz2 |
ipc_utils: Enumerate send first, then recv
Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
-rw-r--r-- | include/samsung-ipc.h | 4 | ||||
-rw-r--r-- | samsung-ipc/ipc_utils.c | 20 |
2 files changed, 12 insertions, 12 deletions
diff --git a/include/samsung-ipc.h b/include/samsung-ipc.h index 669d4d8..7240472 100644 --- a/include/samsung-ipc.h +++ b/include/samsung-ipc.h @@ -113,10 +113,10 @@ const char *ipc_response_type_string(unsigned char type); const char *ipc_command_string(unsigned short command); void ipc_hex_dump(struct ipc_client *client, const void *data, size_t size); -void ipc_client_log_recv(struct ipc_client *client, struct ipc_message *message, - const char *prefix); void ipc_client_log_send(struct ipc_client *client, struct ipc_message *message, const char *prefix); +void ipc_client_log_recv(struct ipc_client *client, struct ipc_message *message, + const char *prefix); int ipc_fmt_header_setup(struct ipc_fmt_header *header, const struct ipc_message *message); diff --git a/samsung-ipc/ipc_utils.c b/samsung-ipc/ipc_utils.c index 6e8d190..5393453 100644 --- a/samsung-ipc/ipc_utils.c +++ b/samsung-ipc/ipc_utils.c @@ -401,7 +401,7 @@ void ipc_hex_dump(struct ipc_client *client, const void *data, size_t size) } } -void ipc_client_log_recv(struct ipc_client *client, struct ipc_message *message, +void ipc_client_log_send(struct ipc_client *client, struct ipc_message *message, const char *prefix) { if (client == NULL || message == NULL || prefix == NULL) @@ -409,8 +409,8 @@ void ipc_client_log_recv(struct ipc_client *client, struct ipc_message *message, switch (client->type) { case IPC_CLIENT_TYPE_FMT: - ipc_client_log(client, "%s: Received FMT message", prefix); - ipc_client_log(client, "%s: Message: aseq=0x%02x, command=%s, type=%s, size=%d", prefix, message->aseq, ipc_command_string(message->command), ipc_response_type_string(message->type), message->size); + ipc_client_log(client, "%s: Sent FMT message", prefix); + ipc_client_log(client, "%s: Message: mseq=0x%02x, command=%s, type=%s, size=%d", prefix, message->mseq, ipc_command_string(message->command), ipc_request_type_string(message->type), message->size); #ifdef DEBUG if (message->size > 0) { ipc_client_log(client, "=============================== FMT data dump ================================"); @@ -420,8 +420,8 @@ void ipc_client_log_recv(struct ipc_client *client, struct ipc_message *message, #endif break; case IPC_CLIENT_TYPE_RFS: - ipc_client_log(client, "%s: Received RFS message", prefix); - ipc_client_log(client, "%s: Message: aseq=0x%02x, command=%s, size=%d", prefix, message->aseq, ipc_command_string(message->command), message->size); + ipc_client_log(client, "%s: Sent RFS message", prefix); + ipc_client_log(client, "%s: Message: mseq=0x%02x, command=%s, size=%d", prefix, message->mseq, ipc_command_string(message->command), message->size); #ifdef DEBUG if (message->size > 0) { ipc_client_log(client, "=============================== RFS data dump ================================"); @@ -433,7 +433,7 @@ void ipc_client_log_recv(struct ipc_client *client, struct ipc_message *message, } } -void ipc_client_log_send(struct ipc_client *client, struct ipc_message *message, +void ipc_client_log_recv(struct ipc_client *client, struct ipc_message *message, const char *prefix) { if (client == NULL || message == NULL || prefix == NULL) @@ -441,8 +441,8 @@ void ipc_client_log_send(struct ipc_client *client, struct ipc_message *message, switch (client->type) { case IPC_CLIENT_TYPE_FMT: - ipc_client_log(client, "%s: Sent FMT message", prefix); - ipc_client_log(client, "%s: Message: mseq=0x%02x, command=%s, type=%s, size=%d", prefix, message->mseq, ipc_command_string(message->command), ipc_request_type_string(message->type), message->size); + ipc_client_log(client, "%s: Received FMT message", prefix); + ipc_client_log(client, "%s: Message: aseq=0x%02x, command=%s, type=%s, size=%d", prefix, message->aseq, ipc_command_string(message->command), ipc_response_type_string(message->type), message->size); #ifdef DEBUG if (message->size > 0) { ipc_client_log(client, "=============================== FMT data dump ================================"); @@ -452,8 +452,8 @@ void ipc_client_log_send(struct ipc_client *client, struct ipc_message *message, #endif break; case IPC_CLIENT_TYPE_RFS: - ipc_client_log(client, "%s: Sent RFS message", prefix); - ipc_client_log(client, "%s: Message: mseq=0x%02x, command=%s, size=%d", prefix, message->mseq, ipc_command_string(message->command), message->size); + ipc_client_log(client, "%s: Received RFS message", prefix); + ipc_client_log(client, "%s: Message: aseq=0x%02x, command=%s, size=%d", prefix, message->aseq, ipc_command_string(message->command), message->size); #ifdef DEBUG if (message->size > 0) { ipc_client_log(client, "=============================== RFS data dump ================================"); |