<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7654.12">
<TITLE>RE: [PATCH] Re: linux-next: build warning after merge of the xfs tree</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/plain format -->

<P><FONT SIZE=2>&gt; Dave Chinner &lt;<A HREF="mailto:david@fromorbit.com">mailto:david@fromorbit.com</A>&gt; wrote:<BR>
&gt; On Thu, Mar 04, 2010 at 11:19:30AM +1100, Stephen Rothwell wrote:<BR>
&gt; &gt; Hi Dave,<BR>
&gt; &gt;<BR>
&gt; &gt; After merging the xfs tree, today's linux-next build (x86_64 allmodconfig)<BR>
&gt; &gt; produced this warning:<BR>
&gt; &gt;<BR>
&gt; &gt; fs/xfs/linux-2.6/xfs_aops.c: In function 'xfs_end_io':<BR>
&gt; &gt; fs/xfs/linux-2.6/xfs_aops.c:232: warning: 'error' may be used uninitialized in this function<BR>
&gt; &gt;<BR>
&gt; &gt; Introduced by commit 77d7a0c2eeb285c9069e15396703d0cb9690ac50 (&quot;xfs:<BR>
&gt; &gt; Non-blocking inode locking in IO completion&quot;).<BR>
&gt; &gt;<BR>
&gt; &gt; I can't tell if this is a false positive.&nbsp; If the first two &quot;if&quot;<BR>
&gt; &gt; statement bodies are skipped, then error is tested uninitialised.&nbsp; It is<BR>
&gt; &gt; possible that at least one of them has to be executed.<BR>
&gt;<BR>
&gt; Right, there is a warning being generated there - I thought I fixed<BR>
&gt; that immediately after posting the first version of the patch. The<BR>
&gt; second version:<BR>
&gt;<BR>
&gt; <A HREF="http://oss.sgi.com/archives/xfs/2010-02/msg00340.html">http://oss.sgi.com/archives/xfs/2010-02/msg00340.html</A><BR>
&gt;<BR>
&gt; definitely had it fixed.<BR>
&gt;<BR>
&gt; Alex, can you make sure you take the entire patch rather than<BR>
&gt; cutting and pasting bits from one patch version to another?&nbsp; That<BR>
&gt; way you don't miss small changes to the patch that might have been<BR>
&gt; forgotten about....<BR>
<BR>
I didn't expect you would change the patch content, only<BR>
the description.&nbsp; I had already tested the previous code<BR>
so just grabbed the new description when you re-posted.<BR>
Sorry about the warning slipping through.&nbsp; I'll incorporate<BR>
your fix below (tomorrow).<BR>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; -Alex<BR>
<BR>
<BR>
&gt; Stephen, the patch below should fix the warning.<BR>
&gt;<BR>
&gt; Cheers,<BR>
&gt;<BR>
&gt; Dave.<BR>
&gt; --<BR>
&gt; Dave Chinner<BR>
&gt; david@fromorbit.com<BR>
&gt;<BR>
&gt; xfs: fix uninitialised variable warning in xfs_end_io<BR>
&gt;<BR>
&gt; Signed-off-by: Dave Chinner &lt;david@fromorbit.com&gt;<BR>
&gt; ---<BR>
&gt;&nbsp; fs/xfs/linux-2.6/xfs_aops.c |&nbsp;&nbsp;&nbsp; 2 +-<BR>
&gt;&nbsp; 1 files changed, 1 insertions(+), 1 deletions(-)<BR>
&gt;<BR>
&gt; diff --git a/fs/xfs/linux-2.6/xfs_aops.c b/fs/xfs/linux-2.6/xfs_aops.c<BR>
&gt; index f41a2d8..8989c16 100644<BR>
&gt; --- a/fs/xfs/linux-2.6/xfs_aops.c<BR>
&gt; +++ b/fs/xfs/linux-2.6/xfs_aops.c<BR>
&gt; @@ -230,7 +230,7 @@ xfs_end_io(<BR>
&gt;&nbsp; {<BR>
&gt;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp; xfs_ioend_t&nbsp;&nbsp;&nbsp;&nbsp; *ioend = container_of(work, xfs_ioend_t, io_work);<BR>
&gt;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp; struct xfs_inode *ip = XFS_I(ioend-&gt;io_inode);<BR>
&gt; -&nbsp;&nbsp;&nbsp;&nbsp; int&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; error;<BR>
&gt; +&nbsp;&nbsp;&nbsp;&nbsp; int&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; error = 0;<BR>
&gt;&nbsp;<BR>
&gt;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp; /*<BR>
&gt;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * For unwritten extents we need to issue transactions to convert a<BR>
&gt;<BR>
&gt;<BR>
</FONT>
</P>

</BODY>
</HTML>