Browse Source

qcacld-3.0: Fix compiler warning from FTM convergence

With FTM modification, compiler is throwing
'implicit declaration of function' warning, and treated as error.

Change-Id: I2341685ff6e25fcef25a6ae7bed365481e9d529c
CRs-Fixed: 2182458
Lin Bai 7 years ago
parent
commit
06cfea0405
1 changed files with 27 additions and 26 deletions
  1. 27 26
      core/hdd/src/wlan_hdd_ftm.c

+ 27 - 26
core/hdd/src/wlan_hdd_ftm.c

@@ -92,6 +92,33 @@ int hdd_update_cds_config_ftm(struct hdd_context *hdd_ctx)
 }
 
 #ifdef LINUX_QCMBR
+
+/**
+ * wlan_hdd_qcmbr_command() - QCMBR command handler
+ * @adapter: adapter upon which the command was received
+ * @pqcmbr_data: QCMBR command
+ *
+ * Return: 0 on success, non-zero on error
+ */
+static int wlan_hdd_qcmbr_command(struct hdd_adapter *adapter,
+				  struct qcmbr_data *pqcmbr_data)
+{
+	int ret = 0;
+	struct hdd_context *hdd_ctx;
+
+	hdd_ctx = WLAN_HDD_GET_CTX(adapter);
+	ret = wlan_hdd_validate_context(hdd_ctx);
+	if (ret)
+		return ret;
+
+	ret = wlan_ioctl_ftm_testmode_cmd(hdd_ctx->hdd_pdev,
+					  pqcmbr_data->cmd,
+					  pqcmbr_data->buf,
+					  pqcmbr_data->length);
+
+	return ret;
+}
+
 #ifdef CONFIG_COMPAT
 
 /**
@@ -134,32 +161,6 @@ static int wlan_hdd_qcmbr_compat_ioctl(struct hdd_adapter *adapter,
 }
 #endif /* CONFIG_COMPAT */
 
-/**
- * wlan_hdd_qcmbr_command() - QCMBR command handler
- * @adapter: adapter upon which the command was received
- * @pqcmbr_data: QCMBR command
- *
- * Return: 0 on success, non-zero on error
- */
-static int wlan_hdd_qcmbr_command(struct hdd_adapter *adapter,
-				  struct qcmbr_data *pqcmbr_data)
-{
-	int ret = 0;
-	struct hdd_context *hdd_ctx;
-
-	hdd_ctx = WLAN_HDD_GET_CTX(adapter);
-	ret = wlan_hdd_validate_context(hdd_ctx);
-	if (ret)
-		return ret;
-
-	ret = wlan_ioctl_ftm_testmode_cmd(hdd_ctx->hdd_pdev,
-					  pqcmbr_data->cmd,
-					  pqcmbr_data->buf,
-					  pqcmbr_data->length);
-
-	return ret;
-}
-
 /**
  * wlan_hdd_qcmbr_ioctl() - Standard QCMBR ioctl handler
  * @adapter: adapter upon which the ioctl was received