lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CALYGNiOA4K4PQcJTk_OwkHOamW-Am_gKSUZoog41v+Y_+qEQxg@mail.gmail.com>
Date: Sat, 15 Feb 2025 18:18:20 +0100
From: Konstantin Khlebnikov <koct9i@...il.com>
To: David Reaver <me@...idreaver.com>
Cc: Jonathan Corbet <corbet@....net>, Randy Dunlap <rdunlap@...radead.org>, Jens Axboe <axboe@...nel.dk>, 
	linux-doc@...r.kernel.org, linux-block@...r.kernel.org, 
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] docs: iostats: Rewrite intro, remove outdated formats

On Fri, 14 Feb 2025 at 18:39, David Reaver <me@...idreaver.com> wrote:
>
> Konstantin Khlebnikov <koct9i@...il.com> writes:
>
> > Wraparounds here are slightly more complicated than simply 32-bit or 64-bit overflows.
> >
> > Internal time counters are 64-bit in nanoseconds.
> >
> > Values are converted into milliseconds for printing,
> > also 32-bit architectures truncate printed values to 32-bit.
> >
> > So the common trick: delta = (long)(after - before) does not work,
> > because the time counter wraps around UINT64_MAX/1000.
> >
>
> Thanks Konstantin. What do you think about just removing this entire
> sentence? It is mostly tweaked from the old text that was rewritten, but
> I'm not sure it is particularly insightful. That paragraph would look
> like this:
>
>   All fields are cumulative, monotonic counters that start at zero at
>   boot, except for field 9, which resets to zero as I/Os complete. Other
>   fields only increase unless they overflow and wrap. Wrapping may occur
>   on long-running or high-load systems, so applications should handle this
>   properly.

There is another case when counters back to zero:
device reattachment or reinitialization.
The device itself might be the same or completely different,
but statistics sampling will see only restart from zero.

So, maybe rephrase that counters sometimes restarts at zero.
For example at boot, device attachment, or counter overflows.

>
> Thanks,
> David Reaver

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ