From b01f58e3a96913727e2459ae485f17ca0d149946 Mon Sep 17 00:00:00 2001 From: Patrick Farrell Date: Fri, 18 Aug 2023 14:31:32 -0400 Subject: [PATCH] LU-15367 llite: iotrace standardization Clean up and standardize some of the iotrace messages for easier parsing. Add a clear 'START' indicator. Remove a now-redundant debug message in the mmap code. Test-Parameters: trivial Signed-off-by: Patrick Farrell Change-Id: Ia620cc8c783509cbc3f47b21a274d67d860b80e7 Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/52002 Reviewed-by: Andreas Dilger Reviewed-by: Sebastien Buisson Reviewed-by: Oleg Drokin Tested-by: Maloo Tested-by: jenkins --- lustre/llite/file.c | 6 ++++-- lustre/llite/llite_mmap.c | 14 +++++--------- 2 files changed, 9 insertions(+), 11 deletions(-) diff --git a/lustre/llite/file.c b/lustre/llite/file.c index 92ba94b..626aea8 100644 --- a/lustre/llite/file.c +++ b/lustre/llite/file.c @@ -2096,7 +2096,8 @@ static ssize_t ll_file_read_iter(struct kiocb *iocb, struct iov_iter *to) ENTRY; - CDEBUG(D_VFSTRACE|D_IOTRACE, "file %s:"DFID", ppos: %lld, count: %zu\n", + CDEBUG(D_VFSTRACE|D_IOTRACE, + "START file %s:"DFID", ppos: %lld, count: %zu\n", file_dentry(file)->d_name.name, PFID(ll_inode2fid(file_inode(file))), iocb->ki_pos, iov_iter_count(to)); @@ -2248,7 +2249,8 @@ static ssize_t ll_file_write_iter(struct kiocb *iocb, struct iov_iter *from) ENTRY; - CDEBUG(D_VFSTRACE|D_IOTRACE, "file %s:"DFID", ppos: %lld, count: %zu\n", + CDEBUG(D_VFSTRACE|D_IOTRACE, + "START file %s:"DFID", ppos: %lld, count: %zu\n", file_dentry(file)->d_name.name, PFID(ll_inode2fid(file_inode(file))), iocb->ki_pos, iov_iter_count(from)); diff --git a/lustre/llite/llite_mmap.c b/lustre/llite/llite_mmap.c index a0ddda6..b6f95d9 100644 --- a/lustre/llite/llite_mmap.c +++ b/lustre/llite/llite_mmap.c @@ -123,11 +123,6 @@ restart: fio->ft_writable = 1; } - CDEBUG(D_MMAP, - DFID": vma=%p start=%#lx end=%#lx vm_flags=%#lx idx=%lu\n", - PFID(&ll_i2info(inode)->lli_fid), vma, vma->vm_start, - vma->vm_end, vma->vm_flags, fio->ft_index); - if (vma->vm_flags & VM_SEQ_READ) io->ci_seq_read = 1; else if (vma->vm_flags & VM_RAND_READ) @@ -404,7 +399,8 @@ static vm_fault_t ll_fault(struct vm_area_struct *vma, struct vm_fault *vmf) goto out; CDEBUG(D_MMAP|D_IOTRACE, - DFID": vma=%p start=%#lx end=%#lx vm_flags=%#lx idx=%lu\n", + "START file %s:"DFID", vma=%p start=%#lx end=%#lx vm_flags=%#lx idx=%lu\n", + file_dentry(vma->vm_file)->d_name.name, PFID(&ll_i2info(file_inode(vma->vm_file))->lli_fid), vma, vma->vm_start, vma->vm_end, vma->vm_flags, vmf->pgoff); @@ -488,10 +484,10 @@ static vm_fault_t ll_page_mkwrite(struct vm_area_struct *vma, vm_fault_t result; CDEBUG(D_MMAP|D_IOTRACE, - DFID": vma=%p start=%#lx end=%#lx vm_flags=%#lx idx=%lu\n", + "START file %s:"DFID", vma=%p start=%#lx end=%#lx vm_flags=%#lx idx=%lu\n", + file_dentry(vma->vm_file)->d_name.name, PFID(&ll_i2info(file_inode(vma->vm_file))->lli_fid), - vma, vma->vm_start, vma->vm_end, vma->vm_flags, - vmf->page->index); + vma, vma->vm_start, vma->vm_end, vma->vm_flags, vmf->page->index); result = pcc_page_mkwrite(vma, vmf, &cached); if (cached) -- 1.8.3.1