qcacld-3.0: Fix camelCase in hdd_cfg_get_config()

In order to conform to the coding style rename local variables in
function hdd_cfg_get_config().

Change-Id: I2b3d3d6b5c3b630967bed389f7f33b6c7b091413
CRs-Fixed: 2352065
Цей коміт міститься в:
Jeff Johnson
2018-11-17 12:44:57 -08:00
зафіксовано nshrivas
джерело 452b907100
коміт b1e673cd1d

Переглянути файл

@@ -2560,75 +2560,75 @@ static char *i_trim(char *str)
/** /**
* hdd_cfg_get_config() - get the configuration content * hdd_cfg_get_config() - get the configuration content
* @reg_table: pointer to configuration table * @reg_table: pointer to configuration table
* @cRegTableEntries: number of the configuration entries * @reg_table_count: number of @reg_table entries
* @ini_struct: pointer to the hdd config knob * @ini_struct: pointer to the hdd config blob
* @hdd_ctx: pointer to hdd context * @hdd_ctx: pointer to hdd context
* @print_fn: print function pointer * @print_fn: print function pointer
* *
* Return: none * Return: none
*/ */
static void hdd_cfg_get_config(struct reg_table_entry *reg_table, static void hdd_cfg_get_config(struct reg_table_entry *reg_table,
unsigned long cRegTableEntries, unsigned long reg_table_count,
uint8_t *ini_struct, struct hdd_context *hdd_ctx, uint8_t *ini_struct, struct hdd_context *hdd_ctx,
void (*print_fn)(const char *)) void (*print_fn)(const char *))
{ {
unsigned int idx; unsigned int idx;
struct reg_table_entry *pRegEntry = reg_table; struct reg_table_entry *reg_entry = reg_table;
uint32_t value; uint32_t value;
char valueStr[CFG_VALUE_MAX_LEN]; char value_str[CFG_VALUE_MAX_LEN];
char config_str[CFG_ENTRY_MAX_LEN]; char config_str[CFG_ENTRY_MAX_LEN];
char *fmt; char *fmt;
void *pField; void *field;
struct qdf_mac_addr *pMacAddr; struct qdf_mac_addr *mac_addr;
int curlen; int curlen;
for (idx = 0; idx < cRegTableEntries; idx++, pRegEntry++) { for (idx = 0; idx < reg_table_count; idx++, reg_entry++) {
pField = ini_struct + pRegEntry->VarOffset; field = ini_struct + reg_entry->VarOffset;
if ((WLAN_PARAM_Integer == pRegEntry->RegType) || if ((WLAN_PARAM_Integer == reg_entry->RegType) ||
(WLAN_PARAM_SignedInteger == pRegEntry->RegType) || (WLAN_PARAM_SignedInteger == reg_entry->RegType) ||
(WLAN_PARAM_HexInteger == pRegEntry->RegType)) { (WLAN_PARAM_HexInteger == reg_entry->RegType)) {
value = 0; value = 0;
if ((pRegEntry->VarSize > sizeof(value)) || if ((reg_entry->VarSize > sizeof(value)) ||
(pRegEntry->VarSize == 0)) { (reg_entry->VarSize == 0)) {
pr_warn("Invalid length of %s: %d", pr_warn("Invalid length of %s: %d",
pRegEntry->RegName, pRegEntry->VarSize); reg_entry->RegName, reg_entry->VarSize);
continue; continue;
} }
memcpy(&value, pField, pRegEntry->VarSize); memcpy(&value, field, reg_entry->VarSize);
if (WLAN_PARAM_HexInteger == pRegEntry->RegType) { if (WLAN_PARAM_HexInteger == reg_entry->RegType) {
fmt = "%x"; fmt = "%x";
} else if (WLAN_PARAM_SignedInteger == } else if (WLAN_PARAM_SignedInteger ==
pRegEntry->RegType) { reg_entry->RegType) {
fmt = "%d"; fmt = "%d";
value = sign_extend32( value = sign_extend32(
value, value,
pRegEntry->VarSize * 8 - 1); reg_entry->VarSize * 8 - 1);
} else { } else {
fmt = "%u"; fmt = "%u";
} }
snprintf(valueStr, CFG_VALUE_MAX_LEN, fmt, value); snprintf(value_str, CFG_VALUE_MAX_LEN, fmt, value);
} else if (WLAN_PARAM_String == pRegEntry->RegType) { } else if (WLAN_PARAM_String == reg_entry->RegType) {
snprintf(valueStr, CFG_VALUE_MAX_LEN, "%s", snprintf(value_str, CFG_VALUE_MAX_LEN, "%s",
(char *)pField); (char *)field);
} else if (WLAN_PARAM_MacAddr == pRegEntry->RegType) { } else if (WLAN_PARAM_MacAddr == reg_entry->RegType) {
pMacAddr = (struct qdf_mac_addr *) pField; mac_addr = (struct qdf_mac_addr *) field;
snprintf(valueStr, CFG_VALUE_MAX_LEN, snprintf(value_str, CFG_VALUE_MAX_LEN,
"%02x:%02x:%02x:%02x:%02x:%02x", "%02x:%02x:%02x:%02x:%02x:%02x",
pMacAddr->bytes[0], mac_addr->bytes[0],
pMacAddr->bytes[1], mac_addr->bytes[1],
pMacAddr->bytes[2], mac_addr->bytes[2],
pMacAddr->bytes[3], mac_addr->bytes[3],
pMacAddr->bytes[4], pMacAddr->bytes[5]); mac_addr->bytes[4], mac_addr->bytes[5]);
} else { } else {
snprintf(valueStr, CFG_VALUE_MAX_LEN, "(unhandled)"); snprintf(value_str, CFG_VALUE_MAX_LEN, "(unhandled)");
} }
curlen = scnprintf(config_str, CFG_ENTRY_MAX_LEN, curlen = scnprintf(config_str, CFG_ENTRY_MAX_LEN,
"%s=%s%s\n", "%s=%s%s\n",
pRegEntry->RegName, reg_entry->RegName,
valueStr, value_str,
test_bit(idx, test_bit(idx,
(void *)&hdd_ctx->config-> (void *)&hdd_ctx->config->
bExplicitCfg) ? "*" : ""); bExplicitCfg) ? "*" : "");