Bläddra i källkod

msm: camera: utils: Use pr_info for camera logs

Use pr_info for camera warning and error logs to avoid sending
to console (assuming info logs are disabled to console).
All camera warning and error logs are anyway tagged with
CAM_WARN and CAM_ERR, so using pr_info doesn't cause any
information loss.

Change-Id: Ib23fbad47c1dce4c45e3413d775303d681a1ff86
Signed-off-by: Pavan Kumar Chilamkurthi <[email protected]>
Signed-off-by: Mukund Madhusudan Atre <[email protected]>
Pavan Kumar Chilamkurthi 5 år sedan
förälder
incheckning
d7a8426091
1 ändrade filer med 6 tillägg och 6 borttagningar
  1. 6 6
      drivers/cam_utils/cam_debug_util.h

+ 6 - 6
drivers/cam_utils/cam_debug_util.h

@@ -75,7 +75,7 @@ const char *cam_get_module_name(unsigned int module_id);
  * @args     :  Arguments which needs to be print in log
  */
 #define CAM_ERR(__module, fmt, args...)                            \
-	pr_err("CAM_ERR: %s: %s: %d " fmt "\n",                     \
+	pr_info("CAM_ERR: %s: %s: %d " fmt "\n",                   \
 		cam_get_module_name(__module), __func__,  __LINE__, ##args)
 /*
  * CAM_WARN
@@ -86,7 +86,7 @@ const char *cam_get_module_name(unsigned int module_id);
  * @args     :  Arguments which needs to be print in log
  */
 #define CAM_WARN(__module, fmt, args...)                           \
-	pr_warn("CAM_WARN: %s: %s: %d " fmt "\n",                     \
+	pr_info("CAM_WARN: %s: %s: %d " fmt "\n",                  \
 		cam_get_module_name(__module), __func__,  __LINE__, ##args)
 /*
  * CAM_INFO
@@ -128,7 +128,7 @@ const char *cam_get_module_name(unsigned int module_id);
  * @brief    :  This Macro will print error print logs with ratelimit
  */
 #define CAM_ERR_RATE_LIMIT(__module, fmt, args...)                 \
-	pr_err_ratelimited("CAM_ERR: %s: %s: %d " fmt "\n",            \
+	pr_info_ratelimited("CAM_ERR: %s: %s: %d " fmt "\n",       \
 		cam_get_module_name(__module), __func__,  __LINE__, ##args)
 /*
  * CAM_WARN_RATE_LIMIT
@@ -139,7 +139,7 @@ const char *cam_get_module_name(unsigned int module_id);
  * @args     :  Arguments which needs to be print in log
  */
 #define CAM_WARN_RATE_LIMIT(__module, fmt, args...)                 \
-	pr_warn_ratelimited("CAM_WARN: %s: %s: %d " fmt "\n",           \
+	pr_info_ratelimited("CAM_WARN: %s: %s: %d " fmt "\n",       \
 		cam_get_module_name(__module), __func__,  __LINE__, ##args)
 
 /*
@@ -158,7 +158,7 @@ const char *cam_get_module_name(unsigned int module_id);
 			(interval * HZ),                                    \
 			burst);                                             \
 		if (__ratelimit(&_rs))                                      \
-			pr_warn(                                            \
+			pr_info(                                            \
 				"CAM_WARN: %s: %s: %d " fmt "\n",           \
 				cam_get_module_name(__module), __func__,    \
 				__LINE__, ##args);                          \
@@ -202,7 +202,7 @@ const char *cam_get_module_name(unsigned int module_id);
 			(interval * HZ),                                   \
 			burst);                                            \
 		if (__ratelimit(&_rs))                                     \
-			pr_err(                                            \
+			pr_info(                                           \
 				"CAM_ERR: %s: %s: %d " fmt "\n",           \
 				cam_get_module_name(__module), __func__,   \
 				__LINE__, ##args);                         \