<div dir="ltr">AFAIR, this behavior has been there since day 1 and changing it will impact performance negatively. I would recommend against making this change for one app.<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">
On Wed, Jun 26, 2013 at 6:50 PM, shencanquan <span dir="ltr">&lt;<a href="mailto:shencanquan@huawei.com" target="_blank">shencanquan@huawei.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">On 2013/6/27 9:25, Andrew Morton wrote:<br>
<br>
&gt; On Thu, 27 Jun 2013 09:19:52 +0800 shencanquan &lt;<a href="mailto:shencanquan@huawei.com">shencanquan@huawei.com</a>&gt; wrote:<br>
&gt;<br>
&gt;&gt; On 2013/6/27 5:18, Andrew Morton wrote:<br>
&gt;&gt;<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; My guess is that there is some other code path which is modifying<br>
&gt;&gt;&gt; inode-&gt;i_size without holding inode-&gt;i_mutex, and while holding<br>
&gt;&gt;&gt; ocfs2_inode_lock().  If so, that code is surely wrong - it should hold<br>
&gt;&gt;&gt; i_mutex while modifying i_size.<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt; inode-&gt;i_mutex lock only protect the inode size on the same machine.<br>
&gt;<br>
&gt; ah ;)<br>
&gt;<br>
&gt;&gt;&gt; And all this is only really applicable to 32-bit CPUs, which you<br>
&gt;&gt;&gt; probably aren&#39;t using.<br>
&gt;&gt;<br>
&gt;&gt; I don&#39;t understand this.<br>
&gt;<br>
&gt; The i_size_read/i_size_write infrastructure is designed to efficiently<br>
&gt; handle the situation where a 32-bit machine reads a 64-bit number which<br>
&gt; might be undergoing modification on another CPU.  We don&#39;t want the<br>
&gt; reading CPU to see an invalid number when the writing CPU is in the<br>
&gt; middle of modifying the two 32-bit words.<br>
&gt;<br>
&gt;<br>
&gt;<br>
<br>
</div>ok. thanks.<br>
<div class="HOEnZb"><div class="h5"><br>
<br>
_______________________________________________<br>
Ocfs2-devel mailing list<br>
<a href="mailto:Ocfs2-devel@oss.oracle.com">Ocfs2-devel@oss.oracle.com</a><br>
<a href="https://oss.oracle.com/mailman/listinfo/ocfs2-devel" target="_blank">https://oss.oracle.com/mailman/listinfo/ocfs2-devel</a><br>
</div></div></blockquote></div><br></div>