Re: [PATCH 0/7] Silence even more W=2 warnings

From: Geert Uytterhoeven
Date: Thu Sep 25 2014 - 03:45:36 EST


On Mon, Sep 22, 2014 at 11:21 PM, Jeff Kirsher
<jeffrey.t.kirsher@xxxxxxxxx> wrote:
>> > Why grep through 100,000 warnings, when we should be fixing the code to
>> > prevent 100,000 warnings. Not saying that the MACRO is the best
>> > solution, it is just a solution, in hopes that it spurs discussions like
>> > this on how to properly fix the warnings. Not a discussion on how to
>> > grep through the warnings and do nothing.
>>
>> There's only one thing I don't understand: why is so bad to grep through
>> the warnings? I mean, sure, fixing them *without* jumping through hoops
>> to do so is the optimal thing. But what's wrong with grepping through
>> them?
>
> Nothing is wrong with grepping for an error, especially when you know
> the error your grepping for. But then again, why grep when it can be
> fixed to begin with? The fact that there are over 100,000
> warnings/errors to begin with is somewhat disconcerting. It makes me
> wonder whether it was due to coding laziness.

Instead of grepping, you can feed the build log to linux-log-summary.
Or when changing a driver, feed the before and after build logs to
linux-log-diff. That way you won't miss the single new warning you've
just introduced.

https://github.com/geertu/linux-scripts

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/