Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1423197AbXBHQdl (ORCPT ); Thu, 8 Feb 2007 11:33:41 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1423168AbXBHQdk (ORCPT ); Thu, 8 Feb 2007 11:33:40 -0500 Received: from smtp.osdl.org ([65.172.181.24]:48784 "EHLO smtp.osdl.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1423197AbXBHQdk (ORCPT ); Thu, 8 Feb 2007 11:33:40 -0500 Date: Thu, 8 Feb 2007 08:33:30 -0800 (PST) From: Linus Torvalds To: Jeff Garzik cc: Linux Kernel Mailing List , Andrew Morton Subject: Re: somebody dropped a (warning) bomb In-Reply-To: <45CB3B28.60102@garzik.org> Message-ID: References: <45CB3B28.60102@garzik.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2178 Lines: 53 On Thu, 8 Feb 2007, Jeff Garzik wrote: > > Just did a pull for the first time since 2.6.20, and a /megaton/ of new > warnings have appeared, on Fedora Core 6/x86-64 "make allyesconfig". That was due to the Makefile rule breakage. Hopefully it now _really_ is fixed. The CFLAGS += $(call cc-option,-Wno-pointer-sign,) part effectively got dropped. > All of the new warnings spew appear to be "pointers differ in signedness" > warning. Granted, we should care about these The thing is, I'm _really_ sad we have to use that -Wno-pointer-sign thing. It's a real and valid warning. It finds really ugly code issues (unlike a lot of the other things). So it got dropped by mistake, but that is one warning that I'd actually like to resurrect (unlike a lot of other gcc warnings that I just think are crap to begin with). However, we've got a metric shitload of code that passes in pointers to the wrong sign, so a lot of it would involve mindless changes that are likely to break real things. And the thing is, sometimes -Wpointer-sign-compare is just horribly broken. For example, you cannot write a "strlen()" that doesn't complain about "unsigned char *" vs "char *". And that is just a BUG. I'm continually amazed at how totally clueless some gcc warnings are. You'd think that the people writing them are competent. And then sometimes they show just how totally incompetent they are, by making it impossible to use "unsigned char" arrays together with standard functions. So a _lot_ of the warnings are real. But with no way to shut up the ones that aren't, it sadly doesn't matter one whit ;( (And adding casts is just much worse than shutting up the warning entirely) There should be a rule about warnings: if you can't shut up stylistic warnings on a site-by-site level without adding horribly syntactic stuff that is worse than what the warning is all about, the warning shouldn't exist. Linus - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/