summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Johnson <jjohnson@codeaurora.org>2016-12-09 17:10:24 -0800
committerqcabuildsw <qcabuildsw@localhost>2016-12-18 20:25:22 -0800
commitc3faf398c83b50b73df96f3855cb92c6f58faf17 (patch)
treef21f939a1f5c56c8a3ad72cf7352ee9397cef316
parent6bbdc3243befb1ed5dc2e1547b0efb97088dae30 (diff)
qcacld-3.0: Fix checkpatch errors in HDD
Over time some checkpatch errors have crept into the HDD code, so fix the issues that should be fixed. Change-Id: I9287a724b856bcc62ac284ba66e68cdf12077646 CRs-Fixed: 1102140
-rw-r--r--core/hdd/inc/wlan_hdd_oemdata.h2
-rw-r--r--core/hdd/src/wlan_hdd_assoc.c5
-rw-r--r--core/hdd/src/wlan_hdd_cfg.c6
-rw-r--r--core/hdd/src/wlan_hdd_lro.c3
-rw-r--r--core/hdd/src/wlan_hdd_nan_datapath.c2
-rw-r--r--core/hdd/src/wlan_hdd_napi.c32
6 files changed, 26 insertions, 24 deletions
diff --git a/core/hdd/inc/wlan_hdd_oemdata.h b/core/hdd/inc/wlan_hdd_oemdata.h
index ed1ab4d9ca9d..bc69f7d299fe 100644
--- a/core/hdd/inc/wlan_hdd_oemdata.h
+++ b/core/hdd/inc/wlan_hdd_oemdata.h
@@ -178,7 +178,7 @@ void hdd_send_peer_status_ind_to_oem_app(struct qdf_mac_addr *peerMac,
uint8_t peerStatus,
uint8_t peerTimingMeasCap,
uint8_t sessionId,
- tSirSmeChanInfo * chan_info,
+ tSirSmeChanInfo *chan_info,
enum tQDF_ADAPTER_MODE dev_mode);
int iw_get_oem_data_cap(struct net_device *dev, struct iw_request_info *info,
diff --git a/core/hdd/src/wlan_hdd_assoc.c b/core/hdd/src/wlan_hdd_assoc.c
index eb4d04f461c9..af913392396c 100644
--- a/core/hdd/src/wlan_hdd_assoc.c
+++ b/core/hdd/src/wlan_hdd_assoc.c
@@ -2794,14 +2794,13 @@ static QDF_STATUS hdd_association_completion_handler(hdd_adapter_t *pAdapter,
pRoamInfo->reasonCode);
pHddStaCtx->conn_info.assoc_status_code =
pRoamInfo->statusCode;
- }
- else
+ } else {
hdd_err("connect failed: for bssid "
MAC_ADDRESS_STR
" result:%d and Status:%d ",
MAC_ADDR_ARRAY(pWextState->req_bssId.bytes),
roamResult, roamStatus);
-
+ }
hdd_err("Invoking packetdump deregistration API");
wlan_deregister_txrx_packetdump();
diff --git a/core/hdd/src/wlan_hdd_cfg.c b/core/hdd/src/wlan_hdd_cfg.c
index 919e71368f28..2f7e2186b5b5 100644
--- a/core/hdd/src/wlan_hdd_cfg.c
+++ b/core/hdd/src/wlan_hdd_cfg.c
@@ -486,7 +486,7 @@ REG_TABLE_ENTRY g_registry_table[] = {
REG_VARIABLE(CFG_HT_MPDU_DENSITY_NAME, WLAN_PARAM_Integer,
struct hdd_config, ht_mpdu_density,
- VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK ,
+ VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK,
CFG_HT_MPDU_DENSITY_DEFAULT,
CFG_HT_MPDU_DENSITY_MIN,
CFG_HT_MPDU_DENSITY_MAX),
@@ -800,12 +800,12 @@ REG_TABLE_ENTRY g_registry_table[] = {
CFG_MIN_REST_TIME_MIN,
CFG_MIN_REST_TIME_MAX),
- REG_VARIABLE(CFG_IDLE_TIME_NAME , WLAN_PARAM_Integer,
+ REG_VARIABLE(CFG_IDLE_TIME_NAME, WLAN_PARAM_Integer,
struct hdd_config, idle_time_conc,
VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT,
CFG_IDLE_TIME_DEFAULT,
CFG_IDLE_TIME_MIN,
- CFG_IDLE_TIME_MAX) ,
+ CFG_IDLE_TIME_MAX),
REG_VARIABLE(CFG_NUM_STA_CHAN_COMBINED_CONC_NAME, WLAN_PARAM_Integer,
struct hdd_config, nNumStaChanCombinedConc,
diff --git a/core/hdd/src/wlan_hdd_lro.c b/core/hdd/src/wlan_hdd_lro.c
index d43d576dc5b1..c71ee2860196 100644
--- a/core/hdd/src/wlan_hdd_lro.c
+++ b/core/hdd/src/wlan_hdd_lro.c
@@ -416,8 +416,7 @@ int hdd_lro_init(hdd_context_t *hdd_ctx)
struct wma_lro_config_cmd_t lro_config;
if ((!hdd_ctx->config->lro_enable) &&
- (hdd_napi_enabled(HDD_NAPI_ANY) == 0))
- {
+ (hdd_napi_enabled(HDD_NAPI_ANY) == 0)) {
hdd_err("LRO and NAPI are both disabled.");
return 0;
}
diff --git a/core/hdd/src/wlan_hdd_nan_datapath.c b/core/hdd/src/wlan_hdd_nan_datapath.c
index 64ee8f085da7..ef5aae68a4b2 100644
--- a/core/hdd/src/wlan_hdd_nan_datapath.c
+++ b/core/hdd/src/wlan_hdd_nan_datapath.c
@@ -1385,7 +1385,7 @@ static void hdd_ndp_indication_handler(hdd_adapter_t *adapter,
goto ndp_indication_nla_failed;
if (nla_put(vendor_event,
- QCA_WLAN_VENDOR_ATTR_NDP_PEER_DISCOVERY_MAC_ADDR ,
+ QCA_WLAN_VENDOR_ATTR_NDP_PEER_DISCOVERY_MAC_ADDR,
QDF_MAC_ADDR_SIZE, event->peer_discovery_mac_addr.bytes))
goto ndp_indication_nla_failed;
diff --git a/core/hdd/src/wlan_hdd_napi.c b/core/hdd/src/wlan_hdd_napi.c
index 73f0136ca67d..8bebb4634aa1 100644
--- a/core/hdd/src/wlan_hdd_napi.c
+++ b/core/hdd/src/wlan_hdd_napi.c
@@ -131,7 +131,7 @@ int hdd_napi_create(void)
hdd_info("napi instances were created. Map=0x%x", rc);
hdd_ctx = cds_get_context(QDF_MODULE_ID_HDD);
if (unlikely(NULL == hdd_ctx)) {
- QDF_ASSERT( 0 );
+ QDF_ASSERT(0);
rc = -EFAULT;
} else {
rc = hdd_napi_event(NAPI_EVT_INI_FILE,
@@ -283,7 +283,7 @@ int hdd_napi_apply_throughput_policy(struct hdd_context_s *hddctx,
uint64_t packets = tx_packets + rx_packets;
enum qca_napi_tput_state req_state;
struct qca_napi_data *napid = hdd_napi_get_all();
- int enabled = 0;
+ int enabled;
NAPI_DEBUG("-->%s(tx=%lld, rx=%lld)", __func__, tx_packets, rx_packets);
@@ -300,20 +300,24 @@ int hdd_napi_apply_throughput_policy(struct hdd_context_s *hddctx,
return rc;
}
- if ((napid != NULL) &&
- (enabled = hdd_napi_enabled(HDD_NAPI_ANY))) {
- if (packets > hddctx->config->busBandwidthHighThreshold)
- req_state = QCA_NAPI_TPUT_HI;
- else
- req_state = QCA_NAPI_TPUT_LO;
+ if (!napid) {
+ hdd_err("ERR: napid NULL");
+ return rc;
+ }
- if (req_state != napid->napi_mode)
- rc = hdd_napi_event(NAPI_EVT_TPUT_STATE,
- (void *)req_state);
- } else {
- hdd_err("ERR: napid (%p) NULL or napi_enabled (%d) FALSE",
- napid, enabled);
+ enabled = hdd_napi_enabled(HDD_NAPI_ANY);
+ if (!enabled) {
+ hdd_err("ERR: napi not enabled");
+ return rc;
}
+
+ if (packets > hddctx->config->busBandwidthHighThreshold)
+ req_state = QCA_NAPI_TPUT_HI;
+ else
+ req_state = QCA_NAPI_TPUT_LO;
+
+ if (req_state != napid->napi_mode)
+ rc = hdd_napi_event(NAPI_EVT_TPUT_STATE, (void *)req_state);
return rc;
}