All of lore.kernel.org
 help / color / mirror / Atom feed
* Issue with 252c651a4c85 ("blk-cgroup: stop using seq_get_buf")
@ 2022-05-12 22:42 ` Khazhy Kumykov
  0 siblings, 0 replies; 13+ messages in thread
From: Khazhy Kumykov @ 2022-05-12 22:42 UTC (permalink / raw)
  To: Tejun Heo, Jens Axboe, Christoph Hellwig; +Cc: linux-block, w.bumiller, cgroups

[-- Attachment #1: Type: text/plain, Size: 1007 bytes --]

I can see in the latest tip, if we have devices with no statistics,
we'll print the maj:min and then nothing else, which can end up
looking weird, (e.g. like below.) I see that in older kernels, we
avoided printing the device name at all if there were no stats, and it
looks like this behavior was silently broken by 252c651a4c85
("blk-cgroup: stop using seq_get_buf"), where before we prepared the
whole line then decided at the end whether to commit it or not.

I do see a patch "blk-cgroup: always terminate io.stat lines" that
addresses this by just unconditionally printing the newline (though it
looks like that patch never landed). I'm wondering if it's worth
trying to bring back the old behavior of not printing these devices at
all if they have no statistics. (e.g. by having the "first"
stats-haver writing out the bdev name, or going back to scnprintf)

9:0 8:0 rbytes=16720896 wbytes=905216 rios=768 wios=67 dbytes=0 dios=0
1:15 1:14 1:13 1:12 1:11 1:10 1:9 1:8 1:7 1:6 1:5 1:4 1:3 1:2 1:1 1:0

[-- Attachment #2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 3999 bytes --]

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

end of thread, other threads:[~2022-05-17  6:27 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-12 22:42 Issue with 252c651a4c85 ("blk-cgroup: stop using seq_get_buf") Khazhy Kumykov
2022-05-12 22:42 ` Khazhy Kumykov
2022-05-12 23:25 ` Khazhy Kumykov
2022-05-12 23:29   ` [RFC PATCH] blkcg: rewind seq_file if no stats Khazhismel Kumykov
2022-05-13 16:30     ` Tejun Heo
2022-05-13 17:40   ` [RESEND][RFC " Khazhismel Kumykov
2022-05-13 18:06     ` Khazhy Kumykov
2022-05-13 18:06       ` Khazhy Kumykov
2022-05-17  6:12     ` Christoph Hellwig
2022-05-17  6:27       ` Khazhy Kumykov
2022-05-17  6:27         ` Khazhy Kumykov
2022-05-17  6:11 ` Issue with 252c651a4c85 ("blk-cgroup: stop using seq_get_buf") Christoph Hellwig
2022-05-17  6:11   ` Christoph Hellwig

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.