[ovs-dev] [sparse 0/4] fix sparse complaints

Jesse Gross jesse at nicira.com
Tue Dec 28 18:12:44 UTC 2010


On Tue, Dec 28, 2010 at 12:57 PM, Ben Pfaff <blp at nicira.com> wrote:
> On Tue, Dec 28, 2010 at 12:37:42PM -0500, Jesse Gross wrote:
>> On Tue, Dec 28, 2010 at 12:21 PM, Ben Pfaff <blp at nicira.com> wrote:
>> > On Tue, Dec 28, 2010 at 12:35:24AM -0500, Jesse Gross wrote:
>> >> On Tue, Dec 28, 2010 at 12:20 AM, Ben Pfaff <blp at nicira.com> wrote:
>> >> > On Mon, Dec 27, 2010 at 9:14 PM, Jesse Gross <jesse at nicira.com> wrote:
>> >> >> On Mon, Dec 27, 2010 at 6:38 PM, Ben Pfaff <blp at nicira.com> wrote:
>> >> >>> This series fixes various issues that sparse complained about.  None
>> >> >>> of them is a bug fix, but all of them seemed worth fixing.
>> >> >>
>> >> >> Hmm, I guess that I should turn up the warning level when I run sparse.
>> >> >
>> >> > I just built passing "C=1" to the "make" process, so I didn't do anything
>> >> > special.  Are you running it some other way?
>> >>
>> >> No, that's how I run it as well (sometimes also with
>> >> CF="-D__CHECK_ENDIAN__").  Running that against master I don't see any
>> >> warnings (with the exception of some RCU checks that were added in
>> >> 2.6.37 that I'll send out patches for soon).  If I add -Wsparse-all
>> >> then I see the issues mentioned here.
>> >
>> > I wonder why the two of us see different behavior.  Maybe something
>> > changed after 2.6.36?  (I most commonly compile against what Linus has
>> > tagged as v2.6.36.)
>>
>> I'm compiling against net-next but I also sometimes use 2.6.35 and I
>> don't see the warnings there either.  What does your man page say for
>> these warnings?  For example, on mine under -Wcast-to-as, it says that
>> the warnings are not enabled by default and I don't see them.  The
>> other potential source of difference is the flags that the kernel
>> build system passes.  On mine in the Makefile there is:
>> CHECKFLAGS     := -D__linux__ -Dlinux -D__STDC__ -Dunix -D__unix__ \
>>                   -Wbitwise -Wno-return-void $(CF)
>
> My manpage also says that those warnings are not enabled by default.
> I have the same CHECKFLAGS in the kernel Makefile.  I don't have CF set
> to anything in my environment.

Hmm, strange.  It all seems the same as mine.  As you say, the
important thing is to get the issues fixed.




More information about the dev mailing list