Explorar o código

qcacmn: Add a new trace level for automation of logging

Add a new logging trace level QDF_TRACE_LEVEL_TRACE for
automation scripts to process the logging.

A new logging Infrastructure is to be added where the newly
added logging level QDF_TRACE_LEVEL_TRACE will be used to
log in specific format and these logs will be used by
post processing script to figure out right FA or to figure
the module from where the path deviated. It will help out CST
to figure out the right FA if there are any issues in the driver.

Change-Id: I7b5772026e4fc2f8e5205663e9150c861b69fdfc
CRs-Fixed: 2290893
Ashish Kumar Dhanotiya %!s(int64=6) %!d(string=hai) anos
pai
achega
9d0ed2532c
Modificáronse 2 ficheiros con 7 adicións e 1 borrados
  1. 5 0
      qdf/inc/qdf_types.h
  2. 2 1
      qdf/linux/src/qdf_trace.c

+ 5 - 0
qdf/inc/qdf_types.h

@@ -484,6 +484,10 @@ typedef enum {
  * @QDF_TRACE_LEVEL_INFO_LOW: Low level operational messages that require
  *			      no action
  * @QDF_TRACE_LEVEL_DEBUG: Information useful to developers for debugging
+ * @QDF_TRACE_LEVEL_TRACE: Indicates trace level for automation scripts,
+ *			whenever there is a context switch in driver, one
+ *			print using this trace level will be added with
+ *			the help of qdf_trace api.
  * @QDF_TRACE_LEVEL_ALL: All trace levels
  * @QDF_TRACE_LEVEL_MAX: Max trace level
  */
@@ -497,6 +501,7 @@ typedef enum {
 	QDF_TRACE_LEVEL_INFO_MED,
 	QDF_TRACE_LEVEL_INFO_LOW,
 	QDF_TRACE_LEVEL_DEBUG,
+	QDF_TRACE_LEVEL_TRACE,
 	QDF_TRACE_LEVEL_ALL,
 	QDF_TRACE_LEVEL_MAX
 } QDF_TRACE_LEVEL;

+ 2 - 1
qdf/linux/src/qdf_trace.c

@@ -2913,11 +2913,12 @@ void qdf_trace_msg_cmn(unsigned int idx,
 			[QDF_TRACE_LEVEL_INFO_MED] = "IM",
 			[QDF_TRACE_LEVEL_INFO_LOW] = "IL",
 			[QDF_TRACE_LEVEL_DEBUG] = "D",
+			[QDF_TRACE_LEVEL_TRACE] = "T",
 			[QDF_TRACE_LEVEL_ALL] = "" };
 
 		/* print the prefix string into the string buffer... */
 		n = scnprintf(str_buffer, QDF_TRACE_BUFFER_SIZE,
-			     "%s: [%d:%2s:%s] ", qdf_trace_wlan_modname(),
+			     "%s: [%d:%s:%s] ", qdf_trace_wlan_modname(),
 			     in_interrupt() ? 0 : current->pid,
 			     VERBOSE_STR[verbose],
 			     g_qdf_category_name[category].category_name_str);