diff --git a/scst/include/scst_debug.h b/scst/include/scst_debug.h index cc6824c1d..33309b0a1 100644 --- a/scst/include/scst_debug.h +++ b/scst/include/scst_debug.h @@ -85,7 +85,9 @@ #define TRACE_FUNCTION 0x00000002 #define TRACE_LINE 0x00000004 #define TRACE_PID 0x00000008 +#ifndef GENERATING_UPSTREAM_PATCH #define TRACE_ENTRYEXIT 0x00000010 +#endif #define TRACE_BUFF 0x00000020 #define TRACE_MEMORY 0x00000040 #define TRACE_SG_OP 0x00000080 @@ -249,6 +251,7 @@ do { \ PRINT(KERN_CONT, format, args); \ } while (0) +#ifndef GENERATING_UPSTREAM_PATCH #define TRACE_ENTRY() \ do { \ if (trace_flag & TRACE_ENTRYEXIT) { \ @@ -302,6 +305,7 @@ do { \ } \ } \ } while (0) +#endif #else /* CONFIG_SCST_DEBUG */ @@ -313,10 +317,12 @@ do { \ #define TRACE_MGMT_DBG_SPECIAL(format, args...) do {} while (0) #define TRACE_BUFFER(message, buff, len) do {} while (0) #define TRACE_BUFF_FLAG(flag, message, buff, len) do {} while (0) +#ifndef GENERATING_UPSTREAM_PATCH #define TRACE_ENTRY() do {} while (0) #define TRACE_EXIT() do {} while (0) #define TRACE_EXIT_RES(res) do {} while (0) #define TRACE_EXIT_HRES(res) do {} while (0) +#endif #ifdef LOG_PREFIX diff --git a/scst/src/scst_proc.c b/scst/src/scst_proc.c index b05532b52..7ec08b992 100644 --- a/scst/src/scst_proc.c +++ b/scst/src/scst_proc.c @@ -99,7 +99,9 @@ static struct scst_trace_log scst_proc_trace_tbl[] = { TRACE_SG_OP, "sg" }, { TRACE_MEMORY, "mem" }, { TRACE_BUFF, "buff" }, +#ifndef GENERATING_UPSTREAM_PATCH { TRACE_ENTRYEXIT, "entryexit" }, +#endif { TRACE_PID, "pid" }, { TRACE_LINE, "line" }, { TRACE_FUNCTION, "function" }, diff --git a/scst/src/scst_sysfs.c b/scst/src/scst_sysfs.c index 7bf56f25e..730064b79 100644 --- a/scst/src/scst_sysfs.c +++ b/scst/src/scst_sysfs.c @@ -70,7 +70,9 @@ static struct scst_trace_log scst_trace_tbl[] = { TRACE_SG_OP, "sg" }, { TRACE_MEMORY, "mem" }, { TRACE_BUFF, "buff" }, +#ifndef GENERATING_UPSTREAM_PATCH { TRACE_ENTRYEXIT, "entryexit" }, +#endif { TRACE_PID, "pid" }, { TRACE_LINE, "line" }, { TRACE_FUNCTION, "function" }, @@ -1212,7 +1214,11 @@ static ssize_t scst_trace_level_show(const struct scst_trace_log *local_tbl, " echo \"value DEC|0xHEX|0OCT\" >trace_level\n" " echo \"add|del TOKEN\" >trace_level\n" "\nwhere TOKEN is one of [debug, function, line, pid,\n" +#ifndef GENERATING_UPSTREAM_PATCH " entryexit, buff, mem, sg, out_of_mem,\n" +#else + " buff, mem, sg, out_of_mem,\n" +#endif " special, scsi, mgmt, minor,\n" " mgmt_minor, mgmt_dbg, scsi_serializing,\n" " retry, recv_bot, send_bot, recv_top,\n"