Re: Patch fs/xfs/xfs_alloc.c

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

 



On Thu, 2010-09-02 at 00:41 -0700, Poyo VL wrote:
> Im using "gcc version 4.5.0 20100604 [gcc-4_5-branch revision 160292] (SUSE 
> Linux)"
> 
> Before compiling kernel (2.6.35.4) I selected from menuconfig all XFS "options": 
> Quota supprt, POSIX ACL support, Realtime subvolume support and Debugging 
> support. I saved the .config and I typed "make". 
> 
> 
> I got the following warnings:
> 
> fs/xfs/xfs_alloc.c: In function ‘xfs_alloc_ag_vextent_near’:
> fs/xfs/xfs_alloc.c:694:15: warning: ‘ltlena’ may be used uninitialized in this 
> function
> fs/xfs/xfs_alloc.c:683:15: warning: ‘gtlena’ may be used uninitialized in this 
> function
> 
> So I tried to initialize those variables (structures) with 0.
> 
> Sorry, I am not neither a C, nor a kernel expert.

I'm going to take this in (to top-of-tree), but
I'll be modifying it slightly (xfs_extlen_t is
not a struct, so I'll initialize with a simple 0).
It may well be that these variables never get used
without being set, but it's not at all clear from
a quick look so this is a simple fix.

Thanks for reporting the warning.

Reviewed-by: Alex Elder <aelder@xxxxxxx>


_______________________________________________
xfs mailing list
xfs@xxxxxxxxxxx
http://oss.sgi.com/mailman/listinfo/xfs



[Index of Archives]     [Linux XFS Devel]     [Linux Filesystem Development]     [Filesystem Testing]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux