From mboxrd@z Thu Jan 1 00:00:00 1970 From: Goldwyn Rodrigues Date: Mon, 14 Feb 2011 12:24:01 -0600 Subject: [Ocfs2-devel] [PATCH] Zero from EOF instead of next block In-Reply-To: <20110214072503.GA8413@noexit> References: <20110214072503.GA8413@noexit> Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: ocfs2-devel@oss.oracle.com On Mon, Feb 14, 2011 at 1:25 AM, Joel Becker wrote: > On Mon, Feb 14, 2011 at 12:21:41AM -0600, Goldwyn Rodrigues wrote: >> ocfs2_zero_extend() extends the file from the next page offset >> rather from the current file size. zero_extend_page() should >> call ocfs2_zero_partial_cluster() to set zero rest of the cluster >> when the file size is within the page boundaries. > > ? ? ? ?We just went over this. ?It is intentional that we start from > the next block. ?Linux code always assumes that the block containing > i_size is properly zeroed to its end. ?Our last set of fixes for this > made sure we were doing that correctly. ?Or so I thought. > ? ? ? ?Your patch description looks like you are worried that we don't > zero from EOF to End-Of-Block. ?Have you proof we've failed that again? > Or are you worried that we don't zero from EOB to End-Of-Cluster? ?We > used to zero to EOC, but we now know that to be a mistake. > Why is zeroing to EOC a mistake? I ran my tests again and found the problem to be from EOB to End-of-cluster, and of course this happens only with blocksize