mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-22 17:36:20 +03:00
gpu: nvgpu: change logging enum names
Add nvgpu prefix to logging enums. In debug mode QNX, Integrity have already a hashdef DEBUG and it is conflicting with logging enum DEBUG Change-Id: I882e566302842f8b79daf11d5f0850dec222cfea Signed-off-by: Shashank Singh <shashsingh@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1570193 Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: svccoveritychecker <svccoveritychecker@nvidia.com> Reviewed-by: Alex Waterman <alexw@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Vijayakumar Subbu <vsubbu@nvidia.com>
This commit is contained in:
committed by
mobile promotions
parent
33f475d6d8
commit
14d99f1575
@@ -82,7 +82,7 @@ static void __nvgpu_really_print_log(u32 trace, const char *gpu_name,
|
|||||||
const char *log_type = log_types[type];
|
const char *log_type = log_types[type];
|
||||||
|
|
||||||
switch (type) {
|
switch (type) {
|
||||||
case DEBUG:
|
case NVGPU_DEBUG:
|
||||||
/*
|
/*
|
||||||
* We could use pr_debug() here but we control debug enablement
|
* We could use pr_debug() here but we control debug enablement
|
||||||
* separately from the Linux kernel. Perhaps this is a bug in
|
* separately from the Linux kernel. Perhaps this is a bug in
|
||||||
@@ -90,13 +90,13 @@ static void __nvgpu_really_print_log(u32 trace, const char *gpu_name,
|
|||||||
*/
|
*/
|
||||||
pr_info(LOG_FMT, name, func_name, line, log_type, log);
|
pr_info(LOG_FMT, name, func_name, line, log_type, log);
|
||||||
break;
|
break;
|
||||||
case INFO:
|
case NVGPU_INFO:
|
||||||
pr_info(LOG_FMT, name, func_name, line, log_type, log);
|
pr_info(LOG_FMT, name, func_name, line, log_type, log);
|
||||||
break;
|
break;
|
||||||
case WARNING:
|
case NVGPU_WARNING:
|
||||||
pr_warn(LOG_FMT, name, func_name, line, log_type, log);
|
pr_warn(LOG_FMT, name, func_name, line, log_type, log);
|
||||||
break;
|
break;
|
||||||
case ERROR:
|
case NVGPU_ERROR:
|
||||||
pr_err(LOG_FMT, name, func_name, line, log_type, log);
|
pr_err(LOG_FMT, name, func_name, line, log_type, log);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -134,5 +134,5 @@ void __nvgpu_log_dbg(struct gk20a *g, u32 log_mask,
|
|||||||
va_end(args);
|
va_end(args);
|
||||||
|
|
||||||
__nvgpu_really_print_log(g->log_trace, nvgpu_log_name(g),
|
__nvgpu_really_print_log(g->log_trace, nvgpu_log_name(g),
|
||||||
func_name, line, DEBUG, log);
|
func_name, line, NVGPU_DEBUG, log);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -29,10 +29,10 @@
|
|||||||
struct gk20a;
|
struct gk20a;
|
||||||
|
|
||||||
enum nvgpu_log_type {
|
enum nvgpu_log_type {
|
||||||
ERROR,
|
NVGPU_ERROR,
|
||||||
WARNING,
|
NVGPU_WARNING,
|
||||||
DEBUG,
|
NVGPU_DEBUG,
|
||||||
INFO,
|
NVGPU_INFO,
|
||||||
};
|
};
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@@ -118,7 +118,7 @@ int nvgpu_log_mask_enabled(struct gk20a *g, u32 log_mask);
|
|||||||
* Uncondtionally print an error message.
|
* Uncondtionally print an error message.
|
||||||
*/
|
*/
|
||||||
#define nvgpu_err(g, fmt, arg...) \
|
#define nvgpu_err(g, fmt, arg...) \
|
||||||
__nvgpu_log_msg(g, __func__, __LINE__, ERROR, fmt, ##arg)
|
__nvgpu_log_msg(g, __func__, __LINE__, NVGPU_ERROR, fmt, ##arg)
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* nvgpu_err - Print a warning
|
* nvgpu_err - Print a warning
|
||||||
@@ -130,7 +130,7 @@ int nvgpu_log_mask_enabled(struct gk20a *g, u32 log_mask);
|
|||||||
* Uncondtionally print a warming message.
|
* Uncondtionally print a warming message.
|
||||||
*/
|
*/
|
||||||
#define nvgpu_warn(g, fmt, arg...) \
|
#define nvgpu_warn(g, fmt, arg...) \
|
||||||
__nvgpu_log_msg(g, __func__, __LINE__, WARNING, fmt, ##arg)
|
__nvgpu_log_msg(g, __func__, __LINE__, NVGPU_WARNING, fmt, ##arg)
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* nvgpu_info - Print an info message
|
* nvgpu_info - Print an info message
|
||||||
@@ -142,7 +142,7 @@ int nvgpu_log_mask_enabled(struct gk20a *g, u32 log_mask);
|
|||||||
* Unconditionally print an information message.
|
* Unconditionally print an information message.
|
||||||
*/
|
*/
|
||||||
#define nvgpu_info(g, fmt, arg...) \
|
#define nvgpu_info(g, fmt, arg...) \
|
||||||
__nvgpu_log_msg(g, __func__, __LINE__, INFO, fmt, ##arg)
|
__nvgpu_log_msg(g, __func__, __LINE__, NVGPU_INFO, fmt, ##arg)
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Some convenience macros.
|
* Some convenience macros.
|
||||||
@@ -170,7 +170,7 @@ extern u32 nvgpu_dbg_mask;
|
|||||||
do { \
|
do { \
|
||||||
if (((log_mask) & nvgpu_dbg_mask) != 0) \
|
if (((log_mask) & nvgpu_dbg_mask) != 0) \
|
||||||
__nvgpu_log_msg(NULL, __func__, __LINE__, \
|
__nvgpu_log_msg(NULL, __func__, __LINE__, \
|
||||||
DEBUG, fmt "\n", ##arg); \
|
NVGPU_DEBUG, fmt "\n", ##arg); \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
Reference in New Issue
Block a user