From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id AA2941DF246 for ; Mon, 20 Jan 2025 11:19:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1737371997; cv=none; b=WFTHUjdZsLSoqmL+fSIvMnq7rV4txXBW3oKE5yOLhnmHWrXVTwbUU67b/oJ25wmTpC8AVtu3Y+GYYdXfY0zPjxcsnK0vOEf9PtLWSz8ktlXlTKS63zYACBKbsyBdI3ep9c+DGjO156o14VUOVmYyKmBKp+BRdFQGF8wvB6YyjcI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1737371997; c=relaxed/simple; bh=oSHk3cSqjy4pIYcib0WLfuNmwU7o2+oVafI0R0Xv/5M=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=QnbPJ5jwfolhTy0gxHAU8Lc99/4q5fAWLz9MGvhJ/LcdaCCNuNK0A4WvwuVTz7SnxwmHlJE0rNhXndF/YrkmK/5g8476VPu5Y55Ierv1a9hBMXVutM0VWGxUvoVM8DgLam1Uqq3kOR1a/6991h012dxuw7kaZPbHu3bbRfWBUm0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=gZHQ6vzA; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="gZHQ6vzA" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2A393C4CEE3; Mon, 20 Jan 2025 11:19:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1737371997; bh=oSHk3cSqjy4pIYcib0WLfuNmwU7o2+oVafI0R0Xv/5M=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=gZHQ6vzAW320IQbPCjHow6MpdSvFcDtgNE85wrSfSGJGKCdLvOV60Mn6Z6fsxg9TZ qT6+q+/qacU/q+1ZETniavlaWBtcBU8Mk5BA+2wwJW4KwkZ3myLbKGuFx1hDUw1pPW hGJVcH0J6CT4mpR0AggFTt1CsVhn9DeZ5UJRRwffjvYxZFCkJ7X9lPANFhVpCMbnQa e9L2W+SNma1BT3DCzBuGBAwNBt+cPdz4cuu8iIavEGjyPbH50q1IvbcGAUMh1m+3wr 2zCyFwhzx5q2H7ndAvQ497LFBDG/zTPSR4YcXjATNGx7jKnDFSWi1UrTxmCpqZ3L2K vYnZfa9035/3Q== From: Chao Yu To: jaegeuk@kernel.org Cc: linux-f2fs-devel@lists.sourceforge.net, linux-kernel@vger.kernel.org, Chao Yu Subject: [PATCH 2/2] f2fs: procfs: show mtime in segment_bits Date: Mon, 20 Jan 2025 19:19:41 +0800 Message-ID: <20250120111941.191621-2-chao@kernel.org> X-Mailer: git-send-email 2.48.1.262.g85cc9f2d1e-goog In-Reply-To: <20250120111941.191621-1-chao@kernel.org> References: <20250120111941.191621-1-chao@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Show mtime in segment_bits for debug. cat /proc/fs//f2fs/loop0/segment_bits format: segment_type|valid_blocks|bitmaps|mtime segment_type(0:HD, 1:WD, 2:CD, 3:HN, 4:WN, 5:CN) 0 3|1 | 04 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00| ffffffffffffffff 1 4|3 | 00 d0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00| ffffffffffffffff 2 5|0 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00| ffffffffffffffff 3 0|1 | 40 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00| ffffffffffffffff Signed-off-by: Chao Yu --- fs/f2fs/sysfs.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fs/f2fs/sysfs.c b/fs/f2fs/sysfs.c index f81190fabdd3..b01c5984cf22 100644 --- a/fs/f2fs/sysfs.c +++ b/fs/f2fs/sysfs.c @@ -1480,7 +1480,7 @@ static int __maybe_unused segment_bits_seq_show(struct seq_file *seq, le32_to_cpu(sbi->raw_super->segment_count_main); int i, j; - seq_puts(seq, "format: segment_type|valid_blocks|bitmaps\n" + seq_puts(seq, "format: segment_type|valid_blocks|bitmaps|mtime\n" "segment_type(0:HD, 1:WD, 2:CD, 3:HN, 4:WN, 5:CN)\n"); for (i = 0; i < total_segs; i++) { @@ -1490,6 +1490,7 @@ static int __maybe_unused segment_bits_seq_show(struct seq_file *seq, seq_printf(seq, "%d|%-3u|", se->type, se->valid_blocks); for (j = 0; j < SIT_VBLOCK_MAP_SIZE; j++) seq_printf(seq, " %.2x", se->cur_valid_map[j]); + seq_printf(seq, "| %llx", se->mtime); seq_putc(seq, '\n'); } return 0; -- 2.48.1.262.g85cc9f2d1e-goog