linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/6] Several changes for the UPIU trace
@ 2020-12-14 20:20 Bean Huo
  2020-12-14 20:20 ` [PATCH v3 1/6] scsi: ufs: Remove stringize operator '#' restriction Bean Huo
                   ` (6 more replies)
  0 siblings, 7 replies; 15+ messages in thread
From: Bean Huo @ 2020-12-14 20:20 UTC (permalink / raw)
  To: alim.akhtar, avri.altman, asutoshd, jejb, martin.petersen,
	stanley.chu, beanhuo, bvanassche, tomas.winkler, cang, rostedt,
	joe
  Cc: linux-scsi, linux-kernel

From: Bean Huo <beanhuo@micron.com>

Changelog:

V2--V3:
  1. Fix a typo in patch 1/6 (Reported-by: Joe Perches <joe@perches.com>)

V1--V2:
  1. Convert __get_str(str) to __print_symbolic()
  2. Add new patches 1/6, 2/6,3/6
  3. Use __print_symbolic() in patch 6/6

Bean Huo (6):
  scsi: ufs: Remove stringize operator '#' restriction
  scsi: ufs: Use __print_symbolic() for UFS trace string print
  scsi: ufs: Don't call trace_ufshcd_upiu() in case trace poit is
    disabled
  scsi: ufs: Distinguish between query REQ and query RSP in query trace
  scsi: ufs: Distinguish between TM request UPIU and response UPIU in TM
    UPIU trace
  scsi: ufs: Make UPIU trace easier differentiate among CDB, OSF, and TM

 drivers/scsi/ufs/ufs.h     |  17 ++++++
 drivers/scsi/ufs/ufshcd.c  |  72 ++++++++++++++++---------
 include/trace/events/ufs.h | 108 +++++++++++++++++++++++--------------
 3 files changed, 131 insertions(+), 66 deletions(-)

-- 
2.17.1


^ permalink raw reply	[flat|nested] 15+ messages in thread

* [PATCH v3 1/6] scsi: ufs: Remove stringize operator '#' restriction
  2020-12-14 20:20 [PATCH v3 0/6] Several changes for the UPIU trace Bean Huo
@ 2020-12-14 20:20 ` Bean Huo
  2020-12-14 21:23   ` Joe Perches
  2020-12-14 23:11   ` David Laight
  2020-12-14 20:20 ` [PATCH v3 2/6] scsi: ufs: Use __print_symbolic() for UFS trace string print Bean Huo
                   ` (5 subsequent siblings)
  6 siblings, 2 replies; 15+ messages in thread
From: Bean Huo @ 2020-12-14 20:20 UTC (permalink / raw)
  To: alim.akhtar, avri.altman, asutoshd, jejb, martin.petersen,
	stanley.chu, beanhuo, bvanassche, tomas.winkler, cang, rostedt,
	joe
  Cc: linux-scsi, linux-kernel

From: Bean Huo <beanhuo@micron.com>

Current EM macro definition, we use stringize operator '#', which turns
the argument it precedes into a quoted string. Thus requires the symbol
of __print_symbolic() should be the string corresponding to the name of
the enum.

However, we have other cases, the symbol and enum name are not the same,
we can redefine EM/EMe, but there will introduce some redundant codes.
This patch is to remove this restriction, let others reuse the current
EM/EMe definition.

Acked-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Signed-off-by: Bean Huo <beanhuo@micron.com>
---
 include/trace/events/ufs.h | 40 +++++++++++++++++++-------------------
 1 file changed, 20 insertions(+), 20 deletions(-)

diff --git a/include/trace/events/ufs.h b/include/trace/events/ufs.h
index 0bd54a184391..fa755394bc0f 100644
--- a/include/trace/events/ufs.h
+++ b/include/trace/events/ufs.h
@@ -20,28 +20,28 @@
 		{ SYNCHRONIZE_CACHE,	"SYNC" },			\
 		{ UNMAP,		"UNMAP" })
 
-#define UFS_LINK_STATES			\
-	EM(UIC_LINK_OFF_STATE)		\
-	EM(UIC_LINK_ACTIVE_STATE)	\
-	EMe(UIC_LINK_HIBERN8_STATE)
-
-#define UFS_PWR_MODES			\
-	EM(UFS_ACTIVE_PWR_MODE)		\
-	EM(UFS_SLEEP_PWR_MODE)		\
-	EM(UFS_POWERDOWN_PWR_MODE)	\
-	EMe(UFS_DEEPSLEEP_PWR_MODE)
-
-#define UFSCHD_CLK_GATING_STATES	\
-	EM(CLKS_OFF)			\
-	EM(CLKS_ON)			\
-	EM(REQ_CLKS_OFF)		\
-	EMe(REQ_CLKS_ON)
+#define UFS_LINK_STATES						\
+	EM(UIC_LINK_OFF_STATE,		"UIC_LINK_OFF_STATE")		\
+	EM(UIC_LINK_ACTIVE_STATE,	"UIC_LINK_ACTIVE_STATE")	\
+	EMe(UIC_LINK_HIBERN8_STATE,	"UIC_LINK_HIBERN8_STATE")
+
+#define UFS_PWR_MODES							\
+	EM(UFS_ACTIVE_PWR_MODE,		"UFS_ACTIVE_PWR_MODE")		\
+	EM(UFS_SLEEP_PWR_MODE,		"UFS_SLEEP_PWR_MODE")		\
+	EM(UFS_POWERDOWN_PWR_MODE,	"UFS_POWERDOWN_PWR_MODE")	\
+	EMe(UFS_DEEPSLEEP_PWR_MODE,	"UFS_DEEPSLEEP_PWR_MODE")
+
+#define UFSCHD_CLK_GATING_STATES				\
+	EM(CLKS_OFF,			"CLKS_OFF")		\
+	EM(CLKS_ON,			"CLKS_ON")		\
+	EM(REQ_CLKS_OFF,		"REQ_CLKS_OFF")		\
+	EMe(REQ_CLKS_ON,		"REQ_CLKS_ON")
 
 /* Enums require being exported to userspace, for user tool parsing */
 #undef EM
 #undef EMe
-#define EM(a)	TRACE_DEFINE_ENUM(a);
-#define EMe(a)	TRACE_DEFINE_ENUM(a);
+#define EM(a, b)	TRACE_DEFINE_ENUM(a);
+#define EMe(a, b)	TRACE_DEFINE_ENUM(a);
 
 UFS_LINK_STATES;
 UFS_PWR_MODES;
@@ -53,8 +53,8 @@ UFSCHD_CLK_GATING_STATES;
  */
 #undef EM
 #undef EMe
-#define EM(a)	{ a, #a },
-#define EMe(a)	{ a, #a }
+#define EM(a, b)	{a, b},
+#define EMe(a, b)	{a, b}
 
 TRACE_EVENT(ufshcd_clk_gating,
 
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v3 2/6] scsi: ufs: Use __print_symbolic() for UFS trace string print
  2020-12-14 20:20 [PATCH v3 0/6] Several changes for the UPIU trace Bean Huo
  2020-12-14 20:20 ` [PATCH v3 1/6] scsi: ufs: Remove stringize operator '#' restriction Bean Huo
@ 2020-12-14 20:20 ` Bean Huo
  2020-12-14 20:20 ` [PATCH v3 3/6] scsi: ufs: Don't call trace_ufshcd_upiu() in case trace poit is disabled Bean Huo
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 15+ messages in thread
From: Bean Huo @ 2020-12-14 20:20 UTC (permalink / raw)
  To: alim.akhtar, avri.altman, asutoshd, jejb, martin.petersen,
	stanley.chu, beanhuo, bvanassche, tomas.winkler, cang, rostedt,
	joe
  Cc: linux-scsi, linux-kernel

From: Bean Huo <beanhuo@micron.com>

__print_symbolic() is designed for exporting the print formatting table
to userspace and allows parsing tool, such as trace-cmd and perf, to analyze
trace log according to this print formatting table, meanwhile, by using
__print_symbolic()s, save space in the trace ring buffer.

original print format:

print fmt: "%s: %s: HDR:%s, CDB:%s", __get_str(str), __get_str(dev_name),
            __print_hex(REC->hdr, sizeof(REC->hdr)),
            __print_hex(REC->tsf, sizeof(REC->tsf))

after this change:

print fmt: "%s: %s: HDR:%s, CDB:%s",
      print_symbolic(REC->str_t, {0, "send"},
                                 {1, "complete"},
                                 {2, "dev_complete"},
                                 {3, "query_send"},
                                 {4, "query_complete"},
                                 {5, "query_complete_err"},
                                 {6, "tm_send"},
                                 {7, "tm_complete"},
                                 {8, "tm_complete_err"}),
      __get_str(dev_name), __print_hex(REC->hdr, sizeof(REC->hdr)),
      __print_hex(REC->tsf, sizeof(REC->tsf))

Note: This patch just converts current __get_str(str) to __print_symbolic(),
      the original tracing log will not be affected by this change, so it
      doesn't break what current parsers expect.

Acked-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Signed-off-by: Bean Huo <beanhuo@micron.com>
---
 drivers/scsi/ufs/ufs.h     | 10 +++++++
 drivers/scsi/ufs/ufshcd.c  | 48 ++++++++++++++++-----------------
 include/trace/events/ufs.h | 54 ++++++++++++++++++++++++--------------
 3 files changed, 69 insertions(+), 43 deletions(-)

diff --git a/drivers/scsi/ufs/ufs.h b/drivers/scsi/ufs/ufs.h
index 14dfda735adf..ba24b504f85a 100644
--- a/drivers/scsi/ufs/ufs.h
+++ b/drivers/scsi/ufs/ufs.h
@@ -545,6 +545,16 @@ struct ufs_dev_info {
 	u8 b_presrv_uspc_en;
 };
 
+/*
+ * This enum is used in string mapping in include/trace/events/ufs.h.
+ */
+enum ufs_trace_str_t {
+	UFS_CMD_SEND, UFS_CMD_COMP, UFS_DEV_COMP,
+	UFS_QUERY_SEND, UFS_QUERY_COMP, UFS_QUERY_ERR,
+	UFS_TM_SEND, UFS_TM_COMP, UFS_TM_ERR
+};
+
+
 /**
  * ufs_is_valid_unit_desc_lun - checks if the given LUN has a unit descriptor
  * @dev_info: pointer of instance of struct ufs_dev_info
diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index e221add25a7e..66babbd8bf32 100644
--- a/drivers/scsi/ufs/ufshcd.c
+++ b/drivers/scsi/ufs/ufshcd.c
@@ -305,53 +305,53 @@ static void ufshcd_scsi_block_requests(struct ufs_hba *hba)
 }
 
 static void ufshcd_add_cmd_upiu_trace(struct ufs_hba *hba, unsigned int tag,
-		const char *str)
+				      enum ufs_trace_str_t str_t)
 {
 	struct utp_upiu_req *rq = hba->lrb[tag].ucd_req_ptr;
 
-	trace_ufshcd_upiu(dev_name(hba->dev), str, &rq->header, &rq->sc.cdb);
+	trace_ufshcd_upiu(dev_name(hba->dev), str_t, &rq->header, &rq->sc.cdb);
 }
 
 static void ufshcd_add_query_upiu_trace(struct ufs_hba *hba, unsigned int tag,
-		const char *str)
+					enum ufs_trace_str_t str_t)
 {
 	struct utp_upiu_req *rq = hba->lrb[tag].ucd_req_ptr;
 
-	trace_ufshcd_upiu(dev_name(hba->dev), str, &rq->header, &rq->qr);
+	trace_ufshcd_upiu(dev_name(hba->dev), str_t, &rq->header, &rq->qr);
 }
 
 static void ufshcd_add_tm_upiu_trace(struct ufs_hba *hba, unsigned int tag,
-		const char *str)
+				     enum ufs_trace_str_t str_t)
 {
 	int off = (int)tag - hba->nutrs;
 	struct utp_task_req_desc *descp = &hba->utmrdl_base_addr[off];
 
-	trace_ufshcd_upiu(dev_name(hba->dev), str, &descp->req_header,
+	trace_ufshcd_upiu(dev_name(hba->dev), str_t, &descp->req_header,
 			&descp->input_param1);
 }
 
 static void ufshcd_add_uic_command_trace(struct ufs_hba *hba,
 					 struct uic_command *ucmd,
-					 const char *str)
+					 enum ufs_trace_str_t str_t)
 {
 	u32 cmd;
 
 	if (!trace_ufshcd_uic_command_enabled())
 		return;
 
-	if (!strcmp(str, "send"))
+	if (str_t == UFS_CMD_SEND)
 		cmd = ucmd->command;
 	else
 		cmd = ufshcd_readl(hba, REG_UIC_COMMAND);
 
-	trace_ufshcd_uic_command(dev_name(hba->dev), str, cmd,
+	trace_ufshcd_uic_command(dev_name(hba->dev), str_t, cmd,
 				 ufshcd_readl(hba, REG_UIC_COMMAND_ARG_1),
 				 ufshcd_readl(hba, REG_UIC_COMMAND_ARG_2),
 				 ufshcd_readl(hba, REG_UIC_COMMAND_ARG_3));
 }
 
-static void ufshcd_add_command_trace(struct ufs_hba *hba,
-		unsigned int tag, const char *str)
+static void ufshcd_add_command_trace(struct ufs_hba *hba, unsigned int tag,
+				     enum ufs_trace_str_t str_t)
 {
 	sector_t lba = -1;
 	u8 opcode = 0, group_id = 0;
@@ -363,13 +363,13 @@ static void ufshcd_add_command_trace(struct ufs_hba *hba,
 	if (!trace_ufshcd_command_enabled()) {
 		/* trace UPIU W/O tracing command */
 		if (cmd)
-			ufshcd_add_cmd_upiu_trace(hba, tag, str);
+			ufshcd_add_cmd_upiu_trace(hba, tag, str_t);
 		return;
 	}
 
 	if (cmd) { /* data phase exists */
 		/* trace UPIU also */
-		ufshcd_add_cmd_upiu_trace(hba, tag, str);
+		ufshcd_add_cmd_upiu_trace(hba, tag, str_t);
 		opcode = cmd->cmnd[0];
 		if ((opcode == READ_10) || (opcode == WRITE_10)) {
 			/*
@@ -392,7 +392,7 @@ static void ufshcd_add_command_trace(struct ufs_hba *hba,
 
 	intr = ufshcd_readl(hba, REG_INTERRUPT_STATUS);
 	doorbell = ufshcd_readl(hba, REG_UTP_TRANSFER_REQ_DOOR_BELL);
-	trace_ufshcd_command(dev_name(hba->dev), str, tag,
+	trace_ufshcd_command(dev_name(hba->dev), str_t, tag,
 			doorbell, transfer_len, intr, lba, opcode, group_id);
 }
 
@@ -1994,7 +1994,7 @@ void ufshcd_send_command(struct ufs_hba *hba, unsigned int task_tag)
 	lrbp->issue_time_stamp = ktime_get();
 	lrbp->compl_time_stamp = ktime_set(0, 0);
 	ufshcd_vops_setup_xfer_req(hba, task_tag, (lrbp->cmd ? true : false));
-	ufshcd_add_command_trace(hba, task_tag, "send");
+	ufshcd_add_command_trace(hba, task_tag, UFS_CMD_SEND);
 	ufshcd_clk_scaling_start_busy(hba);
 	__set_bit(task_tag, &hba->outstanding_reqs);
 	ufshcd_writel(hba, 1 << task_tag, REG_UTP_TRANSFER_REQ_DOOR_BELL);
@@ -2130,7 +2130,7 @@ ufshcd_dispatch_uic_cmd(struct ufs_hba *hba, struct uic_command *uic_cmd)
 	ufshcd_writel(hba, uic_cmd->argument2, REG_UIC_COMMAND_ARG_2);
 	ufshcd_writel(hba, uic_cmd->argument3, REG_UIC_COMMAND_ARG_3);
 
-	ufshcd_add_uic_command_trace(hba, uic_cmd, "send");
+	ufshcd_add_uic_command_trace(hba, uic_cmd, UFS_CMD_SEND);
 
 	/* Write UIC Cmd */
 	ufshcd_writel(hba, uic_cmd->command & COMMAND_OPCODE_MASK,
@@ -2838,7 +2838,7 @@ static int ufshcd_exec_dev_cmd(struct ufs_hba *hba,
 
 	hba->dev_cmd.complete = &wait;
 
-	ufshcd_add_query_upiu_trace(hba, tag, "query_send");
+	ufshcd_add_query_upiu_trace(hba, tag, UFS_QUERY_SEND);
 	/* Make sure descriptors are ready before ringing the doorbell */
 	wmb();
 	spin_lock_irqsave(hba->host->host_lock, flags);
@@ -2849,7 +2849,7 @@ static int ufshcd_exec_dev_cmd(struct ufs_hba *hba,
 
 out:
 	ufshcd_add_query_upiu_trace(hba, tag,
-			err ? "query_complete_err" : "query_complete");
+			err ? UFS_QUERY_ERR : UFS_QUERY_COMP);
 
 out_put_tag:
 	blk_put_request(req);
@@ -4993,7 +4993,7 @@ static irqreturn_t ufshcd_uic_cmd_compl(struct ufs_hba *hba, u32 intr_status)
 
 	if (retval == IRQ_HANDLED)
 		ufshcd_add_uic_command_trace(hba, hba->active_uic_cmd,
-					     "complete");
+					     UFS_CMD_COMP);
 	return retval;
 }
 
@@ -5017,7 +5017,7 @@ static void __ufshcd_transfer_req_compl(struct ufs_hba *hba,
 		lrbp->compl_time_stamp = ktime_get();
 		cmd = lrbp->cmd;
 		if (cmd) {
-			ufshcd_add_command_trace(hba, index, "complete");
+			ufshcd_add_command_trace(hba, index, UFS_CMD_COMP);
 			result = ufshcd_transfer_rsp_status(hba, lrbp);
 			scsi_dma_unmap(cmd);
 			cmd->result = result;
@@ -5031,7 +5031,7 @@ static void __ufshcd_transfer_req_compl(struct ufs_hba *hba,
 			lrbp->command_type == UTP_CMD_TYPE_UFS_STORAGE) {
 			if (hba->dev_cmd.complete) {
 				ufshcd_add_command_trace(hba, index,
-						"dev_complete");
+							 UFS_DEV_COMP);
 				complete(hba->dev_cmd.complete);
 				update_scaling = true;
 			}
@@ -6334,7 +6334,7 @@ static int __ufshcd_issue_tm_cmd(struct ufs_hba *hba,
 
 	spin_unlock_irqrestore(host->host_lock, flags);
 
-	ufshcd_add_tm_upiu_trace(hba, task_tag, "tm_send");
+	ufshcd_add_tm_upiu_trace(hba, task_tag, UFS_TM_SEND);
 
 	/* wait until the task management command is completed */
 	err = wait_for_completion_io_timeout(&wait,
@@ -6345,7 +6345,7 @@ static int __ufshcd_issue_tm_cmd(struct ufs_hba *hba,
 		 * use-after-free.
 		 */
 		req->end_io_data = NULL;
-		ufshcd_add_tm_upiu_trace(hba, task_tag, "tm_complete_err");
+		ufshcd_add_tm_upiu_trace(hba, task_tag, UFS_TM_ERR);
 		dev_err(hba->dev, "%s: task management cmd 0x%.2x timed-out\n",
 				__func__, tm_function);
 		if (ufshcd_clear_tm_cmd(hba, free_slot))
@@ -6356,7 +6356,7 @@ static int __ufshcd_issue_tm_cmd(struct ufs_hba *hba,
 		err = 0;
 		memcpy(treq, hba->utmrdl_base_addr + free_slot, sizeof(*treq));
 
-		ufshcd_add_tm_upiu_trace(hba, task_tag, "tm_complete");
+		ufshcd_add_tm_upiu_trace(hba, task_tag, UFS_TM_COMP);
 	}
 
 	spin_lock_irqsave(hba->host->host_lock, flags);
diff --git a/include/trace/events/ufs.h b/include/trace/events/ufs.h
index fa755394bc0f..335a8d6b490f 100644
--- a/include/trace/events/ufs.h
+++ b/include/trace/events/ufs.h
@@ -37,6 +37,17 @@
 	EM(REQ_CLKS_OFF,		"REQ_CLKS_OFF")		\
 	EMe(REQ_CLKS_ON,		"REQ_CLKS_ON")
 
+#define UFS_CMD_TRACE_STRINGS					\
+	EM(UFS_CMD_SEND,	"send")				\
+	EM(UFS_CMD_COMP,	"complete")			\
+	EM(UFS_DEV_COMP,	"dev_complete")			\
+	EM(UFS_QUERY_SEND,	"query_send")			\
+	EM(UFS_QUERY_COMP,	"query_complete")		\
+	EM(UFS_QUERY_ERR,	"query_complete_err")		\
+	EM(UFS_TM_SEND,		"tm_send")			\
+	EM(UFS_TM_COMP,		"tm_complete")			\
+	EMe(UFS_TM_ERR,		"tm_complete_err")
+
 /* Enums require being exported to userspace, for user tool parsing */
 #undef EM
 #undef EMe
@@ -46,6 +57,7 @@
 UFS_LINK_STATES;
 UFS_PWR_MODES;
 UFSCHD_CLK_GATING_STATES;
+UFS_CMD_TRACE_STRINGS
 
 /*
  * Now redefine the EM() and EMe() macros to map the enums to the strings
@@ -56,6 +68,9 @@ UFSCHD_CLK_GATING_STATES;
 #define EM(a, b)	{a, b},
 #define EMe(a, b)	{a, b}
 
+#define show_ufs_cmd_trace_str(str_t)	\
+				__print_symbolic(str_t, UFS_CMD_TRACE_STRINGS)
+
 TRACE_EVENT(ufshcd_clk_gating,
 
 	TP_PROTO(const char *dev_name, int state),
@@ -223,16 +238,16 @@ DEFINE_EVENT(ufshcd_template, ufshcd_init,
 	     TP_ARGS(dev_name, err, usecs, dev_state, link_state));
 
 TRACE_EVENT(ufshcd_command,
-	TP_PROTO(const char *dev_name, const char *str, unsigned int tag,
-			u32 doorbell, int transfer_len, u32 intr, u64 lba,
-			u8 opcode, u8 group_id),
+	TP_PROTO(const char *dev_name, enum ufs_trace_str_t str_t,
+		 unsigned int tag, u32 doorbell, int transfer_len, u32 intr,
+		 u64 lba, u8 opcode, u8 group_id),
 
-	TP_ARGS(dev_name, str, tag, doorbell, transfer_len,
+	TP_ARGS(dev_name, str_t, tag, doorbell, transfer_len,
 				intr, lba, opcode, group_id),
 
 	TP_STRUCT__entry(
 		__string(dev_name, dev_name)
-		__string(str, str)
+		__field(enum ufs_trace_str_t, str_t)
 		__field(unsigned int, tag)
 		__field(u32, doorbell)
 		__field(int, transfer_len)
@@ -244,7 +259,7 @@ TRACE_EVENT(ufshcd_command,
 
 	TP_fast_assign(
 		__assign_str(dev_name, dev_name);
-		__assign_str(str, str);
+		__entry->str_t = str_t;
 		__entry->tag = tag;
 		__entry->doorbell = doorbell;
 		__entry->transfer_len = transfer_len;
@@ -256,22 +271,22 @@ TRACE_EVENT(ufshcd_command,
 
 	TP_printk(
 		"%s: %s: tag: %u, DB: 0x%x, size: %d, IS: %u, LBA: %llu, opcode: 0x%x (%s), group_id: 0x%x",
-		__get_str(str), __get_str(dev_name), __entry->tag,
-		__entry->doorbell, __entry->transfer_len,
+		show_ufs_cmd_trace_str(__entry->str_t), __get_str(dev_name),
+		__entry->tag, __entry->doorbell, __entry->transfer_len,
 		__entry->intr, __entry->lba, (u32)__entry->opcode,
 		str_opcode(__entry->opcode), (u32)__entry->group_id
 	)
 );
 
 TRACE_EVENT(ufshcd_uic_command,
-	TP_PROTO(const char *dev_name, const char *str, u32 cmd,
+	TP_PROTO(const char *dev_name, enum ufs_trace_str_t str_t, u32 cmd,
 		 u32 arg1, u32 arg2, u32 arg3),
 
-	TP_ARGS(dev_name, str, cmd, arg1, arg2, arg3),
+	TP_ARGS(dev_name, str_t, cmd, arg1, arg2, arg3),
 
 	TP_STRUCT__entry(
 		__string(dev_name, dev_name)
-		__string(str, str)
+		__field(enum ufs_trace_str_t, str_t)
 		__field(u32, cmd)
 		__field(u32, arg1)
 		__field(u32, arg2)
@@ -280,7 +295,7 @@ TRACE_EVENT(ufshcd_uic_command,
 
 	TP_fast_assign(
 		__assign_str(dev_name, dev_name);
-		__assign_str(str, str);
+		__entry->str_t = str_t;
 		__entry->cmd = cmd;
 		__entry->arg1 = arg1;
 		__entry->arg2 = arg2;
@@ -289,33 +304,34 @@ TRACE_EVENT(ufshcd_uic_command,
 
 	TP_printk(
 		"%s: %s: cmd: 0x%x, arg1: 0x%x, arg2: 0x%x, arg3: 0x%x",
-		__get_str(str), __get_str(dev_name), __entry->cmd,
-		__entry->arg1, __entry->arg2, __entry->arg3
+		show_ufs_cmd_trace_str(__entry->str_t), __get_str(dev_name),
+		__entry->cmd, __entry->arg1, __entry->arg2, __entry->arg3
 	)
 );
 
 TRACE_EVENT(ufshcd_upiu,
-	TP_PROTO(const char *dev_name, const char *str, void *hdr, void *tsf),
+	TP_PROTO(const char *dev_name, enum ufs_trace_str_t str_t, void *hdr,
+		 void *tsf),
 
-	TP_ARGS(dev_name, str, hdr, tsf),
+	TP_ARGS(dev_name, str_t, hdr, tsf),
 
 	TP_STRUCT__entry(
 		__string(dev_name, dev_name)
-		__string(str, str)
+		__field(enum ufs_trace_str_t, str_t)
 		__array(unsigned char, hdr, 12)
 		__array(unsigned char, tsf, 16)
 	),
 
 	TP_fast_assign(
 		__assign_str(dev_name, dev_name);
-		__assign_str(str, str);
+		__entry->str_t = str_t;
 		memcpy(__entry->hdr, hdr, sizeof(__entry->hdr));
 		memcpy(__entry->tsf, tsf, sizeof(__entry->tsf));
 	),
 
 	TP_printk(
 		"%s: %s: HDR:%s, CDB:%s",
-		__get_str(str), __get_str(dev_name),
+		show_ufs_cmd_trace_str(__entry->str_t), __get_str(dev_name),
 		__print_hex(__entry->hdr, sizeof(__entry->hdr)),
 		__print_hex(__entry->tsf, sizeof(__entry->tsf))
 	)
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v3 3/6] scsi: ufs: Don't call trace_ufshcd_upiu() in case trace poit is disabled
  2020-12-14 20:20 [PATCH v3 0/6] Several changes for the UPIU trace Bean Huo
  2020-12-14 20:20 ` [PATCH v3 1/6] scsi: ufs: Remove stringize operator '#' restriction Bean Huo
  2020-12-14 20:20 ` [PATCH v3 2/6] scsi: ufs: Use __print_symbolic() for UFS trace string print Bean Huo
@ 2020-12-14 20:20 ` Bean Huo
  2020-12-14 20:20 ` [PATCH v3 4/6] scsi: ufs: Distinguish between query REQ and query RSP in query trace Bean Huo
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 15+ messages in thread
From: Bean Huo @ 2020-12-14 20:20 UTC (permalink / raw)
  To: alim.akhtar, avri.altman, asutoshd, jejb, martin.petersen,
	stanley.chu, beanhuo, bvanassche, tomas.winkler, cang, rostedt,
	joe
  Cc: linux-scsi, linux-kernel

From: Bean Huo <beanhuo@micron.com>

Don't call trace_ufshcd_upiu() in case ufshba_upiu trace poit is not enabled.

Acked-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Signed-off-by: Bean Huo <beanhuo@micron.com>
---
 drivers/scsi/ufs/ufshcd.c | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index 66babbd8bf32..f4a071d12542 100644
--- a/drivers/scsi/ufs/ufshcd.c
+++ b/drivers/scsi/ufs/ufshcd.c
@@ -309,6 +309,9 @@ static void ufshcd_add_cmd_upiu_trace(struct ufs_hba *hba, unsigned int tag,
 {
 	struct utp_upiu_req *rq = hba->lrb[tag].ucd_req_ptr;
 
+	if (!trace_ufshcd_upiu_enabled())
+		return;
+
 	trace_ufshcd_upiu(dev_name(hba->dev), str_t, &rq->header, &rq->sc.cdb);
 }
 
@@ -317,6 +320,9 @@ static void ufshcd_add_query_upiu_trace(struct ufs_hba *hba, unsigned int tag,
 {
 	struct utp_upiu_req *rq = hba->lrb[tag].ucd_req_ptr;
 
+	if (!trace_ufshcd_upiu_enabled())
+		return;
+
 	trace_ufshcd_upiu(dev_name(hba->dev), str_t, &rq->header, &rq->qr);
 }
 
@@ -326,6 +332,9 @@ static void ufshcd_add_tm_upiu_trace(struct ufs_hba *hba, unsigned int tag,
 	int off = (int)tag - hba->nutrs;
 	struct utp_task_req_desc *descp = &hba->utmrdl_base_addr[off];
 
+	if (!trace_ufshcd_upiu_enabled())
+		return;
+
 	trace_ufshcd_upiu(dev_name(hba->dev), str_t, &descp->req_header,
 			&descp->input_param1);
 }
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v3 4/6] scsi: ufs: Distinguish between query REQ and query RSP in query trace
  2020-12-14 20:20 [PATCH v3 0/6] Several changes for the UPIU trace Bean Huo
                   ` (2 preceding siblings ...)
  2020-12-14 20:20 ` [PATCH v3 3/6] scsi: ufs: Don't call trace_ufshcd_upiu() in case trace poit is disabled Bean Huo
@ 2020-12-14 20:20 ` Bean Huo
  2020-12-14 20:20 ` [PATCH v3 5/6] scsi: ufs: Distinguish between TM request UPIU and response UPIU in TM UPIU trace Bean Huo
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 15+ messages in thread
From: Bean Huo @ 2020-12-14 20:20 UTC (permalink / raw)
  To: alim.akhtar, avri.altman, asutoshd, jejb, martin.petersen,
	stanley.chu, beanhuo, bvanassche, tomas.winkler, cang, rostedt,
	joe
  Cc: linux-scsi, linux-kernel

From: Bean Huo <beanhuo@micron.com>

Currently, in the query completion trace print,  since we use
hba->lrb[tag].ucd_req_ptr and didn't differentiate UPIU between
request and response, thus header and transaction-specific field
in UPIU printed by query trace are identical. This is not very
practical. As below:

query_send: HDR:16 00 00 0e 00 81 00 00 00 00 00 00, CDB:06 0e 03 00 00 00 00 00 00 00 00 00 00 00 00 00
query_complete: HDR:16 00 00 0e 00 81 00 00 00 00 00 00, CDB:06 0e 03 00 00 00 00 00 00 00 00 00 00 00 00 00

For the failure analysis, we want to understand the real response
reported by the UFS device, however, the current query trace tells
us nothing. After this patch, the query trace on the query_send, and
the above a pair of query_send and query_complete will be:

query_send: HDR:16 00 00 0e 00 81 00 00 00 00 00 00, CDB:06 0e 03 00 00 00 00 00 00 00 00 00 00 00 00 00
ufshcd_upiu: HDR:36 00 00 0e 00 81 00 00 00 00 00 00, CDB:06 0e 03 00 00 00 00 00 00 00 00 01 00 00 00 00

Acked-by: Avri Altman <avri.altman@wdc.com>
Acked-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Signed-off-by: Bean Huo <beanhuo@micron.com>
---
 drivers/scsi/ufs/ufshcd.c | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index f4a071d12542..d0b054aa0a3c 100644
--- a/drivers/scsi/ufs/ufshcd.c
+++ b/drivers/scsi/ufs/ufshcd.c
@@ -318,12 +318,18 @@ static void ufshcd_add_cmd_upiu_trace(struct ufs_hba *hba, unsigned int tag,
 static void ufshcd_add_query_upiu_trace(struct ufs_hba *hba, unsigned int tag,
 					enum ufs_trace_str_t str_t)
 {
-	struct utp_upiu_req *rq = hba->lrb[tag].ucd_req_ptr;
+	struct utp_upiu_req *rq_rsp;
 
 	if (!trace_ufshcd_upiu_enabled())
 		return;
 
-	trace_ufshcd_upiu(dev_name(hba->dev), str_t, &rq->header, &rq->qr);
+	if (str_t == UFS_QUERY_SEND)
+		rq_rsp = hba->lrb[tag].ucd_req_ptr;
+	else
+		rq_rsp = (struct utp_upiu_req *)hba->lrb[tag].ucd_rsp_ptr;
+
+	trace_ufshcd_upiu(dev_name(hba->dev), str_t, &rq_rsp->header,
+			  &rq_rsp->qr);
 }
 
 static void ufshcd_add_tm_upiu_trace(struct ufs_hba *hba, unsigned int tag,
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v3 5/6] scsi: ufs: Distinguish between TM request UPIU and response UPIU in TM UPIU trace
  2020-12-14 20:20 [PATCH v3 0/6] Several changes for the UPIU trace Bean Huo
                   ` (3 preceding siblings ...)
  2020-12-14 20:20 ` [PATCH v3 4/6] scsi: ufs: Distinguish between query REQ and query RSP in query trace Bean Huo
@ 2020-12-14 20:20 ` Bean Huo
  2020-12-14 20:20 ` [PATCH v3 6/6] scsi: ufs: Make UPIU trace easier differentiate among CDB, OSF, and TM Bean Huo
  2020-12-14 22:13 ` [PATCH v3 0/6] Several changes for the UPIU trace Avri Altman
  6 siblings, 0 replies; 15+ messages in thread
From: Bean Huo @ 2020-12-14 20:20 UTC (permalink / raw)
  To: alim.akhtar, avri.altman, asutoshd, jejb, martin.petersen,
	stanley.chu, beanhuo, bvanassche, tomas.winkler, cang, rostedt,
	joe
  Cc: linux-scsi, linux-kernel

From: Bean Huo <beanhuo@micron.com>

Distinguish between TM request UPIU and response UPIU in TM UPIU trace,
for the TM response, let TM UPIU trace print its TM response UPIU.

Acked-by: Avri Altman <avri.altman@wdc.com>
Acked-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Signed-off-by: Bean Huo <beanhuo@micron.com>
---
 drivers/scsi/ufs/ufshcd.c | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index d0b054aa0a3c..2cf983b3de1a 100644
--- a/drivers/scsi/ufs/ufshcd.c
+++ b/drivers/scsi/ufs/ufshcd.c
@@ -341,8 +341,12 @@ static void ufshcd_add_tm_upiu_trace(struct ufs_hba *hba, unsigned int tag,
 	if (!trace_ufshcd_upiu_enabled())
 		return;
 
-	trace_ufshcd_upiu(dev_name(hba->dev), str_t, &descp->req_header,
-			&descp->input_param1);
+	if (str_t == UFS_TM_SEND)
+		trace_ufshcd_upiu(dev_name(hba->dev), str_t, &descp->req_header,
+				  &descp->input_param1);
+	else
+		trace_ufshcd_upiu(dev_name(hba->dev), str_t, &descp->rsp_header,
+				  &descp->output_param1);
 }
 
 static void ufshcd_add_uic_command_trace(struct ufs_hba *hba,
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v3 6/6] scsi: ufs: Make UPIU trace easier differentiate among CDB, OSF, and TM
  2020-12-14 20:20 [PATCH v3 0/6] Several changes for the UPIU trace Bean Huo
                   ` (4 preceding siblings ...)
  2020-12-14 20:20 ` [PATCH v3 5/6] scsi: ufs: Distinguish between TM request UPIU and response UPIU in TM UPIU trace Bean Huo
@ 2020-12-14 20:20 ` Bean Huo
  2020-12-14 22:13 ` [PATCH v3 0/6] Several changes for the UPIU trace Avri Altman
  6 siblings, 0 replies; 15+ messages in thread
From: Bean Huo @ 2020-12-14 20:20 UTC (permalink / raw)
  To: alim.akhtar, avri.altman, asutoshd, jejb, martin.petersen,
	stanley.chu, beanhuo, bvanassche, tomas.winkler, cang, rostedt,
	joe
  Cc: linux-scsi, linux-kernel

From: Bean Huo <beanhuo@micron.com>

Transaction Specific Fields (TSF) in the UPIU package could be CDB
(SCSI/UFS Command Descriptor Block), OSF (Opcode Specific Field), and
TM I/O parameter (Task Management Input/Output Parameter). But, currently,
we take all of these as CDB  in the UPIU trace. Thus makes user confuse
among CDB, OSF, and TM message. So fix it with this patch.

Acked-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Signed-off-by: Bean Huo <beanhuo@micron.com>
---
 drivers/scsi/ufs/ufs.h     |  7 +++++++
 drivers/scsi/ufs/ufshcd.c  |  9 +++++----
 include/trace/events/ufs.h | 18 +++++++++++++++---
 3 files changed, 27 insertions(+), 7 deletions(-)

diff --git a/drivers/scsi/ufs/ufs.h b/drivers/scsi/ufs/ufs.h
index ba24b504f85a..50f46f3bc8a2 100644
--- a/drivers/scsi/ufs/ufs.h
+++ b/drivers/scsi/ufs/ufs.h
@@ -554,6 +554,13 @@ enum ufs_trace_str_t {
 	UFS_TM_SEND, UFS_TM_COMP, UFS_TM_ERR
 };
 
+/*
+ * Transaction Specific Fields (TSF) type in the UPIU package, this enum is
+ * used in include/trace/events/ufs.h for UFS command trace.
+ */
+enum ufs_trace_tsf_t {
+	UFS_TSF_CDB, UFS_TSF_OSF, UFS_TSF_TM_INPUT, UFS_TSF_TM_OUTPUT
+};
 
 /**
  * ufs_is_valid_unit_desc_lun - checks if the given LUN has a unit descriptor
diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index 2cf983b3de1a..58ba7402d0c3 100644
--- a/drivers/scsi/ufs/ufshcd.c
+++ b/drivers/scsi/ufs/ufshcd.c
@@ -312,7 +312,8 @@ static void ufshcd_add_cmd_upiu_trace(struct ufs_hba *hba, unsigned int tag,
 	if (!trace_ufshcd_upiu_enabled())
 		return;
 
-	trace_ufshcd_upiu(dev_name(hba->dev), str_t, &rq->header, &rq->sc.cdb);
+	trace_ufshcd_upiu(dev_name(hba->dev), str_t, &rq->header, &rq->sc.cdb,
+			  UFS_TSF_CDB);
 }
 
 static void ufshcd_add_query_upiu_trace(struct ufs_hba *hba, unsigned int tag,
@@ -329,7 +330,7 @@ static void ufshcd_add_query_upiu_trace(struct ufs_hba *hba, unsigned int tag,
 		rq_rsp = (struct utp_upiu_req *)hba->lrb[tag].ucd_rsp_ptr;
 
 	trace_ufshcd_upiu(dev_name(hba->dev), str_t, &rq_rsp->header,
-			  &rq_rsp->qr);
+			  &rq_rsp->qr, UFS_TSF_OSF);
 }
 
 static void ufshcd_add_tm_upiu_trace(struct ufs_hba *hba, unsigned int tag,
@@ -343,10 +344,10 @@ static void ufshcd_add_tm_upiu_trace(struct ufs_hba *hba, unsigned int tag,
 
 	if (str_t == UFS_TM_SEND)
 		trace_ufshcd_upiu(dev_name(hba->dev), str_t, &descp->req_header,
-				  &descp->input_param1);
+				  &descp->input_param1, UFS_TSF_TM_INPUT);
 	else
 		trace_ufshcd_upiu(dev_name(hba->dev), str_t, &descp->rsp_header,
-				  &descp->output_param1);
+				  &descp->output_param1, UFS_TSF_TM_OUTPUT);
 }
 
 static void ufshcd_add_uic_command_trace(struct ufs_hba *hba,
diff --git a/include/trace/events/ufs.h b/include/trace/events/ufs.h
index 335a8d6b490f..0e25a569d95a 100644
--- a/include/trace/events/ufs.h
+++ b/include/trace/events/ufs.h
@@ -48,6 +48,12 @@
 	EM(UFS_TM_COMP,		"tm_complete")			\
 	EMe(UFS_TM_ERR,		"tm_complete_err")
 
+#define UFS_CMD_TRACE_TSF_TYPES					\
+	EM(UFS_TSF_CDB,		"CDB")		                \
+	EM(UFS_TSF_OSF,		"OSF")		                \
+	EM(UFS_TSF_TM_INPUT,	"TM_INPUT")                     \
+	EMe(UFS_TSF_TM_OUTPUT,	"TM_OUTPUT")
+
 /* Enums require being exported to userspace, for user tool parsing */
 #undef EM
 #undef EMe
@@ -58,6 +64,7 @@ UFS_LINK_STATES;
 UFS_PWR_MODES;
 UFSCHD_CLK_GATING_STATES;
 UFS_CMD_TRACE_STRINGS
+UFS_CMD_TRACE_TSF_TYPES
 
 /*
  * Now redefine the EM() and EMe() macros to map the enums to the strings
@@ -70,6 +77,8 @@ UFS_CMD_TRACE_STRINGS
 
 #define show_ufs_cmd_trace_str(str_t)	\
 				__print_symbolic(str_t, UFS_CMD_TRACE_STRINGS)
+#define show_ufs_cmd_trace_tsf(tsf)	\
+				__print_symbolic(tsf, UFS_CMD_TRACE_TSF_TYPES)
 
 TRACE_EVENT(ufshcd_clk_gating,
 
@@ -311,15 +320,16 @@ TRACE_EVENT(ufshcd_uic_command,
 
 TRACE_EVENT(ufshcd_upiu,
 	TP_PROTO(const char *dev_name, enum ufs_trace_str_t str_t, void *hdr,
-		 void *tsf),
+		 void *tsf, enum ufs_trace_tsf_t tsf_t),
 
-	TP_ARGS(dev_name, str_t, hdr, tsf),
+	TP_ARGS(dev_name, str_t, hdr, tsf, tsf_t),
 
 	TP_STRUCT__entry(
 		__string(dev_name, dev_name)
 		__field(enum ufs_trace_str_t, str_t)
 		__array(unsigned char, hdr, 12)
 		__array(unsigned char, tsf, 16)
+		__field(enum ufs_trace_tsf_t, tsf_t)
 	),
 
 	TP_fast_assign(
@@ -327,12 +337,14 @@ TRACE_EVENT(ufshcd_upiu,
 		__entry->str_t = str_t;
 		memcpy(__entry->hdr, hdr, sizeof(__entry->hdr));
 		memcpy(__entry->tsf, tsf, sizeof(__entry->tsf));
+		__entry->tsf_t = tsf_t;
 	),
 
 	TP_printk(
-		"%s: %s: HDR:%s, CDB:%s",
+		"%s: %s: HDR:%s, %s:%s",
 		show_ufs_cmd_trace_str(__entry->str_t), __get_str(dev_name),
 		__print_hex(__entry->hdr, sizeof(__entry->hdr)),
+		show_ufs_cmd_trace_tsf(__entry->tsf_t),
 		__print_hex(__entry->tsf, sizeof(__entry->tsf))
 	)
 );
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 15+ messages in thread

* Re: [PATCH v3 1/6] scsi: ufs: Remove stringize operator '#' restriction
  2020-12-14 20:20 ` [PATCH v3 1/6] scsi: ufs: Remove stringize operator '#' restriction Bean Huo
@ 2020-12-14 21:23   ` Joe Perches
  2020-12-14 22:26     ` Bean Huo
  2020-12-14 23:11   ` David Laight
  1 sibling, 1 reply; 15+ messages in thread
From: Joe Perches @ 2020-12-14 21:23 UTC (permalink / raw)
  To: Bean Huo, alim.akhtar, avri.altman, asutoshd, jejb,
	martin.petersen, stanley.chu, beanhuo, bvanassche, tomas.winkler,
	cang, rostedt
  Cc: linux-scsi, linux-kernel

On Mon, 2020-12-14 at 21:20 +0100, Bean Huo wrote:
> From: Bean Huo <beanhuo@micron.com>
> 
> Current EM macro definition, we use stringize operator '#', which turns
> the argument it precedes into a quoted string. Thus requires the symbol
> of __print_symbolic() should be the string corresponding to the name of
> the enum.
> 
> However, we have other cases, the symbol and enum name are not the same,
> we can redefine EM/EMe, but there will introduce some redundant codes.
> This patch is to remove this restriction, let others reuse the current
> EM/EMe definition.

While this version doesn't have the copy/paste typo,
I fail to see value in defining EMe as a trailing comma
in an array declaration isn't meaningful and doesn't emit
any error or warning.

Maybe all the uses of EMe can be converted to EM and the
macro definitions removed.
---
 include/ras/ras_event.h            |  64 ++++++++---------
 include/trace/events/9p.h          | 142 ++++++++++++++++++-------------------
 include/trace/events/btrfs.h       |  66 ++++++++---------
 include/trace/events/huge_memory.h |  58 +++++++--------
 include/trace/events/migrate.h     |  26 +++----
 include/trace/events/mmflags.h     |  34 ++++-----
 include/trace/events/sock.h        |  56 +++++++--------
 include/trace/events/sunrpc.h      |  44 ++++++------
 include/trace/events/tlb.h         |  16 ++---
 include/trace/events/ufs.h         |  12 ++--
 include/trace/events/v4l2.h        |  54 +++++++-------
 include/trace/events/writeback.h   |  24 +++----
 12 files changed, 274 insertions(+), 322 deletions(-)

diff --git a/include/ras/ras_event.h b/include/ras/ras_event.h
index 0bdbc0d17d2f..32521a1066c7 100644
--- a/include/ras/ras_event.h
+++ b/include/ras/ras_event.h
@@ -348,56 +348,52 @@ TRACE_EVENT(aer_event,
 
 #ifdef CONFIG_MEMORY_FAILURE
 #define MF_ACTION_RESULT	\
-	EM ( MF_IGNORED, "Ignored" )	\
-	EM ( MF_FAILED,  "Failed" )	\
-	EM ( MF_DELAYED, "Delayed" )	\
-	EMe ( MF_RECOVERED, "Recovered" )
-
-#define MF_PAGE_TYPE		\
-	EM ( MF_MSG_KERNEL, "reserved kernel page" )			\
-	EM ( MF_MSG_KERNEL_HIGH_ORDER, "high-order kernel page" )	\
-	EM ( MF_MSG_SLAB, "kernel slab page" )				\
-	EM ( MF_MSG_DIFFERENT_COMPOUND, "different compound page after locking" ) \
-	EM ( MF_MSG_POISONED_HUGE, "huge page already hardware poisoned" )	\
-	EM ( MF_MSG_HUGE, "huge page" )					\
-	EM ( MF_MSG_FREE_HUGE, "free huge page" )			\
-	EM ( MF_MSG_NON_PMD_HUGE, "non-pmd-sized huge page" )		\
-	EM ( MF_MSG_UNMAP_FAILED, "unmapping failed page" )		\
-	EM ( MF_MSG_DIRTY_SWAPCACHE, "dirty swapcache page" )		\
-	EM ( MF_MSG_CLEAN_SWAPCACHE, "clean swapcache page" )		\
-	EM ( MF_MSG_DIRTY_MLOCKED_LRU, "dirty mlocked LRU page" )	\
-	EM ( MF_MSG_CLEAN_MLOCKED_LRU, "clean mlocked LRU page" )	\
-	EM ( MF_MSG_DIRTY_UNEVICTABLE_LRU, "dirty unevictable LRU page" )	\
-	EM ( MF_MSG_CLEAN_UNEVICTABLE_LRU, "clean unevictable LRU page" )	\
-	EM ( MF_MSG_DIRTY_LRU, "dirty LRU page" )			\
-	EM ( MF_MSG_CLEAN_LRU, "clean LRU page" )			\
-	EM ( MF_MSG_TRUNCATED_LRU, "already truncated LRU page" )	\
-	EM ( MF_MSG_BUDDY, "free buddy page" )				\
-	EM ( MF_MSG_BUDDY_2ND, "free buddy page (2nd try)" )		\
-	EM ( MF_MSG_DAX, "dax page" )					\
-	EM ( MF_MSG_UNSPLIT_THP, "unsplit thp" )			\
-	EMe ( MF_MSG_UNKNOWN, "unknown page" )
+	EM(MF_IGNORED, "Ignored")	\
+	EM(MF_FAILED,  "Failed")	\
+	EM(MF_DELAYED, "Delayed")	\
+	EM(MF_RECOVERED, "Recovered")
+
+#define MF_PAGE_TYPE							\
+	EM(MF_MSG_KERNEL, "reserved kernel page")			\
+	EM(MF_MSG_KERNEL_HIGH_ORDER, "high-order kernel page")		\
+	EM(MF_MSG_SLAB, "kernel slab page")				\
+	EM(MF_MSG_DIFFERENT_COMPOUND, "different compound page after locking") \
+	EM(MF_MSG_POISONED_HUGE, "huge page already hardware poisoned")	\
+	EM(MF_MSG_HUGE, "huge page")					\
+	EM(MF_MSG_FREE_HUGE, "free huge page")				\
+	EM(MF_MSG_NON_PMD_HUGE, "non-pmd-sized huge page")		\
+	EM(MF_MSG_UNMAP_FAILED, "unmapping failed page")		\
+	EM(MF_MSG_DIRTY_SWAPCACHE, "dirty swapcache page")		\
+	EM(MF_MSG_CLEAN_SWAPCACHE, "clean swapcache page")		\
+	EM(MF_MSG_DIRTY_MLOCKED_LRU, "dirty mlocked LRU page")		\
+	EM(MF_MSG_CLEAN_MLOCKED_LRU, "clean mlocked LRU page")		\
+	EM(MF_MSG_DIRTY_UNEVICTABLE_LRU, "dirty unevictable LRU page")	\
+	EM(MF_MSG_CLEAN_UNEVICTABLE_LRU, "clean unevictable LRU page")	\
+	EM(MF_MSG_DIRTY_LRU, "dirty LRU page")				\
+	EM(MF_MSG_CLEAN_LRU, "clean LRU page")				\
+	EM(MF_MSG_TRUNCATED_LRU, "already truncated LRU page")		\
+	EM(MF_MSG_BUDDY, "free buddy page")				\
+	EM(MF_MSG_BUDDY_2ND, "free buddy page (2nd try)")		\
+	EM(MF_MSG_DAX, "dax page")					\
+	EM(MF_MSG_UNSPLIT_THP, "unsplit thp")				\
+	EM(MF_MSG_UNKNOWN, "unknown page")
 
 /*
  * First define the enums in MM_ACTION_RESULT to be exported to userspace
  * via TRACE_DEFINE_ENUM().
  */
 #undef EM
-#undef EMe
 #define EM(a, b) TRACE_DEFINE_ENUM(a);
-#define EMe(a, b)	TRACE_DEFINE_ENUM(a);
 
 MF_ACTION_RESULT
 MF_PAGE_TYPE
 
 /*
- * Now redefine the EM() and EMe() macros to map the enums to the strings
+ * Now redefine the EM() macro to map the enums to the strings
  * that will be printed in the output.
  */
 #undef EM
-#undef EMe
 #define EM(a, b)		{ a, b },
-#define EMe(a, b)	{ a, b }
 
 TRACE_EVENT(memory_failure_event,
 	TP_PROTO(unsigned long pfn,
diff --git a/include/trace/events/9p.h b/include/trace/events/9p.h
index 78c5608a1648..a7a965d95ad9 100644
--- a/include/trace/events/9p.h
+++ b/include/trace/events/9p.h
@@ -8,91 +8,87 @@
 #include <linux/tracepoint.h>
 
 #define P9_MSG_T							\
-		EM( P9_TLERROR,		"P9_TLERROR" )			\
-		EM( P9_RLERROR,		"P9_RLERROR" )			\
-		EM( P9_TSTATFS,		"P9_TSTATFS" )			\
-		EM( P9_RSTATFS,		"P9_RSTATFS" )			\
-		EM( P9_TLOPEN,		"P9_TLOPEN" )			\
-		EM( P9_RLOPEN,		"P9_RLOPEN" )			\
-		EM( P9_TLCREATE,	"P9_TLCREATE" )			\
-		EM( P9_RLCREATE,	"P9_RLCREATE" )			\
-		EM( P9_TSYMLINK,	"P9_TSYMLINK" )			\
-		EM( P9_RSYMLINK,	"P9_RSYMLINK" )			\
-		EM( P9_TMKNOD,		"P9_TMKNOD" )			\
-		EM( P9_RMKNOD,		"P9_RMKNOD" )			\
-		EM( P9_TRENAME,		"P9_TRENAME" )			\
-		EM( P9_RRENAME,		"P9_RRENAME" )			\
-		EM( P9_TREADLINK,	"P9_TREADLINK" )		\
-		EM( P9_RREADLINK,	"P9_RREADLINK" )		\
-		EM( P9_TGETATTR,	"P9_TGETATTR" )			\
-		EM( P9_RGETATTR,	"P9_RGETATTR" )			\
-		EM( P9_TSETATTR,	"P9_TSETATTR" )			\
-		EM( P9_RSETATTR,	"P9_RSETATTR" )			\
-		EM( P9_TXATTRWALK,	"P9_TXATTRWALK" )		\
-		EM( P9_RXATTRWALK,	"P9_RXATTRWALK" )		\
-		EM( P9_TXATTRCREATE,	"P9_TXATTRCREATE" )		\
-		EM( P9_RXATTRCREATE,	"P9_RXATTRCREATE" )		\
-		EM( P9_TREADDIR,	"P9_TREADDIR" )			\
-		EM( P9_RREADDIR,	"P9_RREADDIR" )			\
-		EM( P9_TFSYNC,		"P9_TFSYNC" )			\
-		EM( P9_RFSYNC,		"P9_RFSYNC" )			\
-		EM( P9_TLOCK,		"P9_TLOCK" )			\
-		EM( P9_RLOCK,		"P9_RLOCK" )			\
-		EM( P9_TGETLOCK,	"P9_TGETLOCK" )			\
-		EM( P9_RGETLOCK,	"P9_RGETLOCK" )			\
-		EM( P9_TLINK,		"P9_TLINK" )			\
-		EM( P9_RLINK,		"P9_RLINK" )			\
-		EM( P9_TMKDIR,		"P9_TMKDIR" )			\
-		EM( P9_RMKDIR,		"P9_RMKDIR" )			\
-		EM( P9_TRENAMEAT,	"P9_TRENAMEAT" )		\
-		EM( P9_RRENAMEAT,	"P9_RRENAMEAT" )		\
-		EM( P9_TUNLINKAT,	"P9_TUNLINKAT" )		\
-		EM( P9_RUNLINKAT,	"P9_RUNLINKAT" )		\
-		EM( P9_TVERSION,	"P9_TVERSION" )			\
-		EM( P9_RVERSION,	"P9_RVERSION" )			\
-		EM( P9_TAUTH,		"P9_TAUTH" )			\
-		EM( P9_RAUTH,		"P9_RAUTH" )			\
-		EM( P9_TATTACH,		"P9_TATTACH" )			\
-		EM( P9_RATTACH,		"P9_RATTACH" )			\
-		EM( P9_TERROR,		"P9_TERROR" )			\
-		EM( P9_RERROR,		"P9_RERROR" )			\
-		EM( P9_TFLUSH,		"P9_TFLUSH" )			\
-		EM( P9_RFLUSH,		"P9_RFLUSH" )			\
-		EM( P9_TWALK,		"P9_TWALK" )			\
-		EM( P9_RWALK,		"P9_RWALK" )			\
-		EM( P9_TOPEN,		"P9_TOPEN" )			\
-		EM( P9_ROPEN,		"P9_ROPEN" )			\
-		EM( P9_TCREATE,		"P9_TCREATE" )			\
-		EM( P9_RCREATE,		"P9_RCREATE" )			\
-		EM( P9_TREAD,		"P9_TREAD" )			\
-		EM( P9_RREAD,		"P9_RREAD" )			\
-		EM( P9_TWRITE,		"P9_TWRITE" )			\
-		EM( P9_RWRITE,		"P9_RWRITE" )			\
-		EM( P9_TCLUNK,		"P9_TCLUNK" )			\
-		EM( P9_RCLUNK,		"P9_RCLUNK" )			\
-		EM( P9_TREMOVE,		"P9_TREMOVE" )			\
-		EM( P9_RREMOVE,		"P9_RREMOVE" )			\
-		EM( P9_TSTAT,		"P9_TSTAT" )			\
-		EM( P9_RSTAT,		"P9_RSTAT" )			\
-		EM( P9_TWSTAT,		"P9_TWSTAT" )			\
-		EMe(P9_RWSTAT,		"P9_RWSTAT" )
+		EM(P9_TLERROR,		"P9_TLERROR")			\
+		EM(P9_RLERROR,		"P9_RLERROR")			\
+		EM(P9_TSTATFS,		"P9_TSTATFS")			\
+		EM(P9_RSTATFS,		"P9_RSTATFS")			\
+		EM(P9_TLOPEN,		"P9_TLOPEN")			\
+		EM(P9_RLOPEN,		"P9_RLOPEN")			\
+		EM(P9_TLCREATE,		"P9_TLCREATE")			\
+		EM(P9_RLCREATE,		"P9_RLCREATE")			\
+		EM(P9_TSYMLINK,		"P9_TSYMLINK")			\
+		EM(P9_RSYMLINK,		"P9_RSYMLINK")			\
+		EM(P9_TMKNOD,		"P9_TMKNOD")			\
+		EM(P9_RMKNOD,		"P9_RMKNOD")			\
+		EM(P9_TRENAME,		"P9_TRENAME")			\
+		EM(P9_RRENAME,		"P9_RRENAME")			\
+		EM(P9_TREADLINK,	"P9_TREADLINK")			\
+		EM(P9_RREADLINK,	"P9_RREADLINK")			\
+		EM(P9_TGETATTR,		"P9_TGETATTR")			\
+		EM(P9_RGETATTR,		"P9_RGETATTR")			\
+		EM(P9_TSETATTR,		"P9_TSETATTR")			\
+		EM(P9_RSETATTR,		"P9_RSETATTR")			\
+		EM(P9_TXATTRWALK,	"P9_TXATTRWALK")		\
+		EM(P9_RXATTRWALK,	"P9_RXATTRWALK")		\
+		EM(P9_TXATTRCREATE,	"P9_TXATTRCREATE")		\
+		EM(P9_RXATTRCREATE,	"P9_RXATTRCREATE")		\
+		EM(P9_TREADDIR,		"P9_TREADDIR")			\
+		EM(P9_RREADDIR,		"P9_RREADDIR")			\
+		EM(P9_TFSYNC,		"P9_TFSYNC")			\
+		EM(P9_RFSYNC,		"P9_RFSYNC")			\
+		EM(P9_TLOCK,		"P9_TLOCK")			\
+		EM(P9_RLOCK,		"P9_RLOCK")			\
+		EM(P9_TGETLOCK,		"P9_TGETLOCK")			\
+		EM(P9_RGETLOCK,		"P9_RGETLOCK")			\
+		EM(P9_TLINK,		"P9_TLINK")			\
+		EM(P9_RLINK,		"P9_RLINK")			\
+		EM(P9_TMKDIR,		"P9_TMKDIR")			\
+		EM(P9_RMKDIR,		"P9_RMKDIR")			\
+		EM(P9_TRENAMEAT,	"P9_TRENAMEAT")			\
+		EM(P9_RRENAMEAT,	"P9_RRENAMEAT")			\
+		EM(P9_TUNLINKAT,	"P9_TUNLINKAT")			\
+		EM(P9_RUNLINKAT,	"P9_RUNLINKAT")			\
+		EM(P9_TVERSION,		"P9_TVERSION")			\
+		EM(P9_RVERSION,		"P9_RVERSION")			\
+		EM(P9_TAUTH,		"P9_TAUTH")			\
+		EM(P9_RAUTH,		"P9_RAUTH")			\
+		EM(P9_TATTACH,		"P9_TATTACH")			\
+		EM(P9_RATTACH,		"P9_RATTACH")			\
+		EM(P9_TERROR,		"P9_TERROR")			\
+		EM(P9_RERROR,		"P9_RERROR")			\
+		EM(P9_TFLUSH,		"P9_TFLUSH")			\
+		EM(P9_RFLUSH,		"P9_RFLUSH")			\
+		EM(P9_TWALK,		"P9_TWALK")			\
+		EM(P9_RWALK,		"P9_RWALK")			\
+		EM(P9_TOPEN,		"P9_TOPEN")			\
+		EM(P9_ROPEN,		"P9_ROPEN")			\
+		EM(P9_TCREATE,		"P9_TCREATE")			\
+		EM(P9_RCREATE,		"P9_RCREATE")			\
+		EM(P9_TREAD,		"P9_TREAD")			\
+		EM(P9_RREAD,		"P9_RREAD")			\
+		EM(P9_TWRITE,		"P9_TWRITE")			\
+		EM(P9_RWRITE,		"P9_RWRITE")			\
+		EM(P9_TCLUNK,		"P9_TCLUNK")			\
+		EM(P9_RCLUNK,		"P9_RCLUNK")			\
+		EM(P9_TREMOVE,		"P9_TREMOVE")			\
+		EM(P9_RREMOVE,		"P9_RREMOVE")			\
+		EM(P9_TSTAT,		"P9_TSTAT")			\
+		EM(P9_RSTAT,		"P9_RSTAT")			\
+		EM(P9_TWSTAT,		"P9_TWSTAT")			\
+		EM(P9_RWSTAT,		"P9_RWSTAT")
 
 /* Define EM() to export the enums to userspace via TRACE_DEFINE_ENUM() */
 #undef EM
-#undef EMe
 #define EM(a, b)	TRACE_DEFINE_ENUM(a);
-#define EMe(a, b)	TRACE_DEFINE_ENUM(a);
 
 P9_MSG_T
 
 /*
- * Now redefine the EM() and EMe() macros to map the enums to the strings
+ * Now redefine the EM() macro to map the enums to the strings
  * that will be printed in the output.
  */
 #undef EM
-#undef EMe
 #define EM(a, b)	{ a, b },
-#define EMe(a, b)	{ a, b }
 
 #define show_9p_op(type)						\
 	__print_symbolic(type, P9_MSG_T)
diff --git a/include/trace/events/btrfs.h b/include/trace/events/btrfs.h
index 74b466dc20ac..7fcdd8a3f22e 100644
--- a/include/trace/events/btrfs.h
+++ b/include/trace/events/btrfs.h
@@ -61,46 +61,46 @@ struct btrfs_space_info;
 	       obj <= BTRFS_QUOTA_TREE_OBJECTID)) ? __show_root_type(obj) : "-"
 
 #define FLUSH_ACTIONS								\
-	EM( BTRFS_RESERVE_NO_FLUSH,		"BTRFS_RESERVE_NO_FLUSH")	\
-	EM( BTRFS_RESERVE_FLUSH_LIMIT,		"BTRFS_RESERVE_FLUSH_LIMIT")	\
-	EM( BTRFS_RESERVE_FLUSH_ALL,		"BTRFS_RESERVE_FLUSH_ALL")	\
-	EMe(BTRFS_RESERVE_FLUSH_ALL_STEAL,	"BTRFS_RESERVE_FLUSH_ALL_STEAL")
+	EM(BTRFS_RESERVE_NO_FLUSH,		"BTRFS_RESERVE_NO_FLUSH")	\
+	EM(BTRFS_RESERVE_FLUSH_LIMIT,		"BTRFS_RESERVE_FLUSH_LIMIT")	\
+	EM(BTRFS_RESERVE_FLUSH_ALL,		"BTRFS_RESERVE_FLUSH_ALL")	\
+	EM(BTRFS_RESERVE_FLUSH_ALL_STEAL,	"BTRFS_RESERVE_FLUSH_ALL_STEAL")
 
 #define FI_TYPES							\
-	EM( BTRFS_FILE_EXTENT_INLINE,		"INLINE")		\
-	EM( BTRFS_FILE_EXTENT_REG,		"REG")			\
-	EMe(BTRFS_FILE_EXTENT_PREALLOC,		"PREALLOC")
+	EM(BTRFS_FILE_EXTENT_INLINE,		"INLINE")		\
+	EM(BTRFS_FILE_EXTENT_REG,		"REG")			\
+	EM(BTRFS_FILE_EXTENT_PREALLOC,		"PREALLOC")
 
 #define QGROUP_RSV_TYPES						\
-	EM( BTRFS_QGROUP_RSV_DATA,		"DATA")			\
-	EM( BTRFS_QGROUP_RSV_META_PERTRANS,	"META_PERTRANS")	\
-	EMe(BTRFS_QGROUP_RSV_META_PREALLOC,	"META_PREALLOC")
+	EM(BTRFS_QGROUP_RSV_DATA,		"DATA")			\
+	EM(BTRFS_QGROUP_RSV_META_PERTRANS,	"META_PERTRANS")	\
+	EM(BTRFS_QGROUP_RSV_META_PREALLOC,	"META_PREALLOC")
 
 #define IO_TREE_OWNER						    \
-	EM( IO_TREE_FS_PINNED_EXTENTS, 	  "PINNED_EXTENTS")	    \
-	EM( IO_TREE_FS_EXCLUDED_EXTENTS,  "EXCLUDED_EXTENTS")	    \
-	EM( IO_TREE_BTREE_INODE_IO,	  "BTREE_INODE_IO")	    \
-	EM( IO_TREE_INODE_IO,		  "INODE_IO")		    \
-	EM( IO_TREE_INODE_IO_FAILURE,	  "INODE_IO_FAILURE")	    \
-	EM( IO_TREE_RELOC_BLOCKS,	  "RELOC_BLOCKS")	    \
-	EM( IO_TREE_TRANS_DIRTY_PAGES,	  "TRANS_DIRTY_PAGES")      \
-	EM( IO_TREE_ROOT_DIRTY_LOG_PAGES, "ROOT_DIRTY_LOG_PAGES")   \
-	EM( IO_TREE_INODE_FILE_EXTENT,	  "INODE_FILE_EXTENT")      \
+	EM(IO_TREE_FS_PINNED_EXTENTS,	  "PINNED_EXTENTS")	    \
+	EM(IO_TREE_FS_EXCLUDED_EXTENTS,	  "EXCLUDED_EXTENTS")	    \
+	EM(IO_TREE_BTREE_INODE_IO,	  "BTREE_INODE_IO")	    \
+	EM(IO_TREE_INODE_IO,		  "INODE_IO")		    \
+	EM(IO_TREE_INODE_IO_FAILURE,	  "INODE_IO_FAILURE")	    \
+	EM(IO_TREE_RELOC_BLOCKS,	  "RELOC_BLOCKS")	    \
+	EM(IO_TREE_TRANS_DIRTY_PAGES,	  "TRANS_DIRTY_PAGES")      \
+	EM(IO_TREE_ROOT_DIRTY_LOG_PAGES,  "ROOT_DIRTY_LOG_PAGES")   \
+	EM(IO_TREE_INODE_FILE_EXTENT,	  "INODE_FILE_EXTENT")      \
 	EM( IO_TREE_LOG_CSUM_RANGE,	  "LOG_CSUM_RANGE")         \
-	EMe(IO_TREE_SELFTEST,		  "SELFTEST")
+	EM( IO_TREE_SELFTEST,		  "SELFTEST")
 
 #define FLUSH_STATES							\
-	EM( FLUSH_DELAYED_ITEMS_NR,	"FLUSH_DELAYED_ITEMS_NR")	\
-	EM( FLUSH_DELAYED_ITEMS,	"FLUSH_DELAYED_ITEMS")		\
-	EM( FLUSH_DELALLOC,		"FLUSH_DELALLOC")		\
-	EM( FLUSH_DELALLOC_WAIT,	"FLUSH_DELALLOC_WAIT")		\
-	EM( FLUSH_DELAYED_REFS_NR,	"FLUSH_DELAYED_REFS_NR")	\
-	EM( FLUSH_DELAYED_REFS,		"FLUSH_ELAYED_REFS")		\
-	EM( ALLOC_CHUNK,		"ALLOC_CHUNK")			\
-	EM( ALLOC_CHUNK_FORCE,		"ALLOC_CHUNK_FORCE")		\
-	EM( RUN_DELAYED_IPUTS,		"RUN_DELAYED_IPUTS")		\
+	EM(FLUSH_DELAYED_ITEMS_NR,	"FLUSH_DELAYED_ITEMS_NR")	\
+	EM(FLUSH_DELAYED_ITEMS,		"FLUSH_DELAYED_ITEMS")		\
+	EM(FLUSH_DELALLOC,		"FLUSH_DELALLOC")		\
+	EM(FLUSH_DELALLOC_WAIT,		"FLUSH_DELALLOC_WAIT")		\
+	EM(FLUSH_DELAYED_REFS_NR,	"FLUSH_DELAYED_REFS_NR")	\
+	EM(FLUSH_DELAYED_REFS,		"FLUSH_ELAYED_REFS")		\
+	EM(ALLOC_CHUNK,			"ALLOC_CHUNK")			\
+	EM(ALLOC_CHUNK_FORCE,		"ALLOC_CHUNK_FORCE")		\
+	EM(RUN_DELAYED_IPUTS,		"RUN_DELAYED_IPUTS")		\
 	EM(COMMIT_TRANS,		"COMMIT_TRANS")			\
-	EMe(FORCE_COMMIT_TRANS,		"FORCE_COMMIT_TRANS")
+	EM(FORCE_COMMIT_TRANS,		"FORCE_COMMIT_TRANS")
 
 /*
  * First define the enums in the above macros to be exported to userspace via
@@ -108,9 +108,7 @@ struct btrfs_space_info;
  */
 
 #undef EM
-#undef EMe
 #define EM(a, b)	TRACE_DEFINE_ENUM(a);
-#define EMe(a, b)	TRACE_DEFINE_ENUM(a);
 
 FLUSH_ACTIONS
 FI_TYPES
@@ -119,14 +117,12 @@ IO_TREE_OWNER
 FLUSH_STATES
 
 /*
- * Now redefine the EM and EMe macros to map the enums to the strings that will
+ * Now redefine the EM macro to map the enums to the strings that will
  * be printed in the output
  */
 
 #undef EM
-#undef EMe
 #define EM(a, b)        {a, b},
-#define EMe(a, b)       {a, b}
 
 
 #define BTRFS_GROUP_FLAGS	\
diff --git a/include/trace/events/huge_memory.h b/include/trace/events/huge_memory.h
index 4fdb14a81108..ae98c5bc03c8 100644
--- a/include/trace/events/huge_memory.h
+++ b/include/trace/events/huge_memory.h
@@ -8,45 +8,41 @@
 #include  <linux/tracepoint.h>
 
 #define SCAN_STATUS							\
-	EM( SCAN_FAIL,			"failed")			\
-	EM( SCAN_SUCCEED,		"succeeded")			\
-	EM( SCAN_PMD_NULL,		"pmd_null")			\
-	EM( SCAN_EXCEED_NONE_PTE,	"exceed_none_pte")		\
-	EM( SCAN_EXCEED_SWAP_PTE,	"exceed_swap_pte")		\
-	EM( SCAN_EXCEED_SHARED_PTE,	"exceed_shared_pte")		\
-	EM( SCAN_PTE_NON_PRESENT,	"pte_non_present")		\
-	EM( SCAN_PTE_UFFD_WP,		"pte_uffd_wp")			\
-	EM( SCAN_PAGE_RO,		"no_writable_page")		\
-	EM( SCAN_LACK_REFERENCED_PAGE,	"lack_referenced_page")		\
-	EM( SCAN_PAGE_NULL,		"page_null")			\
-	EM( SCAN_SCAN_ABORT,		"scan_aborted")			\
-	EM( SCAN_PAGE_COUNT,		"not_suitable_page_count")	\
-	EM( SCAN_PAGE_LRU,		"page_not_in_lru")		\
-	EM( SCAN_PAGE_LOCK,		"page_locked")			\
-	EM( SCAN_PAGE_ANON,		"page_not_anon")		\
-	EM( SCAN_PAGE_COMPOUND,		"page_compound")		\
-	EM( SCAN_ANY_PROCESS,		"no_process_for_page")		\
-	EM( SCAN_VMA_NULL,		"vma_null")			\
-	EM( SCAN_VMA_CHECK,		"vma_check_failed")		\
-	EM( SCAN_ADDRESS_RANGE,		"not_suitable_address_range")	\
-	EM( SCAN_SWAP_CACHE_PAGE,	"page_swap_cache")		\
-	EM( SCAN_DEL_PAGE_LRU,		"could_not_delete_page_from_lru")\
-	EM( SCAN_ALLOC_HUGE_PAGE_FAIL,	"alloc_huge_page_failed")	\
-	EM( SCAN_CGROUP_CHARGE_FAIL,	"ccgroup_charge_failed")	\
-	EM( SCAN_TRUNCATED,		"truncated")			\
-	EMe(SCAN_PAGE_HAS_PRIVATE,	"page_has_private")		\
+	EM(SCAN_FAIL,			"failed")			\
+	EM(SCAN_SUCCEED,		"succeeded")			\
+	EM(SCAN_PMD_NULL,		"pmd_null")			\
+	EM(SCAN_EXCEED_NONE_PTE,	"exceed_none_pte")		\
+	EM(SCAN_EXCEED_SWAP_PTE,	"exceed_swap_pte")		\
+	EM(SCAN_EXCEED_SHARED_PTE,	"exceed_shared_pte")		\
+	EM(SCAN_PTE_NON_PRESENT,	"pte_non_present")		\
+	EM(SCAN_PTE_UFFD_WP,		"pte_uffd_wp")			\
+	EM(SCAN_PAGE_RO,		"no_writable_page")		\
+	EM(SCAN_LACK_REFERENCED_PAGE,	"lack_referenced_page")		\
+	EM(SCAN_PAGE_NULL,		"page_null")			\
+	EM(SCAN_SCAN_ABORT,		"scan_aborted")			\
+	EM(SCAN_PAGE_COUNT,		"not_suitable_page_count")	\
+	EM(SCAN_PAGE_LRU,		"page_not_in_lru")		\
+	EM(SCAN_PAGE_LOCK,		"page_locked")			\
+	EM(SCAN_PAGE_ANON,		"page_not_anon")		\
+	EM(SCAN_PAGE_COMPOUND,		"page_compound")		\
+	EM(SCAN_ANY_PROCESS,		"no_process_for_page")		\
+	EM(SCAN_VMA_NULL,		"vma_null")			\
+	EM(SCAN_VMA_CHECK,		"vma_check_failed")		\
+	EM(SCAN_ADDRESS_RANGE,		"not_suitable_address_range")	\
+	EM(SCAN_SWAP_CACHE_PAGE,	"page_swap_cache")		\
+	EM(SCAN_DEL_PAGE_LRU,		"could_not_delete_page_from_lru")\
+	EM(SCAN_ALLOC_HUGE_PAGE_FAIL,	"alloc_huge_page_failed")	\
+	EM(SCAN_CGROUP_CHARGE_FAIL,	"ccgroup_charge_failed")	\
+	EM(SCAN_TRUNCATED,		"truncated")			\
+	EM(SCAN_PAGE_HAS_PRIVATE,	"page_has_private")		\
 
 #undef EM
-#undef EMe
 #define EM(a, b)	TRACE_DEFINE_ENUM(a);
-#define EMe(a, b)	TRACE_DEFINE_ENUM(a);
 
 SCAN_STATUS
 
 #undef EM
-#undef EMe
 #define EM(a, b)	{a, b},
-#define EMe(a, b)	{a, b}
 
 TRACE_EVENT(mm_khugepaged_scan_pmd,
 
diff --git a/include/trace/events/migrate.h b/include/trace/events/migrate.h
index 4d434398d64d..a0224212e261 100644
--- a/include/trace/events/migrate.h
+++ b/include/trace/events/migrate.h
@@ -8,40 +8,36 @@
 #include <linux/tracepoint.h>
 
 #define MIGRATE_MODE						\
-	EM( MIGRATE_ASYNC,	"MIGRATE_ASYNC")		\
-	EM( MIGRATE_SYNC_LIGHT,	"MIGRATE_SYNC_LIGHT")		\
-	EMe(MIGRATE_SYNC,	"MIGRATE_SYNC")
+	EM(MIGRATE_ASYNC,	"MIGRATE_ASYNC")		\
+	EM(MIGRATE_SYNC_LIGHT,	"MIGRATE_SYNC_LIGHT")		\
+	EM(MIGRATE_SYNC,	"MIGRATE_SYNC")
 
 
 #define MIGRATE_REASON						\
-	EM( MR_COMPACTION,	"compaction")			\
-	EM( MR_MEMORY_FAILURE,	"memory_failure")		\
-	EM( MR_MEMORY_HOTPLUG,	"memory_hotplug")		\
-	EM( MR_SYSCALL,		"syscall_or_cpuset")		\
-	EM( MR_MEMPOLICY_MBIND,	"mempolicy_mbind")		\
-	EM( MR_NUMA_MISPLACED,	"numa_misplaced")		\
-	EMe(MR_CONTIG_RANGE,	"contig_range")
+	EM(MR_COMPACTION,	"compaction")			\
+	EM(MR_MEMORY_FAILURE,	"memory_failure")		\
+	EM(MR_MEMORY_HOTPLUG,	"memory_hotplug")		\
+	EM(MR_SYSCALL,		"syscall_or_cpuset")		\
+	EM(MR_MEMPOLICY_MBIND,	"mempolicy_mbind")		\
+	EM(MR_NUMA_MISPLACED,	"numa_misplaced")		\
+	EM(MR_CONTIG_RANGE,	"contig_range")
 
 /*
  * First define the enums in the above macros to be exported to userspace
  * via TRACE_DEFINE_ENUM().
  */
 #undef EM
-#undef EMe
 #define EM(a, b)	TRACE_DEFINE_ENUM(a);
-#define EMe(a, b)	TRACE_DEFINE_ENUM(a);
 
 MIGRATE_MODE
 MIGRATE_REASON
 
 /*
- * Now redefine the EM() and EMe() macros to map the enums to the strings
+ * Now redefine the EM() macro to map the enums to the strings
  * that will be printed in the output.
  */
 #undef EM
-#undef EMe
 #define EM(a, b)	{a, b},
-#define EMe(a, b)	{a, b}
 
 TRACE_EVENT(mm_migrate_pages,
 
diff --git a/include/trace/events/mmflags.h b/include/trace/events/mmflags.h
index 67018d367b9f..dfb625cedf32 100644
--- a/include/trace/events/mmflags.h
+++ b/include/trace/events/mmflags.h
@@ -178,15 +178,15 @@ IF_HAVE_VM_SOFTDIRTY(VM_SOFTDIRTY,	"softdirty"	)		\
 
 #ifdef CONFIG_COMPACTION
 #define COMPACTION_STATUS					\
-	EM( COMPACT_SKIPPED,		"skipped")		\
-	EM( COMPACT_DEFERRED,		"deferred")		\
-	EM( COMPACT_CONTINUE,		"continue")		\
-	EM( COMPACT_SUCCESS,		"success")		\
-	EM( COMPACT_PARTIAL_SKIPPED,	"partial_skipped")	\
-	EM( COMPACT_COMPLETE,		"complete")		\
-	EM( COMPACT_NO_SUITABLE_PAGE,	"no_suitable_page")	\
-	EM( COMPACT_NOT_SUITABLE_ZONE,	"not_suitable_zone")	\
-	EMe(COMPACT_CONTENDED,		"contended")
+	EM(COMPACT_SKIPPED,		"skipped")		\
+	EM(COMPACT_DEFERRED,		"deferred")		\
+	EM(COMPACT_CONTINUE,		"continue")		\
+	EM(COMPACT_SUCCESS,		"success")		\
+	EM(COMPACT_PARTIAL_SKIPPED,	"partial_skipped")	\
+	EM(COMPACT_COMPLETE,		"complete")		\
+	EM(COMPACT_NO_SUITABLE_PAGE,	"no_suitable_page")	\
+	EM(COMPACT_NOT_SUITABLE_ZONE,	"not_suitable_zone")	\
+	EM(COMPACT_CONTENDED,		"contended")
 
 /* High-level compaction status feedback */
 #define COMPACTION_FAILED	1
@@ -203,12 +203,12 @@ IF_HAVE_VM_SOFTDIRTY(VM_SOFTDIRTY,	"softdirty"	)		\
 #define COMPACTION_FEEDBACK		\
 	EM(COMPACTION_FAILED,		"failed")	\
 	EM(COMPACTION_WITHDRAWN,	"withdrawn")	\
-	EMe(COMPACTION_PROGRESS,	"progress")
+	EM(COMPACTION_PROGRESS,		"progress")
 
 #define COMPACTION_PRIORITY						\
 	EM(COMPACT_PRIO_SYNC_FULL,	"COMPACT_PRIO_SYNC_FULL")	\
 	EM(COMPACT_PRIO_SYNC_LIGHT,	"COMPACT_PRIO_SYNC_LIGHT")	\
-	EMe(COMPACT_PRIO_ASYNC,		"COMPACT_PRIO_ASYNC")
+	EM(COMPACT_PRIO_ASYNC,		"COMPACT_PRIO_ASYNC")
 #else
 #define COMPACTION_STATUS
 #define COMPACTION_PRIORITY
@@ -238,23 +238,21 @@ IF_HAVE_VM_SOFTDIRTY(VM_SOFTDIRTY,	"softdirty"	)		\
 	IFDEF_ZONE_DMA32(	EM (ZONE_DMA32,	 "DMA32"))	\
 				EM (ZONE_NORMAL, "Normal")	\
 	IFDEF_ZONE_HIGHMEM(	EM (ZONE_HIGHMEM,"HighMem"))	\
-				EMe(ZONE_MOVABLE,"Movable")
+				EM (ZONE_MOVABLE,"Movable")
 
 #define LRU_NAMES		\
 		EM (LRU_INACTIVE_ANON, "inactive_anon") \
 		EM (LRU_ACTIVE_ANON, "active_anon") \
 		EM (LRU_INACTIVE_FILE, "inactive_file") \
 		EM (LRU_ACTIVE_FILE, "active_file") \
-		EMe(LRU_UNEVICTABLE, "unevictable")
+		EM (LRU_UNEVICTABLE, "unevictable")
 
 /*
- * First define the enums in the above macros to be exported to userspace
+ * First define the enum in the EM macro to be exported to userspace
  * via TRACE_DEFINE_ENUM().
  */
 #undef EM
-#undef EMe
 #define EM(a, b)	TRACE_DEFINE_ENUM(a);
-#define EMe(a, b)	TRACE_DEFINE_ENUM(a);
 
 COMPACTION_STATUS
 COMPACTION_PRIORITY
@@ -263,10 +261,8 @@ ZONE_TYPE
 LRU_NAMES
 
 /*
- * Now redefine the EM() and EMe() macros to map the enums to the strings
+ * Now redefine the EM() macro to map the enums to the strings
  * that will be printed in the output.
  */
 #undef EM
-#undef EMe
 #define EM(a, b)	{a, b},
-#define EMe(a, b)	{a, b}
diff --git a/include/trace/events/sock.h b/include/trace/events/sock.h
index a966d4b5ab37..254ded9e13b2 100644
--- a/include/trace/events/sock.h
+++ b/include/trace/events/sock.h
@@ -11,40 +11,38 @@
 #include <linux/ipv6.h>
 #include <linux/tcp.h>
 
-#define family_names			\
-		EM(AF_INET)				\
-		EMe(AF_INET6)
+#define family_names					\
+	EM(AF_INET)					\
+	EM(AF_INET6)
 
 /* The protocol traced by inet_sock_set_state */
-#define inet_protocol_names		\
-		EM(IPPROTO_TCP)			\
-		EM(IPPROTO_DCCP)		\
-		EM(IPPROTO_SCTP)		\
-		EMe(IPPROTO_MPTCP)
-
-#define tcp_state_names			\
-		EM(TCP_ESTABLISHED)		\
-		EM(TCP_SYN_SENT)		\
-		EM(TCP_SYN_RECV)		\
-		EM(TCP_FIN_WAIT1)		\
-		EM(TCP_FIN_WAIT2)		\
-		EM(TCP_TIME_WAIT)		\
-		EM(TCP_CLOSE)			\
-		EM(TCP_CLOSE_WAIT)		\
-		EM(TCP_LAST_ACK)		\
-		EM(TCP_LISTEN)			\
-		EM(TCP_CLOSING)			\
-		EMe(TCP_NEW_SYN_RECV)
-
-#define skmem_kind_names			\
-		EM(SK_MEM_SEND)			\
-		EMe(SK_MEM_RECV)
+#define inet_protocol_names				\
+	EM(IPPROTO_TCP)				\
+	EM(IPPROTO_DCCP)			\
+	EM(IPPROTO_SCTP)			\
+	EM(IPPROTO_MPTCP)
+
+#define tcp_state_names					\
+	EM(TCP_ESTABLISHED)				\
+	EM(TCP_SYN_SENT)				\
+	EM(TCP_SYN_RECV)				\
+	EM(TCP_FIN_WAIT1)				\
+	EM(TCP_FIN_WAIT2)				\
+	EM(TCP_TIME_WAIT)				\
+	EM(TCP_CLOSE)					\
+	EM(TCP_CLOSE_WAIT)				\
+	EM(TCP_LAST_ACK)				\
+	EM(TCP_LISTEN)					\
+	EM(TCP_CLOSING)					\
+	EM(TCP_NEW_SYN_RECV)
+
+#define skmem_kind_names				\
+	EM(SK_MEM_SEND)					\
+	EM(SK_MEM_RECV)
 
 /* enums need to be exported to user space */
 #undef EM
-#undef EMe
 #define EM(a)       TRACE_DEFINE_ENUM(a);
-#define EMe(a)      TRACE_DEFINE_ENUM(a);
 
 family_names
 inet_protocol_names
@@ -52,9 +50,7 @@ tcp_state_names
 skmem_kind_names
 
 #undef EM
-#undef EMe
 #define EM(a)       { a, #a },
-#define EMe(a)      { a, #a }
 
 #define show_family_name(val)			\
 	__print_symbolic(val, family_names)
diff --git a/include/trace/events/sunrpc.h b/include/trace/events/sunrpc.h
index 58994e013022..2b3c47ba7ad3 100644
--- a/include/trace/events/sunrpc.h
+++ b/include/trace/events/sunrpc.h
@@ -762,38 +762,36 @@ TRACE_EVENT(rpc_xdr_alignment,
 );
 
 /*
- * First define the enums in the below macros to be exported to userspace
+ * First define the enum in the EM macro to be exported to userspace
  * via TRACE_DEFINE_ENUM().
  */
 #undef EM
-#undef EMe
 #define EM(a, b)	TRACE_DEFINE_ENUM(a);
-#define EMe(a, b)	TRACE_DEFINE_ENUM(a);
 
-#define RPC_SHOW_SOCKET				\
-	EM( SS_FREE, "FREE" )			\
-	EM( SS_UNCONNECTED, "UNCONNECTED" )	\
-	EM( SS_CONNECTING, "CONNECTING" )	\
-	EM( SS_CONNECTED, "CONNECTED" )		\
-	EMe( SS_DISCONNECTING, "DISCONNECTING" )
+#define RPC_SHOW_SOCKET					\
+	EM(SS_FREE,	 	"FREE")			\
+	EM(SS_UNCONNECTED,	"UNCONNECTED")		\
+	EM(SS_CONNECTING,	"CONNECTING")		\
+	EM(SS_CONNECTED,	"CONNECTED")		\
+	EM(SS_DISCONNECTING,	"DISCONNECTING")
 
 #define rpc_show_socket_state(state) \
 	__print_symbolic(state, RPC_SHOW_SOCKET)
 
 RPC_SHOW_SOCKET
 
-#define RPC_SHOW_SOCK				\
-	EM( TCP_ESTABLISHED, "ESTABLISHED" )	\
-	EM( TCP_SYN_SENT, "SYN_SENT" )		\
-	EM( TCP_SYN_RECV, "SYN_RECV" )		\
-	EM( TCP_FIN_WAIT1, "FIN_WAIT1" )	\
-	EM( TCP_FIN_WAIT2, "FIN_WAIT2" )	\
-	EM( TCP_TIME_WAIT, "TIME_WAIT" )	\
-	EM( TCP_CLOSE, "CLOSE" )		\
-	EM( TCP_CLOSE_WAIT, "CLOSE_WAIT" )	\
-	EM( TCP_LAST_ACK, "LAST_ACK" )		\
-	EM( TCP_LISTEN, "LISTEN" )		\
-	EMe( TCP_CLOSING, "CLOSING" )
+#define RPC_SHOW_SOCK					\
+	EM(TCP_ESTABLISHED,	"ESTABLISHED")		\
+	EM(TCP_SYN_SENT,	"SYN_SENT")		\
+	EM(TCP_SYN_RECV,	"SYN_RECV")		\
+	EM(TCP_FIN_WAIT1,	"FIN_WAIT1")		\
+	EM(TCP_FIN_WAIT2,	"FIN_WAIT2")		\
+	EM(TCP_TIME_WAIT,	"TIME_WAIT")		\
+	EM(TCP_CLOSE,		"CLOSE")		\
+	EM(TCP_CLOSE_WAIT,	"CLOSE_WAIT")		\
+	EM(TCP_LAST_ACK,	"LAST_ACK")		\
+	EM(TCP_LISTEN,		"LISTEN")		\
+	EM(TCP_CLOSING,		"CLOSING")
 
 #define rpc_show_sock_state(state) \
 	__print_symbolic(state, RPC_SHOW_SOCK)
@@ -801,13 +799,11 @@ RPC_SHOW_SOCKET
 RPC_SHOW_SOCK
 
 /*
- * Now redefine the EM() and EMe() macros to map the enums to the strings
+ * Now redefine the EM() macro to map the enums to the strings
  * that will be printed in the output.
  */
 #undef EM
-#undef EMe
 #define EM(a, b)	{a, b},
-#define EMe(a, b)	{a, b}
 
 DECLARE_EVENT_CLASS(xs_socket_event,
 
diff --git a/include/trace/events/tlb.h b/include/trace/events/tlb.h
index b4d8e7dc38f8..9e5a3d66e36f 100644
--- a/include/trace/events/tlb.h
+++ b/include/trace/events/tlb.h
@@ -9,31 +9,27 @@
 #include <linux/tracepoint.h>
 
 #define TLB_FLUSH_REASON						\
-	EM(  TLB_FLUSH_ON_TASK_SWITCH,	"flush on task switch" )	\
-	EM(  TLB_REMOTE_SHOOTDOWN,	"remote shootdown" )		\
-	EM(  TLB_LOCAL_SHOOTDOWN,	"local shootdown" )		\
-	EM(  TLB_LOCAL_MM_SHOOTDOWN,	"local mm shootdown" )		\
-	EMe( TLB_REMOTE_SEND_IPI,	"remote ipi send" )
+	EM(TLB_FLUSH_ON_TASK_SWITCH,	"flush on task switch")		\
+	EM(TLB_REMOTE_SHOOTDOWN,	"remote shootdown")		\
+	EM(TLB_LOCAL_SHOOTDOWN,		"local shootdown")		\
+	EM(TLB_LOCAL_MM_SHOOTDOWN,	"local mm shootdown")		\
+	EM(TLB_REMOTE_SEND_IPI,		"remote ipi send")
 
 /*
  * First define the enums in TLB_FLUSH_REASON to be exported to userspace
  * via TRACE_DEFINE_ENUM().
  */
 #undef EM
-#undef EMe
 #define EM(a,b)		TRACE_DEFINE_ENUM(a);
-#define EMe(a,b)	TRACE_DEFINE_ENUM(a);
 
 TLB_FLUSH_REASON
 
 /*
- * Now redefine the EM() and EMe() macros to map the enums to the strings
+ * Now redefine the EM() macro to map the enums to the strings
  * that will be printed in the output.
  */
 #undef EM
-#undef EMe
 #define EM(a,b)		{ a, b },
-#define EMe(a,b)	{ a, b }
 
 TRACE_EVENT(tlb_flush,
 
diff --git a/include/trace/events/ufs.h b/include/trace/events/ufs.h
index 0bd54a184391..28e9ffe7f272 100644
--- a/include/trace/events/ufs.h
+++ b/include/trace/events/ufs.h
@@ -23,38 +23,34 @@
 #define UFS_LINK_STATES			\
 	EM(UIC_LINK_OFF_STATE)		\
 	EM(UIC_LINK_ACTIVE_STATE)	\
-	EMe(UIC_LINK_HIBERN8_STATE)
+	EM(UIC_LINK_HIBERN8_STATE)
 
 #define UFS_PWR_MODES			\
 	EM(UFS_ACTIVE_PWR_MODE)		\
 	EM(UFS_SLEEP_PWR_MODE)		\
 	EM(UFS_POWERDOWN_PWR_MODE)	\
-	EMe(UFS_DEEPSLEEP_PWR_MODE)
+	EM(UFS_DEEPSLEEP_PWR_MODE)
 
 #define UFSCHD_CLK_GATING_STATES	\
 	EM(CLKS_OFF)			\
 	EM(CLKS_ON)			\
 	EM(REQ_CLKS_OFF)		\
-	EMe(REQ_CLKS_ON)
+	EM(REQ_CLKS_ON)
 
 /* Enums require being exported to userspace, for user tool parsing */
 #undef EM
-#undef EMe
 #define EM(a)	TRACE_DEFINE_ENUM(a);
-#define EMe(a)	TRACE_DEFINE_ENUM(a);
 
 UFS_LINK_STATES;
 UFS_PWR_MODES;
 UFSCHD_CLK_GATING_STATES;
 
 /*
- * Now redefine the EM() and EMe() macros to map the enums to the strings
+ * Now redefine the EM() macro to map the enums to the strings
  * that will be printed in the output.
  */
 #undef EM
-#undef EMe
 #define EM(a)	{ a, #a },
-#define EMe(a)	{ a, #a }
 
 TRACE_EVENT(ufshcd_clk_gating,
 
diff --git a/include/trace/events/v4l2.h b/include/trace/events/v4l2.h
index 248bc09bfc99..f918ddd1319f 100644
--- a/include/trace/events/v4l2.h
+++ b/include/trace/events/v4l2.h
@@ -10,28 +10,26 @@
 
 /* Enums require being exported to userspace, for user tool parsing */
 #undef EM
-#undef EMe
 #define EM(a, b)	TRACE_DEFINE_ENUM(a);
-#define EMe(a, b)	TRACE_DEFINE_ENUM(a);
 
 #define show_type(type)							\
 	__print_symbolic(type, SHOW_TYPE)
 
 #define SHOW_TYPE							\
-	EM( V4L2_BUF_TYPE_VIDEO_CAPTURE,	"VIDEO_CAPTURE" )	\
-	EM( V4L2_BUF_TYPE_VIDEO_OUTPUT,		"VIDEO_OUTPUT" )	\
-	EM( V4L2_BUF_TYPE_VIDEO_OVERLAY,	"VIDEO_OVERLAY" )	\
-	EM( V4L2_BUF_TYPE_VBI_CAPTURE,		"VBI_CAPTURE" )		\
-	EM( V4L2_BUF_TYPE_VBI_OUTPUT,		"VBI_OUTPUT" )		\
-	EM( V4L2_BUF_TYPE_SLICED_VBI_CAPTURE,   "SLICED_VBI_CAPTURE" )	\
-	EM( V4L2_BUF_TYPE_SLICED_VBI_OUTPUT,    "SLICED_VBI_OUTPUT" )	\
-	EM( V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY, "VIDEO_OUTPUT_OVERLAY" ) \
-	EM( V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE, "VIDEO_CAPTURE_MPLANE" ) \
-	EM( V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE,  "VIDEO_OUTPUT_MPLANE" )	\
-	EM( V4L2_BUF_TYPE_SDR_CAPTURE,          "SDR_CAPTURE" )		\
-	EM( V4L2_BUF_TYPE_SDR_OUTPUT,           "SDR_OUTPUT" )		\
-	EM( V4L2_BUF_TYPE_META_CAPTURE,		"META_CAPTURE" )	\
-	EMe(V4L2_BUF_TYPE_PRIVATE,		"PRIVATE" )
+	EM(V4L2_BUF_TYPE_VIDEO_CAPTURE,		"VIDEO_CAPTURE")	\
+	EM(V4L2_BUF_TYPE_VIDEO_OUTPUT,		"VIDEO_OUTPUT")		\
+	EM(V4L2_BUF_TYPE_VIDEO_OVERLAY,		"VIDEO_OVERLAY")	\
+	EM(V4L2_BUF_TYPE_VBI_CAPTURE,		"VBI_CAPTURE")		\
+	EM(V4L2_BUF_TYPE_VBI_OUTPUT,		"VBI_OUTPUT")		\
+	EM(V4L2_BUF_TYPE_SLICED_VBI_CAPTURE,	"SLICED_VBI_CAPTURE")	\
+	EM(V4L2_BUF_TYPE_SLICED_VBI_OUTPUT,	"SLICED_VBI_OUTPUT")	\
+	EM(V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY,	"VIDEO_OUTPUT_OVERLAY") \
+	EM(V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE,	"VIDEO_CAPTURE_MPLANE") \
+	EM(V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE,	"VIDEO_OUTPUT_MPLANE")	\
+	EM(V4L2_BUF_TYPE_SDR_CAPTURE,		"SDR_CAPTURE")		\
+	EM(V4L2_BUF_TYPE_SDR_OUTPUT,		"SDR_OUTPUT")		\
+	EM(V4L2_BUF_TYPE_META_CAPTURE,		"META_CAPTURE")		\
+	EM(V4L2_BUF_TYPE_PRIVATE,		"PRIVATE")
 
 SHOW_TYPE
 
@@ -39,27 +37,25 @@ SHOW_TYPE
 	__print_symbolic(field, SHOW_FIELD)
 
 #define SHOW_FIELD							\
-	EM( V4L2_FIELD_ANY,		"ANY" )				\
-	EM( V4L2_FIELD_NONE,		"NONE" )			\
-	EM( V4L2_FIELD_TOP,		"TOP" )				\
-	EM( V4L2_FIELD_BOTTOM,		"BOTTOM" )			\
-	EM( V4L2_FIELD_INTERLACED,	"INTERLACED" )			\
-	EM( V4L2_FIELD_SEQ_TB,		"SEQ_TB" )			\
-	EM( V4L2_FIELD_SEQ_BT,		"SEQ_BT" )			\
-	EM( V4L2_FIELD_ALTERNATE,	"ALTERNATE" )			\
-	EM( V4L2_FIELD_INTERLACED_TB,	"INTERLACED_TB" )		\
-	EMe( V4L2_FIELD_INTERLACED_BT,	"INTERLACED_BT" )
+	EM(V4L2_FIELD_ANY,		"ANY")				\
+	EM(V4L2_FIELD_NONE,		"NONE")				\
+	EM(V4L2_FIELD_TOP,		"TOP")				\
+	EM(V4L2_FIELD_BOTTOM,		"BOTTOM")			\
+	EM(V4L2_FIELD_INTERLACED,	"INTERLACED")			\
+	EM(V4L2_FIELD_SEQ_TB,		"SEQ_TB")			\
+	EM(V4L2_FIELD_SEQ_BT,		"SEQ_BT")			\
+	EM(V4L2_FIELD_ALTERNATE,	"ALTERNATE")			\
+	EM(V4L2_FIELD_INTERLACED_TB,	"INTERLACED_TB")		\
+	EM(V4L2_FIELD_INTERLACED_BT,	"INTERLACED_BT")
 
 SHOW_FIELD
 
 /*
- * Now redefine the EM() and EMe() macros to map the enums to the strings
+ * Now redefine the EM() macro to map the enums to the strings
  * that will be printed in the output.
  */
 #undef EM
-#undef EMe
 #define EM(a, b)	{a, b},
-#define EMe(a, b)	{a, b}
 
 /* V4L2_TC_TYPE_* are macros, not defines, they do not need processing */
 
diff --git a/include/trace/events/writeback.h b/include/trace/events/writeback.h
index 1efa463c4979..ca2840636600 100644
--- a/include/trace/events/writeback.h
+++ b/include/trace/events/writeback.h
@@ -25,29 +25,25 @@
 
 /* enums need to be exported to user space */
 #undef EM
-#undef EMe
-#define EM(a,b) 	TRACE_DEFINE_ENUM(a);
-#define EMe(a,b)	TRACE_DEFINE_ENUM(a);
+#define EM(a, b) 	TRACE_DEFINE_ENUM(a);
 
 #define WB_WORK_REASON							\
-	EM( WB_REASON_BACKGROUND,		"background")		\
-	EM( WB_REASON_VMSCAN,			"vmscan")		\
-	EM( WB_REASON_SYNC,			"sync")			\
-	EM( WB_REASON_PERIODIC,			"periodic")		\
-	EM( WB_REASON_LAPTOP_TIMER,		"laptop_timer")		\
-	EM( WB_REASON_FS_FREE_SPACE,		"fs_free_space")	\
-	EMe(WB_REASON_FORKER_THREAD,		"forker_thread")
+	EM(WB_REASON_BACKGROUND,		"background")		\
+	EM(WB_REASON_VMSCAN,			"vmscan")		\
+	EM(WB_REASON_SYNC,			"sync")			\
+	EM(WB_REASON_PERIODIC,			"periodic")		\
+	EM(WB_REASON_LAPTOP_TIMER,		"laptop_timer")		\
+	EM(WB_REASON_FS_FREE_SPACE,		"fs_free_space")	\
+	EM(WB_REASON_FORKER_THREAD,		"forker_thread")
 
 WB_WORK_REASON
 
 /*
- * Now redefine the EM() and EMe() macros to map the enums to the strings
+ * Now redefine the EM() macro to map the enums to the strings
  * that will be printed in the output.
  */
 #undef EM
-#undef EMe
-#define EM(a,b)		{ a, b },
-#define EMe(a,b)	{ a, b }
+#define EM(a, b)	{ a, b },
 
 struct wb_writeback_work;
 


^ permalink raw reply related	[flat|nested] 15+ messages in thread

* RE: [PATCH v3 0/6] Several changes for the UPIU trace
  2020-12-14 20:20 [PATCH v3 0/6] Several changes for the UPIU trace Bean Huo
                   ` (5 preceding siblings ...)
  2020-12-14 20:20 ` [PATCH v3 6/6] scsi: ufs: Make UPIU trace easier differentiate among CDB, OSF, and TM Bean Huo
@ 2020-12-14 22:13 ` Avri Altman
  2020-12-14 22:37   ` Bean Huo
  6 siblings, 1 reply; 15+ messages in thread
From: Avri Altman @ 2020-12-14 22:13 UTC (permalink / raw)
  To: Bean Huo, alim.akhtar, asutoshd, jejb, martin.petersen,
	stanley.chu, beanhuo, bvanassche, tomas.winkler, cang, rostedt,
	joe
  Cc: linux-scsi, linux-kernel

Bean Hi,
I support this series.
I think it is a good idea to print the response on complete,
But you need to change the prefix strings, otherwise you are breaking the current parsers.

Say that you have a trace log, generated sometime during 2020 using the current upiu trace.
It would look something like:
"send" <request upiu>
"complete" <request upiu>

And another log generated sometime during 2021 after your change is merged:
"send" <request upiu>
"complete" < ****response upiu ****>

The current parser won't be able to differentiate between those logs.
Just change the prefix strings to be "send_req" and "complete_rsp", or something,
so the parsing tools that support the new format will be able to differentiate it from the old one.
  
Also, once the parser can differentiate the new format from the old,
whatever follows its fine: cdb / osf / tsf or whatever makes sense to you.

Thanks,
Avri
 

> -----Original Message-----
> From: Bean Huo <huobean@gmail.com>
> Sent: Monday, December 14, 2020 10:20 PM
> To: alim.akhtar@samsung.com; Avri Altman <Avri.Altman@wdc.com>;
> asutoshd@codeaurora.org; jejb@linux.ibm.com;
> martin.petersen@oracle.com; stanley.chu@mediatek.com;
> beanhuo@micron.com; bvanassche@acm.org; tomas.winkler@intel.com;
> cang@codeaurora.org; rostedt@goodmis.org; joe@perches.com
> Cc: linux-scsi@vger.kernel.org; linux-kernel@vger.kernel.org
> Subject: [PATCH v3 0/6] Several changes for the UPIU trace
> 
> CAUTION: This email originated from outside of Western Digital. Do not click
> on links or open attachments unless you recognize the sender and know that
> the content is safe.
> 
> 
> From: Bean Huo <beanhuo@micron.com>
> 
> Changelog:
> 
> V2--V3:
>   1. Fix a typo in patch 1/6 (Reported-by: Joe Perches <joe@perches.com>)
> 
> V1--V2:
>   1. Convert __get_str(str) to __print_symbolic()
>   2. Add new patches 1/6, 2/6,3/6
>   3. Use __print_symbolic() in patch 6/6
> 
> Bean Huo (6):
>   scsi: ufs: Remove stringize operator '#' restriction
>   scsi: ufs: Use __print_symbolic() for UFS trace string print
>   scsi: ufs: Don't call trace_ufshcd_upiu() in case trace poit is
>     disabled
>   scsi: ufs: Distinguish between query REQ and query RSP in query trace
>   scsi: ufs: Distinguish between TM request UPIU and response UPIU in TM
>     UPIU trace
>   scsi: ufs: Make UPIU trace easier differentiate among CDB, OSF, and TM
> 
>  drivers/scsi/ufs/ufs.h     |  17 ++++++
>  drivers/scsi/ufs/ufshcd.c  |  72 ++++++++++++++++---------
>  include/trace/events/ufs.h | 108 +++++++++++++++++++++++--------------
>  3 files changed, 131 insertions(+), 66 deletions(-)
> 
> --
> 2.17.1


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v3 1/6] scsi: ufs: Remove stringize operator '#' restriction
  2020-12-14 21:23   ` Joe Perches
@ 2020-12-14 22:26     ` Bean Huo
  0 siblings, 0 replies; 15+ messages in thread
From: Bean Huo @ 2020-12-14 22:26 UTC (permalink / raw)
  To: Joe Perches, alim.akhtar, avri.altman, asutoshd, jejb,
	martin.petersen, stanley.chu, beanhuo, bvanassche, tomas.winkler,
	cang, rostedt
  Cc: linux-scsi, linux-kernel

On Mon, 2020-12-14 at 13:23 -0800, Joe Perches wrote:
> > From: Bean Huo <beanhuo@micron.com>
> > 
> > Current EM macro definition, we use stringize operator '#', which
> > turns
> > the argument it precedes into a quoted string. Thus requires the
> > symbol
> > of __print_symbolic() should be the string corresponding to the
> > name of
> > the enum.
> > 
> > However, we have other cases, the symbol and enum name are not the
> > same,
> > we can redefine EM/EMe, but there will introduce some redundant
> > codes.
> > This patch is to remove this restriction, let others reuse the
> > current
> > EM/EMe definition.
> 
> While this version doesn't have the copy/paste typo,
> I fail to see value in defining EMe as a trailing comma
> in an array declaration isn't meaningful and doesn't emit
> any error or warning.
> 
> Maybe all the uses of EMe can be converted to EM and the
> macro definitions removed.

Hi Joe
I removed EMe, but there is this error:

./include/trace/trace_events.h:300:18: error: initializer element is
not constant
    { symbol_array, { -1, NULL }};   \

./include/trace/trace_events.h:300:18: error: expected expression
before ‘,’ token
    { symbol_array, { -1, NULL }};   \


did you choose kernel trace and event trace before compiling?


Thanks,
Bean


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v3 0/6] Several changes for the UPIU trace
  2020-12-14 22:13 ` [PATCH v3 0/6] Several changes for the UPIU trace Avri Altman
@ 2020-12-14 22:37   ` Bean Huo
  2020-12-15 22:18     ` Bean Huo
  0 siblings, 1 reply; 15+ messages in thread
From: Bean Huo @ 2020-12-14 22:37 UTC (permalink / raw)
  To: Avri Altman, alim.akhtar, asutoshd, jejb, martin.petersen,
	stanley.chu, beanhuo, bvanassche, tomas.winkler, cang, rostedt,
	joe
  Cc: linux-scsi, linux-kernel

On Mon, 2020-12-14 at 22:13 +0000, Avri Altman wrote:
> Bean Hi,
> I support this series.
> I think it is a good idea to print the response on complete,
> But you need to change the prefix strings, otherwise you are breaking
> the current parsers.
> 
> Say that you have a trace log, generated sometime during 2020 using
> the current upiu trace.
> It would look something like:
> "send" <request upiu>
> "complete" <request upiu>
> 
> And another log generated sometime during 2021 after your change is
> merged:
> "send" <request upiu>
> "complete" < ****response upiu ****>
> 
> The current parser won't be able to differentiate between those logs.
> Just change the prefix strings to be "send_req" and "complete_rsp",
> or something,
> so the parsing tools that support the new format will be able to
> differentiate it from the old one.

Avri,
I still don't understand, this change doesn't break you current parser.
if you still trace "send", "complete", "CDB", "query_send/complte",
they are still there, doesn't change. I suggest you just run on your
system. see if there is conflict.

Regarding your suggestion:
This is not problem now, we just change this definition.

do you mean just "send" and "complete" or all?

#define
UFS_CMD_TRACE_STRINGS                                   \              
          
        EM(UFS_CMD_SEND,        "send_req")                         \  
                                  
        EM(UFS_CMD_COMP,        "complete_rsp")                     \  

below also need add "req" and "rsp"?

                                  
        EM(UFS_DEV_COMP,        "dev_complete_rsp")                 \  
                                  
        EM(UFS_QUERY_SEND,      "query_send")                   \      
                              
        EM(UFS_QUERY_COMP,      "query_complete")               \      
                              
        EM(UFS_QUERY_ERR,       "query_complete_err")           \      
                              
        EM(UFS_TM_SEND,         "tm_send")                      \      
                              
        EM(UFS_TM_COMP,         "tm_complete")                  \      
                              
        EM(UFS_TM_ERR,          "tm_complete_err")    


>   
> Also, once the parser can differentiate the new format from the old,
> whatever follows its fine: cdb / osf / tsf or whatever makes sense to
> you.
> 
> Thanks,
> Avri


^ permalink raw reply	[flat|nested] 15+ messages in thread

* RE: [PATCH v3 1/6] scsi: ufs: Remove stringize operator '#' restriction
  2020-12-14 20:20 ` [PATCH v3 1/6] scsi: ufs: Remove stringize operator '#' restriction Bean Huo
  2020-12-14 21:23   ` Joe Perches
@ 2020-12-14 23:11   ` David Laight
  2020-12-14 23:21     ` Steven Rostedt
  1 sibling, 1 reply; 15+ messages in thread
From: David Laight @ 2020-12-14 23:11 UTC (permalink / raw)
  To: 'Bean Huo',
	alim.akhtar, avri.altman, asutoshd, jejb, martin.petersen,
	stanley.chu, beanhuo, bvanassche, tomas.winkler, cang, rostedt,
	joe
  Cc: linux-scsi, linux-kernel

From: Bean Huo <huobean@gmail.com>
> Sent: 14 December 2020 20:20
> 
> From: Bean Huo <beanhuo@micron.com>
> 
> Current EM macro definition, we use stringize operator '#', which turns
> the argument it precedes into a quoted string. Thus requires the symbol
> of __print_symbolic() should be the string corresponding to the name of
> the enum.
> 
> However, we have other cases, the symbol and enum name are not the same,
> we can redefine EM/EMe, but there will introduce some redundant codes.
> This patch is to remove this restriction, let others reuse the current
> EM/EMe definition.
> 
> Acked-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
> Signed-off-by: Bean Huo <beanhuo@micron.com>
> ---
>  include/trace/events/ufs.h | 40 +++++++++++++++++++-------------------
>  1 file changed, 20 insertions(+), 20 deletions(-)
> 
> diff --git a/include/trace/events/ufs.h b/include/trace/events/ufs.h
> index 0bd54a184391..fa755394bc0f 100644
> --- a/include/trace/events/ufs.h
> +++ b/include/trace/events/ufs.h
> @@ -20,28 +20,28 @@
..
> +#define UFS_LINK_STATES						\
> +	EM(UIC_LINK_OFF_STATE,		"UIC_LINK_OFF_STATE")		\
> +	EM(UIC_LINK_ACTIVE_STATE,	"UIC_LINK_ACTIVE_STATE")	\
> +	EMe(UIC_LINK_HIBERN8_STATE,	"UIC_LINK_HIBERN8_STATE")

If you make EM a parameter to UFS_LINK_STATES then the caller
can pass in the name of a #define that does the required expansion.
The caller can also add in any required terminator after the last entry.
For an enum (which doesn't want a , at the end) just add a dummy entry.
You often want a constant for the number of items anyway.

	David

-
Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK
Registration No: 1397386 (Wales)


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v3 1/6] scsi: ufs: Remove stringize operator '#' restriction
  2020-12-14 23:11   ` David Laight
@ 2020-12-14 23:21     ` Steven Rostedt
  0 siblings, 0 replies; 15+ messages in thread
From: Steven Rostedt @ 2020-12-14 23:21 UTC (permalink / raw)
  To: David Laight
  Cc: 'Bean Huo',
	alim.akhtar, avri.altman, asutoshd, jejb, martin.petersen,
	stanley.chu, beanhuo, bvanassche, tomas.winkler, cang, joe,
	linux-scsi, linux-kernel

On Mon, 14 Dec 2020 23:11:40 +0000
David Laight <David.Laight@ACULAB.COM> wrote:

> > ---
> >  include/trace/events/ufs.h | 40 +++++++++++++++++++-------------------
> >  1 file changed, 20 insertions(+), 20 deletions(-)
> > 
> > diff --git a/include/trace/events/ufs.h b/include/trace/events/ufs.h
> > index 0bd54a184391..fa755394bc0f 100644
> > --- a/include/trace/events/ufs.h
> > +++ b/include/trace/events/ufs.h
> > @@ -20,28 +20,28 @@  
> ..
> > +#define UFS_LINK_STATES						\
> > +	EM(UIC_LINK_OFF_STATE,		"UIC_LINK_OFF_STATE")		\
> > +	EM(UIC_LINK_ACTIVE_STATE,	"UIC_LINK_ACTIVE_STATE")	\
> > +	EMe(UIC_LINK_HIBERN8_STATE,	"UIC_LINK_HIBERN8_STATE")  
> 
> If you make EM a parameter to UFS_LINK_STATES then the caller
> can pass in the name of a #define that does the required expansion.
> The caller can also add in any required terminator after the last entry.
> For an enum (which doesn't want a , at the end) just add a dummy entry.
> You often want a constant for the number of items anyway.

This is currently the way its done in multiple other places. When creating
the "EMe" trick, I've thought about it, but then realized it would make the
other locations look strange without the expected comma, and decided that
EMe() would be the best solution, as it's only strange in where it's added,
and not where its used.

 $ git grep -l EMe include/trace/ |wc -l
     11

It's already used in 11 other files, let's not muck with it now.

-- Steve


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v3 0/6] Several changes for the UPIU trace
  2020-12-14 22:37   ` Bean Huo
@ 2020-12-15 22:18     ` Bean Huo
  2021-01-04 20:39       ` Bean Huo
  0 siblings, 1 reply; 15+ messages in thread
From: Bean Huo @ 2020-12-15 22:18 UTC (permalink / raw)
  To: Avri Altman, alim.akhtar, asutoshd, jejb, martin.petersen,
	stanley.chu, beanhuo, bvanassche, tomas.winkler, cang, rostedt,
	joe
  Cc: linux-scsi, linux-kernel

On Mon, 2020-12-14 at 23:37 +0100, Bean Huo wrote:
> > And another log generated sometime during 2021 after your change is
> > merged:
> > "send" <request upiu>
> > "complete" < ****response upiu ****>
> > 
> > The current parser won't be able to differentiate between those
> > logs.
> > Just change the prefix strings to be "send_req" and "complete_rsp",
> > or something,
> > so the parsing tools that support the new format will be able to
> > differentiate it from the old one.
> 
> Avri,
> I still don't understand, this change doesn't break you current
> parser.
> if you still trace "send", "complete", "CDB", "query_send/complte",
> they are still there, doesn't change. I suggest you just run on your
> system. see if there is conflict.
> 
> Regarding your suggestion:
> This is not problem now, we just change this definition.
> 
> do you mean just "send" and "complete" or all?
> 
> #define
> UFS_CMD_TRACE_STRINGS                                  
> \              
>           
>         EM(UFS_CMD_SEND,        "send_req")                        
> \  
>                                   
>         EM(UFS_CMD_COMP,        "complete_rsp")                    
> \  
> 
> below also need add "req" and "rsp"?
> 
>                                   
>         EM(UFS_DEV_COMP,        "dev_complete_rsp")                
> \  
>                                   
>         EM(UFS_QUERY_SEND,      "query_send")                  
> \      
>                               
>         EM(UFS_QUERY_COMP,      "query_complete")              
> \      
>                               
>         EM(UFS_QUERY_ERR,       "query_complete_err")          
> \      
>                               
>         EM(UFS_TM_SEND,         "tm_send")                     
> \      
>                               
>         EM(UFS_TM_COMP,         "tm_complete")                 
> \      
>                               
>         EM(UFS_TM_ERR,          "tm_complete_err") 


Hi Avri

I am waiting for your answer. How can I change these strings to back-
compatible with your tool? Tt seems only you use these strings.

Thanks,
Bean


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v3 0/6] Several changes for the UPIU trace
  2020-12-15 22:18     ` Bean Huo
@ 2021-01-04 20:39       ` Bean Huo
  0 siblings, 0 replies; 15+ messages in thread
From: Bean Huo @ 2021-01-04 20:39 UTC (permalink / raw)
  To: Avri Altman, alim.akhtar, asutoshd, jejb, martin.petersen,
	stanley.chu, beanhuo, bvanassche, tomas.winkler, cang, rostedt,
	joe
  Cc: linux-scsi, linux-kernel

On Tue, 2020-12-15 at 23:18 +0100, Bean Huo wrote:
> On Mon, 2020-12-14 at 23:37 +0100, Bean Huo wrote:
> > > And another log generated sometime during 2021 after your change
> > > is
> > > merged:
> > > "send" <request upiu>
> > > "complete" < ****response upiu ****>
> > > 
> > > The current parser won't be able to differentiate between those
> > > logs.
> > > Just change the prefix strings to be "send_req" and
> > > "complete_rsp",
> > > or something,
> > > so the parsing tools that support the new format will be able to
> > > differentiate it from the old one.
> > 
> > Avri,
> > I still don't understand, this change doesn't break you current
> > parser.
> > if you still trace "send", "complete", "CDB", "query_send/complte",
> > they are still there, doesn't change. I suggest you just run on
> > your
> > system. see if there is conflict.
> > 
> > Regarding your suggestion:
> > This is not problem now, we just change this definition.
> > 
> > do you mean just "send" and "complete" or all?
> > 
> > #define
> > UFS_CMD_TRACE_STRINGS                                  
> > \              
> >           
> >         EM(UFS_CMD_SEND,        "send_req")                        
> > \  
> >                                   
> >         EM(UFS_CMD_COMP,        "complete_rsp")                    
> > \  
> > 
> > below also need add "req" and "rsp"?
> > 
> >                                   
> >         EM(UFS_DEV_COMP,        "dev_complete_rsp")                
> > \  
> >                                   
> >         EM(UFS_QUERY_SEND,      "query_send")                  
> > \      
> >                               
> >         EM(UFS_QUERY_COMP,      "query_complete")              
> > \      
> >                               
> >         EM(UFS_QUERY_ERR,       "query_complete_err")          
> > \      
> >                               
> >         EM(UFS_TM_SEND,         "tm_send")                     
> > \      
> >                               
> >         EM(UFS_TM_COMP,         "tm_complete")                 
> > \      
> >                               
> >         EM(UFS_TM_ERR,          "tm_complete_err") 
> 
> 
> Hi Avri
> 
> I am waiting for your answer. How can I change these strings to back-
> compatible with your tool? Tt seems only you use these strings.
> 
> Thanks,
> Bean
> 


Hi Avri
Before sending next version, double confirm with your.  I think you
just need change:

"send" to "send_req" 
"complete" to "complete_rsp"
                           

Bean






^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2021-01-04 23:33 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-14 20:20 [PATCH v3 0/6] Several changes for the UPIU trace Bean Huo
2020-12-14 20:20 ` [PATCH v3 1/6] scsi: ufs: Remove stringize operator '#' restriction Bean Huo
2020-12-14 21:23   ` Joe Perches
2020-12-14 22:26     ` Bean Huo
2020-12-14 23:11   ` David Laight
2020-12-14 23:21     ` Steven Rostedt
2020-12-14 20:20 ` [PATCH v3 2/6] scsi: ufs: Use __print_symbolic() for UFS trace string print Bean Huo
2020-12-14 20:20 ` [PATCH v3 3/6] scsi: ufs: Don't call trace_ufshcd_upiu() in case trace poit is disabled Bean Huo
2020-12-14 20:20 ` [PATCH v3 4/6] scsi: ufs: Distinguish between query REQ and query RSP in query trace Bean Huo
2020-12-14 20:20 ` [PATCH v3 5/6] scsi: ufs: Distinguish between TM request UPIU and response UPIU in TM UPIU trace Bean Huo
2020-12-14 20:20 ` [PATCH v3 6/6] scsi: ufs: Make UPIU trace easier differentiate among CDB, OSF, and TM Bean Huo
2020-12-14 22:13 ` [PATCH v3 0/6] Several changes for the UPIU trace Avri Altman
2020-12-14 22:37   ` Bean Huo
2020-12-15 22:18     ` Bean Huo
2021-01-04 20:39       ` Bean Huo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).