Re: [RFC][Patch 1/2] Persistent preallocation in ext4

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

 



On Tue, Jan 02, 2007 at 04:34:09PM +0530, Amit K. Arora wrote:
> On Wed, Dec 27, 2006 at 03:30:44PM -0800, Mingming Cao wrote:
> > Since the API takes the number of bytes to preallocate, at return time,
> > shall we convert the blocks to bytes to the user?
> >
> > Here it returns the number of allocated blocks to the user.   Do we need
> > to worry about the case when dealing with a range with partial hole and
> > partial blocks already allocated? In that case nblocks(the new
> > preallocated blocks) will less than the maxblocks (the number of blocks
> > asked by application).  I am wondering what does other filesystem like
> > xfs do? Maybe we should do the same thing.
> 
> I think xfs just returns 0 on success, and errno on an error. Do we
> want to keep the same behavior here ? Or, should we return the number of
> bytes preallocated ?

We still need to decide on what the ioctl should return. Should it
return zero on success and errno on error, like how posix_fallocate and
xfs behave ?  If yes, then should we undo partial preallocation (if any)
in case of an error (say ENOSPC) ?

If no, then should we return the number of bytes preallocated ? In this
case we have to think about the situation Mingming mentioned above (i.e.
when the preallocation request partially spans through a hole and
partially through few already allocated blocks).

--
Regards,
Amit Arora
-
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