Browse Source

qcacld-3.0: Cleanup unnecessary logging in DSC

There are various entry and exit prints present in DSC that are not
necessary for any debugging purpose.

Cleanup these extra logs

Change-Id: I0f2f5b03ddc3e4535cc352fd13782eac1a235121
CRs-Fixed: 2616198
Sourav Mohapatra 5 years ago
parent
commit
5548977f58

+ 7 - 16
components/dsc/src/wlan_dsc_driver.c

@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2018-2019 The Linux Foundation. All rights reserved.
+ * Copyright (c) 2018-2020 The Linux Foundation. All rights reserved.
  *
  * Permission to use, copy, modify, and/or distribute this software for
  * any purpose with or without fee is hereby granted, provided that the
@@ -62,9 +62,7 @@ QDF_STATUS dsc_driver_create(struct dsc_driver **out_driver)
 {
 	QDF_STATUS status;
 
-	dsc_enter();
 	status = __dsc_driver_create(out_driver);
-	dsc_exit();
 
 	return status;
 }
@@ -100,9 +98,7 @@ static void __dsc_driver_destroy(struct dsc_driver **out_driver)
 
 void dsc_driver_destroy(struct dsc_driver **out_driver)
 {
-	dsc_enter();
 	__dsc_driver_destroy(out_driver);
-	dsc_exit();
 }
 
 static bool __dsc_driver_trans_active_down_tree(struct dsc_driver *driver)
@@ -170,7 +166,8 @@ QDF_STATUS dsc_driver_trans_start(struct dsc_driver *driver, const char *desc)
 
 	dsc_enter_str(desc);
 	status = __dsc_driver_trans_start(driver, desc);
-	dsc_exit_status(status);
+	if (QDF_IS_STATUS_ERROR(status))
+		dsc_exit_status(status);
 
 	return status;
 }
@@ -215,7 +212,8 @@ dsc_driver_trans_start_wait(struct dsc_driver *driver, const char *desc)
 
 	dsc_enter_str(desc);
 	status = __dsc_driver_trans_start_wait(driver, desc);
-	dsc_exit_status(status);
+	if (QDF_IS_STATUS_ERROR(status))
+		dsc_exit_status(status);
 
 	return status;
 }
@@ -264,9 +262,7 @@ static void __dsc_driver_trans_stop(struct dsc_driver *driver)
 
 void dsc_driver_trans_stop(struct dsc_driver *driver)
 {
-	dsc_enter();
 	__dsc_driver_trans_stop(driver);
-	dsc_exit();
 }
 
 static void __dsc_driver_assert_trans_protected(struct dsc_driver *driver)
@@ -281,9 +277,7 @@ static void __dsc_driver_assert_trans_protected(struct dsc_driver *driver)
 
 void dsc_driver_assert_trans_protected(struct dsc_driver *driver)
 {
-	dsc_enter();
 	__dsc_driver_assert_trans_protected(driver);
-	dsc_exit();
 }
 
 static QDF_STATUS
@@ -318,7 +312,8 @@ QDF_STATUS _dsc_driver_op_start(struct dsc_driver *driver, const char *func)
 
 	dsc_enter_str(func);
 	status = __dsc_driver_op_start(driver, func);
-	dsc_exit_status(status);
+	if (QDF_IS_STATUS_ERROR(status))
+		dsc_exit_status(status);
 
 	return status;
 }
@@ -339,9 +334,7 @@ static void __dsc_driver_op_stop(struct dsc_driver *driver, const char *func)
 
 void _dsc_driver_op_stop(struct dsc_driver *driver, const char *func)
 {
-	dsc_enter_str(func);
 	__dsc_driver_op_stop(driver, func);
-	dsc_exit();
 }
 
 static void __dsc_driver_wait_for_ops(struct dsc_driver *driver)
@@ -373,8 +366,6 @@ static void __dsc_driver_wait_for_ops(struct dsc_driver *driver)
 
 void dsc_driver_wait_for_ops(struct dsc_driver *driver)
 {
-	dsc_enter();
 	__dsc_driver_wait_for_ops(driver);
-	dsc_exit();
 }
 

+ 5 - 13
components/dsc/src/wlan_dsc_psoc.c

@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2018-2019 The Linux Foundation. All rights reserved.
+ * Copyright (c) 2018-2020 The Linux Foundation. All rights reserved.
  *
  * Permission to use, copy, modify, and/or distribute this software for
  * any purpose with or without fee is hereby granted, provided that the
@@ -64,9 +64,7 @@ dsc_psoc_create(struct dsc_driver *driver, struct dsc_psoc **out_psoc)
 {
 	QDF_STATUS status;
 
-	dsc_enter();
 	status =  __dsc_psoc_create(driver, out_psoc);
-	dsc_exit();
 
 	return status;
 }
@@ -107,9 +105,7 @@ static void __dsc_psoc_destroy(struct dsc_psoc **out_psoc)
 
 void dsc_psoc_destroy(struct dsc_psoc **out_psoc)
 {
-	dsc_enter();
 	__dsc_psoc_destroy(out_psoc);
-	dsc_exit();
 }
 
 static bool __dsc_psoc_trans_active_down_tree(struct dsc_psoc *psoc)
@@ -199,7 +195,8 @@ QDF_STATUS dsc_psoc_trans_start(struct dsc_psoc *psoc, const char *desc)
 
 	dsc_enter_str(desc);
 	status = __dsc_psoc_trans_start(psoc, desc);
-	dsc_exit_status(status);
+	if (QDF_IS_STATUS_ERROR(status))
+		dsc_exit_status(status);
 
 	return status;
 }
@@ -243,7 +240,8 @@ QDF_STATUS dsc_psoc_trans_start_wait(struct dsc_psoc *psoc, const char *desc)
 
 	dsc_enter_str(desc);
 	status = __dsc_psoc_trans_start_wait(psoc, desc);
-	dsc_exit_status(status);
+	if (QDF_IS_STATUS_ERROR(status))
+		dsc_exit_status(status);
 
 	return status;
 }
@@ -277,9 +275,7 @@ static void __dsc_psoc_trans_stop(struct dsc_psoc *psoc)
 
 void dsc_psoc_trans_stop(struct dsc_psoc *psoc)
 {
-	dsc_enter();
 	__dsc_psoc_trans_stop(psoc);
-	dsc_exit();
 }
 
 static void __dsc_psoc_assert_trans_protected(struct dsc_psoc *psoc)
@@ -295,9 +291,7 @@ static void __dsc_psoc_assert_trans_protected(struct dsc_psoc *psoc)
 
 void dsc_psoc_assert_trans_protected(struct dsc_psoc *psoc)
 {
-	dsc_enter();
 	__dsc_psoc_assert_trans_protected(psoc);
-	dsc_exit();
 }
 
 bool __dsc_psoc_trans_trigger_checked(struct dsc_psoc *psoc)
@@ -390,8 +384,6 @@ static void __dsc_psoc_wait_for_ops(struct dsc_psoc *psoc)
 
 void dsc_psoc_wait_for_ops(struct dsc_psoc *psoc)
 {
-	dsc_enter();
 	__dsc_psoc_wait_for_ops(psoc);
-	dsc_exit();
 }
 

+ 4 - 12
components/dsc/src/wlan_dsc_vdev.c

@@ -63,9 +63,7 @@ QDF_STATUS dsc_vdev_create(struct dsc_psoc *psoc, struct dsc_vdev **out_vdev)
 {
 	QDF_STATUS status;
 
-	dsc_enter();
 	status =  __dsc_vdev_create(psoc, out_vdev);
-	dsc_exit();
 
 	return status;
 }
@@ -102,9 +100,7 @@ static void __dsc_vdev_destroy(struct dsc_vdev **out_vdev)
 
 void dsc_vdev_destroy(struct dsc_vdev **out_vdev)
 {
-	dsc_enter();
 	__dsc_vdev_destroy(out_vdev);
-	dsc_exit();
 }
 
 #define __dsc_vdev_can_op(vdev) __dsc_vdev_can_trans(vdev)
@@ -194,7 +190,8 @@ QDF_STATUS dsc_vdev_trans_start(struct dsc_vdev *vdev, const char *desc)
 
 	dsc_enter_str(desc);
 	status = __dsc_vdev_trans_start(vdev, desc);
-	dsc_exit_status(status);
+	if (QDF_IS_STATUS_ERROR(status))
+		dsc_exit_status(status);
 
 	return status;
 }
@@ -238,7 +235,8 @@ QDF_STATUS dsc_vdev_trans_start_wait(struct dsc_vdev *vdev, const char *desc)
 
 	dsc_enter_str(desc);
 	status = __dsc_vdev_trans_start_wait(vdev, desc);
-	dsc_exit_status(status);
+	if (QDF_IS_STATUS_ERROR(status))
+		dsc_exit_status(status);
 
 	return status;
 }
@@ -269,9 +267,7 @@ static void __dsc_vdev_trans_stop(struct dsc_vdev *vdev)
 
 void dsc_vdev_trans_stop(struct dsc_vdev *vdev)
 {
-	dsc_enter();
 	__dsc_vdev_trans_stop(vdev);
-	dsc_exit();
 }
 
 static void __dsc_vdev_assert_trans_protected(struct dsc_vdev *vdev)
@@ -288,9 +284,7 @@ static void __dsc_vdev_assert_trans_protected(struct dsc_vdev *vdev)
 
 void dsc_vdev_assert_trans_protected(struct dsc_vdev *vdev)
 {
-	dsc_enter();
 	__dsc_vdev_assert_trans_protected(vdev);
-	dsc_exit();
 }
 
 static QDF_STATUS __dsc_vdev_op_start(struct dsc_vdev *vdev, const char *func)
@@ -373,8 +367,6 @@ static void __dsc_vdev_wait_for_ops(struct dsc_vdev *vdev)
 
 void dsc_vdev_wait_for_ops(struct dsc_vdev *vdev)
 {
-	dsc_enter();
 	__dsc_vdev_wait_for_ops(vdev);
-	dsc_exit();
 }