diff --git a/src/app/data_harvester/disks/unix/linux/counters.rs b/src/app/data_harvester/disks/unix/linux/counters.rs index 22134b85..f01d5b7d 100644 --- a/src/app/data_harvester/disks/unix/linux/counters.rs +++ b/src/app/data_harvester/disks/unix/linux/counters.rs @@ -16,24 +16,24 @@ use crate::app::data_harvester::disks::IoCounters; /// via /sys/block/{DISK}/queue/hw_sector_size and results may vary /// between 1k, 2k, or 4k... 512 appears to be a magic constant used /// throughout Linux source code: -/// * https://stackoverflow.com/a/38136179/376587 -/// * https://lists.gt.net/linux/kernel/2241060 -/// * https://github.com/giampaolo/psutil/issues/1305 -/// * https://github.com/torvalds/linux/blob/4f671fe2f9523a1ea206f63fe60a7c7b3a56d5c7/include/linux/bio.h#L99 -/// * https://lkml.org/lkml/2015/8/17/234 +/// * +/// * +/// * +/// * +/// * const DISK_SECTOR_SIZE: u64 = 512; impl FromStr for IoCounters { type Err = anyhow::Error; - /// Converts a `&str` to an [`IoStats`]. + /// Converts a `&str` to an [`IoCounters`]. /// /// Follows the format used in Linux 2.6+. Note that this completely ignores the following stats: /// - Discard stats from 4.18+ /// - Flush stats from 5.5+ /// - /// https://www.kernel.org/doc/Documentation/iostats.txt - /// https://www.kernel.org/doc/Documentation/ABI/testing/procfs-diskstats + /// + /// fn from_str(s: &str) -> anyhow::Result { fn next_part<'a>(iter: &mut impl Iterator) -> Result<&'a str, io::Error> { iter.next() diff --git a/src/components/tui_widget/time_chart/canvas.rs b/src/components/tui_widget/time_chart/canvas.rs index fc921cb4..f1d98825 100644 --- a/src/components/tui_widget/time_chart/canvas.rs +++ b/src/components/tui_widget/time_chart/canvas.rs @@ -1,4 +1,4 @@ -//! Vendored from https://github.com/fdehau/tui-rs/blob/fafad6c96109610825aad89c4bba5253e01101ed/src/widgets/canvas/mod.rs. +//! Vendored from . //! Main difference is in the Braille rendering, which can now effectively be done in a single layer without the effects //! of doing it all in a single layer via the normal tui-rs crate. This means you can do it all in a single pass, with //! just one string alloc and no resets.