Re: [PATCH v4 7/7] e2fsck: INODE64 high part is more important then LUFID

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On May 4, 2018, at 1:09 AM, c17828 <artem.blagodarenko@xxxxxxxxx> wrote:
> 
> From: Artem Blagodarenko <artem.blagodarenko@xxxxxxxxx>
> 
> Keep the INO64 field over LUFID, since it is both smaller,
> and more important.
> 
> Lustre-bug: https://jira.hpdd.intel.com/browse/LU-9309
> Signed-off-by: Artem Blagodarenko <artem.blagodarenko@xxxxxxxxx>
> ---
> e2fsck/pass2.c | 22 +++++++++++++++++++++-
> 1 file changed, 21 insertions(+), 1 deletion(-)
> 
> @@ -399,6 +408,17 @@ void ext2_fix_dirent_dirdata(struct ext2_dir_entry *de)
> 		}
> 	}
> 
> +	/* Keep the INO64 field over  LUFID, since it is both smaller,
> +	 * and more important.
> +	 */
> +	if (inop && (ext2_get_dirdata_field_size(de, new_flag) >= 5) &&

Wasn't there a structure added to hold the inode64 value?  That should be
used here for sizeof(ext2fs_dirdata_inode64) (or whatever it is named)
instead of "5", which doesn't pass very much information to the reader.

I don't see it in this patch, so it might have only been added in the
kernel part of the dirdata patch.  It should also be used in e2fsprogs.

> +	    !(new_flag & EXT2_DIRENT_INODE)) {
> +		new_flag &= ~EXT2_DIRENT_LUFID;
> +		new_flag |= EXT2_DIRENT_INODE;
> +		memmove(startp, inop,
> +			ext2_get_dirdata_field_size(de, new_flag));
> +	}
> +
> 	de->name_len = name_len | file_type | (new_flag << 8);
> }
> 
> --
> 2.14.3 (Apple Git-98)
> 


Cheers, Andreas





Attachment: signature.asc
Description: Message signed with OpenPGP


[Index of Archives]     [Reiser Filesystem Development]     [Ceph FS]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite National Park]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]     [Linux Media]

  Powered by Linux