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: <TY1PR01MB157894A971A781BE900C5A7590DD0@TY1PR01MB1578.jpnprd01.prod.outlook.com>
Date:   Mon, 13 Apr 2020 09:41:22 +0000
From:   "Kohada.Tetsuhiro@...MitsubishiElectric.co.jp" 
        <Kohada.Tetsuhiro@...MitsubishiElectric.co.jp>
To:     unlisted-recipients:; (no To-header on input)
CC:     "Mori.Takahiro@...MitsubishiElectric.co.jp" 
        <Mori.Takahiro@...MitsubishiElectric.co.jp>,
        "Motai.Hirotaka@...MitsubishiElectric.co.jp" 
        <Motai.Hirotaka@...MitsubishiElectric.co.jp>,
        Namjae Jeon <namjae.jeon@...sung.com>,
        Sungjong Seo <sj1557.seo@...sung.com>,
        "linux-fsdevel@...r.kernel.org" <linux-fsdevel@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH v2] exfat: replace 'time_ms' with 'time_10ms'

> Please leave at least 24 hours between sending new versions so that
> you can collect all feedback relating to your change, and we don't see
> discussion fragment between different threads.

Thanks for good advice!

> > +		ts->tv_sec += (time_10ms * 10) / 1000;
> > +		ts->tv_nsec = (time_10ms * 10) % 1000 * NSEC_PER_MSEC;
> 
> I find this more confusing than the original.

The parentheses were intended to group conversions into milliseconds, 
but were not necessary from an "operator precedence" perspective.


> 
> 		ts->tv_sec += time_10ms / 100;
> 		ts->tv_nsec = (time_10ms % 100) * 10 * NSEC_PER_MSEC;
> 
> is easier to understand for me, not least because I don't need to worry
> about the operator precedence between % and *.

If I use '100' for the divisor of '10ms', I find it difficult to understand 
the meaning of the operation.

When using '100' for the divisor, I think cs (centi-sec) is easier to understand than 10ms.
Which do you prefer, time_10ms or time_cs?


BR
---
Kohada Tetsuhiro <Kohada.Tetsuhiro@...MitsubishiElectric.co.jp>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ