summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSubash Abhinov Kasiviswanathan <subashab@codeaurora.org>2015-04-14 13:51:59 -0600
committerSubash Abhinov Kasiviswanathan <subashab@codeaurora.org>2015-04-14 14:48:36 -0600
commitcf715081f8ed52bd5af0f9a543010eb7e2a5c6a3 (patch)
treeef55869ac5bd9f9e2b3f5ef5b8be96369630c760
parentd42712d0fb90465955088b51ee00ad21cabbae13 (diff)
downloadandroid_vendor_qcom_opensource_dataservices-cf715081f8ed52bd5af0f9a543010eb7e2a5c6a3.tar.gz
android_vendor_qcom_opensource_dataservices-cf715081f8ed52bd5af0f9a543010eb7e2a5c6a3.tar.bz2
android_vendor_qcom_opensource_dataservices-cf715081f8ed52bd5af0f9a543010eb7e2a5c6a3.zip
librmnetctl: Minor readability and spelling fixes
Add numbering to the rmnetctl error code enum. This helps for easier reading while debugging. Fix a few typos. Also update copyright. Change-Id: I7ce113f7535f8d1897bb5accb30b0e0dc133869a
-rw-r--r--rmnetctl/cli/rmnetcli.c10
-rw-r--r--rmnetctl/cli/rmnetcli.h2
-rw-r--r--rmnetctl/inc/librmnetctl.h58
-rw-r--r--rmnetctl/inc/librmnetctl_hndl.h2
-rw-r--r--rmnetctl/src/librmnetctl.c4
5 files changed, 38 insertions, 38 deletions
diff --git a/rmnetctl/cli/rmnetcli.c b/rmnetctl/cli/rmnetcli.c
index fdbe3c6..2275ec2 100644
--- a/rmnetctl/cli/rmnetcli.c
+++ b/rmnetctl/cli/rmnetcli.c
@@ -2,7 +2,7 @@
R M N E T C L I . C
-Copyright (c) 2013-2014, The Linux Foundation. All rights reserved.
+Copyright (c) 2013-2015, The Linux Foundation. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
@@ -151,17 +151,17 @@ static void rmnet_api_usage(void)
printf(_5TABS" bridged. dev_name");
printf(_5TABS" and egress_dev_name");
printf(_5TABS" cannot be larger");
- printf(_5TABS" than 15 tcharacters");
+ printf(_5TABS" than 15 characters");
printf(_5TABS" Returns the status code\n\n");
printf("rmnetcli unsetlepc <logical_ep_id> Un-sets the logical");
printf(_2TABS" <dev_name> endpoint configuration for");
printf(_5TABS" a particular link.");
printf(_5TABS" integers from -1 to 31.");
printf(_5TABS" dev_name cannot be larger");
- printf(_5TABS" than 15 tcharacters");
+ printf(_5TABS" than 15 characters");
printf(_5TABS" Returns the status code\n\n");
printf("rmnetcli getlepc <logical_ep_id> Sets the logical");
- printf(_2TABS" <dev_name> enpoint configuration for a");
+ printf(_2TABS" <dev_name> endpoint configuration for a");
printf(_5TABS" particular link.");
printf(_5TABS" logical_ep_id are 32bit");
printf(_5TABS" integers from -1 to 31.");
@@ -241,7 +241,7 @@ static void print_rmnet_api_status(int return_code, uint16_t error_number)
/*!
* @brief Method to make the API calls
* @details Checks for each type of parameter and calls the appropriate
-* function based on the number of parameters and paramter type
+* function based on the number of parameters and parameter type
* @param argc Number of arguments which vary based on the commands
* @param argv Value of the arguments which vary based on the commands
* @return RMNETCTL_SUCCESS if successful. Relevant data might be printed
diff --git a/rmnetctl/cli/rmnetcli.h b/rmnetctl/cli/rmnetcli.h
index 503a86e..6375082 100644
--- a/rmnetctl/cli/rmnetcli.h
+++ b/rmnetctl/cli/rmnetcli.h
@@ -2,7 +2,7 @@
R M N E T C L I . H
-Copyright (c) 2013, The Linux Foundation. All rights reserved.
+Copyright (c) 2013, 2015 The Linux Foundation. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
diff --git a/rmnetctl/inc/librmnetctl.h b/rmnetctl/inc/librmnetctl.h
index 1b8e985..ff78011 100644
--- a/rmnetctl/inc/librmnetctl.h
+++ b/rmnetctl/inc/librmnetctl.h
@@ -2,7 +2,7 @@
L I B R M N E T C T L . H
-Copyright (c) 2013-2014, The Linux Foundation. All rights reserved.
+Copyright (c) 2013-2015, The Linux Foundation. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
@@ -65,69 +65,69 @@ IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
enum rmnetctl_error_codes_e {
/* API succeeded. This should always be the first element. */
- RMNETCTL_API_SUCCESS,
+ RMNETCTL_API_SUCCESS = 0,
- RMNETCTL_API_FIRST_ERR,
+ RMNETCTL_API_FIRST_ERR = 1,
/* API failed because not enough memory to create buffer to send
* message */
RMNETCTL_API_ERR_REQUEST_INVALID = RMNETCTL_API_FIRST_ERR,
/* API failed because not enough memory to create buffer for the
* response message */
- RMNETCTL_API_ERR_RESPONSE_INVALID,
+ RMNETCTL_API_ERR_RESPONSE_INVALID = 2,
/* API failed because could not send the message to kernel */
- RMNETCTL_API_ERR_MESSAGE_SEND,
+ RMNETCTL_API_ERR_MESSAGE_SEND = 3,
/* API failed because could not receive message from the kernel */
- RMNETCTL_API_ERR_MESSAGE_RECEIVE,
+ RMNETCTL_API_ERR_MESSAGE_RECEIVE = 4,
- RMNETCTL_INIT_FIRST_ERR,
+ RMNETCTL_INIT_FIRST_ERR = 5,
/* Invalid process id. So return an error. */
RMNETCTL_INIT_ERR_PROCESS_ID = RMNETCTL_INIT_FIRST_ERR,
/* Invalid socket descriptor id. So return an error. */
- RMNETCTL_INIT_ERR_NETLINK_FD,
+ RMNETCTL_INIT_ERR_NETLINK_FD = 6,
/* Could not bind the socket to the Netlink file descriptor */
- RMNETCTL_INIT_ERR_BIND,
+ RMNETCTL_INIT_ERR_BIND = 7,
/* Invalid user id. Only root has access to this function. (NA) */
- RMNETCTL_INIT_ERR_INVALID_USER,
+ RMNETCTL_INIT_ERR_INVALID_USER = 8,
- RMNETCTL_API_SECOND_ERR,
+ RMNETCTL_API_SECOND_ERR = 9,
/* API failed because the RmNet handle for the transaction was NULL */
RMNETCTL_API_ERR_HNDL_INVALID = RMNETCTL_API_SECOND_ERR,
/* API failed because the request buffer for the transaction was NULL */
- RMNETCTL_API_ERR_REQUEST_NULL,
+ RMNETCTL_API_ERR_REQUEST_NULL = 10,
/* API failed because the response buffer for the transaction was NULL*/
- RMNETCTL_API_ERR_RESPONSE_NULL,
+ RMNETCTL_API_ERR_RESPONSE_NULL = 11,
/* API failed because the request and response type do not match*/
- RMNETCTL_API_ERR_MESSAGE_TYPE,
+ RMNETCTL_API_ERR_MESSAGE_TYPE = 12,
/* API failed because the return type is invalid */
- RMNETCTL_API_ERR_RETURN_TYPE,
+ RMNETCTL_API_ERR_RETURN_TYPE = 13,
/* API failed because the string was truncated */
- RMNETCTL_API_ERR_STRING_TRUNCATION,
+ RMNETCTL_API_ERR_STRING_TRUNCATION = 14,
/* These error are 1-to-1 with rmnet_data config errors in rmnet_data.h
for each conversion.
please keep the enums synced.
*/
- RMNETCTL_KERNEL_FIRST_ERR,
+ RMNETCTL_KERNEL_FIRST_ERR = 15,
/* No error */
RMNETCTL_KERNEL_ERROR_NO_ERR = RMNETCTL_KERNEL_FIRST_ERR,
/* Invalid / unsupported message */
- RMNETCTL_KERNEL_ERR_UNKNOWN_MESSAGE,
- /* Internal problem in the kernel modeule */
- RMNETCTL_KERNEL_ERR_INTERNAL,
- /* Kernel is temporarely out of memory */
- RMNETCTL_KERNEL_ERR_OUT_OF_MEM,
+ RMNETCTL_KERNEL_ERR_UNKNOWN_MESSAGE = 16,
+ /* Internal problem in the kernel module */
+ RMNETCTL_KERNEL_ERR_INTERNAL = 17,
+ /* Kernel is temporarily out of memory */
+ RMNETCTL_KERNEL_ERR_OUT_OF_MEM = 18,
/* Device already exists / Still in use */
- RMETNCTL_KERNEL_ERR_DEVICE_IN_USE,
+ RMETNCTL_KERNEL_ERR_DEVICE_IN_USE = 19,
/* Invalid request / Unsupported scenario */
- RMNETCTL_KERNEL_ERR_INVALID_REQUEST,
+ RMNETCTL_KERNEL_ERR_INVALID_REQUEST = 20,
/* Device doesn't exist */
- RMNETCTL_KERNEL_ERR_NO_SUCH_DEVICE,
+ RMNETCTL_KERNEL_ERR_NO_SUCH_DEVICE = 21,
/* One or more of the arguments is invalid */
- RMNETCTL_KERNEL_ERR_BAD_ARGS,
+ RMNETCTL_KERNEL_ERR_BAD_ARGS = 22,
/* Egress device is invalid */
- RMNETCTL_KERNEL_ERR_BAD_EGRESS_DEVICE,
+ RMNETCTL_KERNEL_ERR_BAD_EGRESS_DEVICE = 23,
/* TC handle is full */
- RMNETCTL_KERNEL_ERR_TC_HANDLE_FULL,
+ RMNETCTL_KERNEL_ERR_TC_HANDLE_FULL = 24,
/* This should always be the last element */
RMNETCTL_API_ERR_ENUM_LENGTH
@@ -159,7 +159,7 @@ char rmnetctl_error_code_text
"ERROR: Kernel call succeeded\n",
"ERROR: Invalid / Unsupported directive\n",
"ERROR: Internal problem in the kernel module\n",
- "ERROR: The kernel is temporarely out of memory\n",
+ "ERROR: The kernel is temporarily out of memory\n",
"ERROR: Device already exists / Still in use\n",
"ERROR: Invalid request / Unsupported scenario\n",
"ERROR: Device doesn't exist\n",
diff --git a/rmnetctl/inc/librmnetctl_hndl.h b/rmnetctl/inc/librmnetctl_hndl.h
index c020e7b..1a435ed 100644
--- a/rmnetctl/inc/librmnetctl_hndl.h
+++ b/rmnetctl/inc/librmnetctl_hndl.h
@@ -2,7 +2,7 @@
L I B R M N E T C T L _ H N D L. H
-Copyright (c) 2013, The Linux Foundation. All rights reserved.
+Copyright (c) 2013, 2015 The Linux Foundation. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
diff --git a/rmnetctl/src/librmnetctl.c b/rmnetctl/src/librmnetctl.c
index 835798e..749e346 100644
--- a/rmnetctl/src/librmnetctl.c
+++ b/rmnetctl/src/librmnetctl.c
@@ -2,7 +2,7 @@
L I B R M N E T C T L . C
-Copyright (c) 2013-2014, The Linux Foundation. All rights reserved.
+Copyright (c) 2013-2015, The Linux Foundation. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
@@ -33,7 +33,7 @@ IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
/*!
* @file librmnetctl.c
-* @brief rmnet control API's implentations file
+* @brief rmnet control API's implementation file
*/
/*===========================================================================