[prev in list] [next in list] [prev in thread] [next in thread]
List: yaffs
Subject: Re: [Yaffs] a question about yaffs_hold_space
From: Charles Manning <cdhmanning () gmail ! com>
Date: 2015-07-30 22:13:07
Message-ID: CAE21AQoKF=jY+nxUV_cYAEkhPKuc-zmX9xGJBb=0FT0Bxe6bTQ () mail ! gmail ! com
[Download RAW message or body]
[Attachment #2 (multipart/alternative)]
The purpose of yaffs_hold_space() is to support the write_begin VFS method.
write_begin asks the file system to commit enough space to do the actual
write in write_end.
Strictly speaking this should really be handled with counter of committed
space that is incremented on every write_begin and decremented on every
write_end.
However, it is workable to just not expect there to be more than n writes
in progress at a time. n=20 seems rather conservative.
-- Charles
On Thu, Jul 30, 2015 at 3:04 PM, chenjie <chenjie6@huawei.com> wrote:
>
> Hi:
> why the yaffs_hold_space reserved 20 chunk?
> return (n_free_chunks > 20) ? 1 : 0;
>
>
>
>
[Attachment #5 (text/html)]
<div dir="ltr"><div><div><div><div>The purpose of yaffs_hold_space() is to support \
the write_begin VFS method.<br><br></div>write_begin asks the file system to commit \
enough space to do the actual write in write_end.<br><br></div>Strictly speaking this \
should really be handled with counter of committed space that is incremented on every \
write_begin and decremented on every write_end.<br><br></div>However, it is workable \
to just not expect there to be more than n writes in progress at a time. n=20 seems \
rather conservative.<br><br></div>-- Charles<br><br></div><div \
class="gmail_extra"><br><div class="gmail_quote">On Thu, Jul 30, 2015 at 3:04 PM, \
chenjie <span dir="ltr"><<a href="mailto:chenjie6@huawei.com" \
target="_blank">chenjie6@huawei.com</a>></span> wrote:<br><blockquote \
class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc \
solid;padding-left:1ex"><br> Hi:<br>
why the yaffs_hold_space reserved 20 chunk?<br>
return (n_free_chunks > 20) ? 1 : 0;<br>
<br>
<br>
<br>
</blockquote></div><br></div>
_______________________________________________
yaffs mailing list
yaffs@lists.aleph1.co.uk
http://lists.aleph1.co.uk/cgi-bin/mailman/listinfo/yaffs
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic