Re: [PATCH 4/5] libext2fs: Implement ext2fs_find_first_zero_generic_bmap().

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

 



On Mon, Mar 12, 2012 at 09:15:14PM +0200, Sami Liedes wrote:
> In the case of ext2fs_new_inode(), the function does not actually
> iterate through all zero bits; it really only wants to find the first
> zero in a certain range, after which it returns. So for simplicity of
> use (and efficiency) I think it still makes sense to have
> ->find_first_zero() too.

I agree, a find_first_zero() and a find_first_set(), both of which
taking a starting bit position for the search, and the best low-level
primitives that would be implemented on for each backend bitmap
implementation.

It would then be very easy to build iterators on *top* of
find_first_zero() and find_first_set(), and in fact this could be used
to replace some of the places where we are using a sorted list (i.e.,
the badblocks list).  So that sounds like a good idea, and I can
definitely think of some places where we could use that code today.

So I plan to pull in your patch series and then we can further enhance
this with iterator support afterwards.  Sami, if you'd be interested
in implementing iterators, that would be great!

Thanks,

   			   	      	 - Ted
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[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