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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <19910196-DFF3-4F94-B6D3-B9BF722DF8B8@toblux.com>
Date: Thu, 29 Feb 2024 20:41:31 +0100
From: Thorsten Blum <thorsten.blum@...lux.com>
To: Ryusuke Konishi <konishi.ryusuke@...il.com>
Cc: linux-nilfs@...r.kernel.org,
 linux-kernel@...r.kernel.org
Subject: Re: [PATCH] nilfs2: Use div64_ul() instead of do_div()


> On Feb 29, 2024, at 19:45, Ryusuke Konishi <konishi.ryusuke@...il.com> wrote:
> 
> All of the fixes in this patch seem to be correct, but this doesn't
> cover nilfs_resize_fs(), nilfs_max_segment_count(), and
> nilfs_sb2_bad_offset(), which also have do_div() that doesn't use the
> return value.

I just tested this, and Coccinelle didn't report nilfs_resize_fs() or
nilfs_max_segment_count() because both divisors are fields of a struct. I will
refactor this and submit a v2.

For nilfs_sb2_bad_offset(), where the dividend is u64 and the divisor is u32, we
would need a dedicated function like div64_u32() that doesn't calculate the
remainder, which doesn't seem to exist. What do you think?

Thanks,
Thorsten

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ