Forráskód Böngészése

qcacld-3.0: Route logging through CDF_TRACE

AR_print and cdf_print macros were not logging to the driver log.

Change-Id: I11bc86f6c8ee91866c8e27903eaa15966111ce62
CRs-Fixed: 940770
Houston Hoffman 9 éve
szülő
commit
04507d3cf4
2 módosított fájl, 10 hozzáadás és 28 törlés
  1. 5 4
      core/cdf/inc/cdf_types.h
  2. 5 24
      uapi/linux/osapi_linux.h

+ 5 - 4
core/cdf/inc/cdf_types.h

@@ -200,10 +200,6 @@ typedef bool (*cdf_irqlocked_func_t)(void *);
 /* Prototype of timer function */
 typedef void (*cdf_softirq_timer_func_t)(void *);
 
-#define cdf_print         __cdf_print
-#define cdf_vprint        __cdf_vprint
-#define cdf_snprint       __cdf_snprint
-
 #define cdf_offsetof(type, field) offsetof(type, field)
 
 /**
@@ -264,6 +260,11 @@ typedef enum {
 	CDF_MODULE_ID_MAX
 } CDF_MODULE_ID;
 
+#define cdf_print(args...) \
+	CDF_TRACE(CDF_MODULE_ID_CDF, CDF_TRACE_LEVEL_ERROR, ## args)
+#define cdf_vprint        __cdf_vprint
+#define cdf_snprint       __cdf_snprint
+
 /**
  * typedef enum tCDF_CON_MODE - Concurrency role.
  *

+ 5 - 24
uapi/linux/osapi_linux.h

@@ -71,31 +71,12 @@
 #define A_MEMSET(addr, value, size)     memset((addr), (value), (size))
 #define A_MEMCMP(addr1, addr2, len)     memcmp((addr1), (addr2), (len))
 
-#if defined(ANDROID_ENV) && defined(CONFIG_ANDROID_LOGGER)
-extern unsigned int enablelogcat;
-extern int android_logger_lv(void *module, int mask);
-enum logidx { LOG_MAIN_IDX = 0 };
-extern int logger_write(const enum logidx idx,
-			const unsigned char prio,
-			const char __kernel *const tag,
-			const char __kernel *const fmt, ...);
-#define A_ANDROID_PRINTF(mask, module, tags, args ...) do {  \
-		if (enablelogcat) \
-			logger_write(LOG_MAIN_IDX, android_logger_lv(module, mask), tags, args); \
-		else \
-			printk(KERN_ALERT args); \
-} while (0)
-#ifdef DEBUG
-#define A_LOGGER_MODULE_NAME(x) # x
 #define A_LOGGER(mask, mod, args ...) \
-	A_ANDROID_PRINTF(mask, &GET_ATH_MODULE_DEBUG_VAR_NAME(mod), "ar6k_" A_LOGGER_MODULE_NAME(mod), args);
-#endif
-#define A_PRINTF(args ...) A_ANDROID_PRINTF(ATH_DEBUG_INFO, NULL, "ar6k_driver", args)
-#else
-#define A_LOGGER(mask, mod, args ...)    printk(args)
-#define A_PRINTF(args ...)               printk(args)
-#endif /* ANDROID */
-#define A_PRINTF_LOG(args ...)           printk(args)
+		CDF_TRACE(CDF_MODULE_ID_CDF, CDF_TRACE_LEVEL_ERROR, ## args)
+#define A_PRINTF(args ...) \
+		CDF_TRACE(CDF_MODULE_ID_CDF, CDF_TRACE_LEVEL_ERROR, ## args)
+#define A_PRINTF_LOG(args ...) \
+		CDF_TRACE(CDF_MODULE_ID_CDF, CDF_TRACE_LEVEL_ERROR, ## args)
 #define A_SNPRINTF(buf, len, args ...)   snprintf (buf, len, args)
 
 /*