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]
Date:	Wed, 26 Aug 2015 17:55:22 +0200
From:	Jan Kara <jack@...e.cz>
To:	"Darrick J. Wong" <darrick.wong@...cle.com>
Cc:	Jan Kara <jack@...e.com>, linux-ext4@...r.kernel.org,
	Ted Tso <tytso@....edu>, Jan Kara <jack@...e.cz>
Subject: Re: [PATCH 08/19] ext2fs: Implement block moving in libext2fs

On Fri 07-08-15 08:55:14, Darrick J. Wong wrote:
> On Fri, Aug 07, 2015 at 12:51:18PM +0200, Jan Kara wrote:
> > From: Jan Kara <jack@...e.cz>
> > 
> > Signed-off-by: Jan Kara <jack@...e.cz>
> 
> <snip>
> 
> > diff --git a/lib/ext2fs/extent_map.c b/lib/ext2fs/extent_map.c
> > new file mode 100644
> > index 000000000000..702172b24e2b
> > --- /dev/null
> > +++ b/lib/ext2fs/extent_map.c
> > @@ -0,0 +1,233 @@
> > +/*
> > + * extent.c --- ext2 extent mapping abstraction
> > + *
> > + * This abstraction is used to provide a compact way of representing a
> > + * translation table, for moving multiple contiguous ranges (extents)
> > + * of blocks or inodes.
> > + *
> > + * Copyright (C) 1997, 1998 by Theodore Ts'o and
> > + * 	PowerQuest, Inc.
> > + *
> > + * Copyright (C) 1999, 2000 by Theosore Ts'o
> 
> Ted should probably weigh in on this amazing coincidence in contributors :)
> but this I suspect is a spelling error waiting a long time to be fixed.

Fixed up.

> > + *
> > + * %Begin-Header%
> 
> <snip>
> 
> > diff --git a/lib/ext2fs/move.h b/lib/ext2fs/move.h
> > new file mode 100644
> > index 000000000000..8d66aa039ec0
> > --- /dev/null
> > +++ b/lib/ext2fs/move.h
> > @@ -0,0 +1,23 @@
> > +#ifndef _EXT2FS_MOVE_H
> > +#define _EXT2FS_MOVE_H
> > +
> > +#include "ext2fs.h"
> > +
> > +typedef struct _ext2_map_extent *ext2_map_extent;
> > +
> > +/* extent_map.c */
> > +extern int ext2fs_extent_table_empty(ext2_map_extent extent);
> > +extern errcode_t ext2fs_create_extent_table(ext2_map_extent *ret_extent,
> > +					    __u64 size);
> > +extern void ext2fs_free_extent_table(ext2_map_extent extent);
> > +extern errcode_t ext2fs_add_extent_entry(ext2_map_extent extent,
> > +					 __u64 old_loc, __u64 new_loc);
> > +extern __u64 ext2fs_extent_translate(ext2_map_extent extent, __u64 old_loc);
> > +extern errcode_t ext2fs_iterate_extent(ext2_map_extent extent, __u64 *old_loc,
> > +				       __u64 *new_loc, __u64 *size);
> > +
> > +/* move.c */
> > +errcode_t ext2fs_move_blocks(ext2_filsys fs, ext2fs_block_bitmap move_map,
> > +			     ext2fs_block_bitmap reuse_map);
> > +
> > +#endif
> 
> Hmm... are these functions intended for use by client programs?  I'm accustomed
> to looking in ext2fs.h for such functions.

So block moving function is definitely for use by client programs. So I'll
move that to ext2fs.h. Extent mapping functions could possibly be useful but
no interface in libext2fs needs these as an input / output so I'd consider
these internal.

								Honza
-- 
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