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]
Date:   Fri, 21 Oct 2016 11:54:35 +0200
From:   Jan Kara <jack@...e.cz>
To:     Dan Carpenter <dan.carpenter@...cle.com>
Cc:     Theodore Ts'o <tytso@....edu>, Fabian Frederick <fabf@...net.be>,
        Andreas Dilger <adilger.kernel@...ger.ca>,
        linux-ext4@...r.kernel.org, kernel-janitors@...r.kernel.org
Subject: Re: ext4: remove another test in ext4_alloc_file_blocks()

On Wed 12-10-16 09:00:02, Dan Carpenter wrote:
> Before commit c3fe493ccdb1 ('ext4: remove unneeded test in
> ext4_alloc_file_blocks()') then it was possible for "depth" to be -1
> but now, it's not possible that it is negative.
> 
> Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>

Looks good. You can add:

Reviewed-by: Jan Kara <jack@...e.cz>

								Honza

> 
> diff --git a/fs/ext4/extents.c b/fs/ext4/extents.c
> index c930a01..dca394c 100644
> --- a/fs/ext4/extents.c
> +++ b/fs/ext4/extents.c
> @@ -4701,7 +4701,7 @@ static int ext4_alloc_file_blocks(struct file *file, ext4_lblk_t offset,
>  		/*
>  		 * Recalculate credits when extent tree depth changes.
>  		 */
> -		if (depth >= 0 && depth != ext_depth(inode)) {
> +		if (depth != ext_depth(inode)) {
>  			credits = ext4_chunk_trans_blocks(inode, len);
>  			depth = ext_depth(inode);
>  		}
> --
> To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
> the body of a message to majordomo@...r.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
-- 
Jan Kara <jack@...e.com>
SUSE Labs, CR
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ