diff mbox series

[06/15] xfs: standardize daddr formatting in ftrace output

Message ID 162924376504.761813.17237311452402341703.stgit@magnolia (mailing list archive)
State Accepted, archived
Headers show
Series xfs: clean up ftrace field tags and formats | expand

Commit Message

Darrick J. Wong Aug. 17, 2021, 11:42 p.m. UTC
From: Darrick J. Wong <djwong@kernel.org>

Always print disk addr (i.e. 512 byte block) numbers in hexadecimal and
preceded with the unit "daddr".

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
---
 fs/xfs/xfs_trace.h |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

Comments

Dave Chinner Aug. 19, 2021, 2:42 a.m. UTC | #1
On Tue, Aug 17, 2021 at 04:42:45PM -0700, Darrick J. Wong wrote:
> From: Darrick J. Wong <djwong@kernel.org>
> 
> Always print disk addr (i.e. 512 byte block) numbers in hexadecimal and
> preceded with the unit "daddr".
> 
> Signed-off-by: Darrick J. Wong <djwong@kernel.org>
> ---
>  fs/xfs/xfs_trace.h |    8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)

Looks good.

Reviewed-by: Dave Chinner <dchinner@redhat.com>
Carlos Maiolino Aug. 19, 2021, 11:02 a.m. UTC | #2
On Tue, Aug 17, 2021 at 04:42:45PM -0700, Darrick J. Wong wrote:
> From: Darrick J. Wong <djwong@kernel.org>
> 
> Always print disk addr (i.e. 512 byte block) numbers in hexadecimal and
> preceded with the unit "daddr".
> 
> Signed-off-by: Darrick J. Wong <djwong@kernel.org>

Reviewed-by: Carlos Maiolino <cmaiolino@redhat.com>

> ---
>  fs/xfs/xfs_trace.h |    8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> 
> diff --git a/fs/xfs/xfs_trace.h b/fs/xfs/xfs_trace.h
> index d6365a0ee0ff..3944373ad2f6 100644
> --- a/fs/xfs/xfs_trace.h
> +++ b/fs/xfs/xfs_trace.h
> @@ -397,7 +397,7 @@ DECLARE_EVENT_CLASS(xfs_buf_class,
>  		__entry->flags = bp->b_flags;
>  		__entry->caller_ip = caller_ip;
>  	),
> -	TP_printk("dev %d:%d bno 0x%llx nblks 0x%x hold %d pincount %d "
> +	TP_printk("dev %d:%d daddr 0x%llx nblks 0x%x hold %d pincount %d "
>  		  "lock %d flags %s caller %pS",
>  		  MAJOR(__entry->dev), MINOR(__entry->dev),
>  		  (unsigned long long)__entry->bno,
> @@ -465,7 +465,7 @@ DECLARE_EVENT_CLASS(xfs_buf_flags_class,
>  		__entry->lockval = bp->b_sema.count;
>  		__entry->caller_ip = caller_ip;
>  	),
> -	TP_printk("dev %d:%d bno 0x%llx len 0x%zx hold %d pincount %d "
> +	TP_printk("dev %d:%d daddr 0x%llx len 0x%zx hold %d pincount %d "
>  		  "lock %d flags %s caller %pS",
>  		  MAJOR(__entry->dev), MINOR(__entry->dev),
>  		  (unsigned long long)__entry->bno,
> @@ -510,7 +510,7 @@ TRACE_EVENT(xfs_buf_ioerror,
>  		__entry->flags = bp->b_flags;
>  		__entry->caller_ip = caller_ip;
>  	),
> -	TP_printk("dev %d:%d bno 0x%llx len 0x%zx hold %d pincount %d "
> +	TP_printk("dev %d:%d daddr 0x%llx len 0x%zx hold %d pincount %d "
>  		  "lock %d error %d flags %s caller %pS",
>  		  MAJOR(__entry->dev), MINOR(__entry->dev),
>  		  (unsigned long long)__entry->bno,
> @@ -552,7 +552,7 @@ DECLARE_EVENT_CLASS(xfs_buf_item_class,
>  		__entry->buf_lockval = bip->bli_buf->b_sema.count;
>  		__entry->li_flags = bip->bli_item.li_flags;
>  	),
> -	TP_printk("dev %d:%d bno 0x%llx len 0x%zx hold %d pincount %d "
> +	TP_printk("dev %d:%d daddr 0x%llx len 0x%zx hold %d pincount %d "
>  		  "lock %d flags %s recur %d refcount %d bliflags %s "
>  		  "liflags %s",
>  		  MAJOR(__entry->dev), MINOR(__entry->dev),
>
diff mbox series

Patch

diff --git a/fs/xfs/xfs_trace.h b/fs/xfs/xfs_trace.h
index d6365a0ee0ff..3944373ad2f6 100644
--- a/fs/xfs/xfs_trace.h
+++ b/fs/xfs/xfs_trace.h
@@ -397,7 +397,7 @@  DECLARE_EVENT_CLASS(xfs_buf_class,
 		__entry->flags = bp->b_flags;
 		__entry->caller_ip = caller_ip;
 	),
-	TP_printk("dev %d:%d bno 0x%llx nblks 0x%x hold %d pincount %d "
+	TP_printk("dev %d:%d daddr 0x%llx nblks 0x%x hold %d pincount %d "
 		  "lock %d flags %s caller %pS",
 		  MAJOR(__entry->dev), MINOR(__entry->dev),
 		  (unsigned long long)__entry->bno,
@@ -465,7 +465,7 @@  DECLARE_EVENT_CLASS(xfs_buf_flags_class,
 		__entry->lockval = bp->b_sema.count;
 		__entry->caller_ip = caller_ip;
 	),
-	TP_printk("dev %d:%d bno 0x%llx len 0x%zx hold %d pincount %d "
+	TP_printk("dev %d:%d daddr 0x%llx len 0x%zx hold %d pincount %d "
 		  "lock %d flags %s caller %pS",
 		  MAJOR(__entry->dev), MINOR(__entry->dev),
 		  (unsigned long long)__entry->bno,
@@ -510,7 +510,7 @@  TRACE_EVENT(xfs_buf_ioerror,
 		__entry->flags = bp->b_flags;
 		__entry->caller_ip = caller_ip;
 	),
-	TP_printk("dev %d:%d bno 0x%llx len 0x%zx hold %d pincount %d "
+	TP_printk("dev %d:%d daddr 0x%llx len 0x%zx hold %d pincount %d "
 		  "lock %d error %d flags %s caller %pS",
 		  MAJOR(__entry->dev), MINOR(__entry->dev),
 		  (unsigned long long)__entry->bno,
@@ -552,7 +552,7 @@  DECLARE_EVENT_CLASS(xfs_buf_item_class,
 		__entry->buf_lockval = bip->bli_buf->b_sema.count;
 		__entry->li_flags = bip->bli_item.li_flags;
 	),
-	TP_printk("dev %d:%d bno 0x%llx len 0x%zx hold %d pincount %d "
+	TP_printk("dev %d:%d daddr 0x%llx len 0x%zx hold %d pincount %d "
 		  "lock %d flags %s recur %d refcount %d bliflags %s "
 		  "liflags %s",
 		  MAJOR(__entry->dev), MINOR(__entry->dev),