Date: Mon, 29 May 2006 17:01:01 +0200 (CEST) From: Dan Lukes <dan@obluda.cz> To: FreeBSD-gnats-submit@FreeBSD.org Subject: kern/98091: [ patch ] Makefile style of mfi kernel module broke the WARNS/NO_WERROR logic Message-ID: <200605291501.k4TF11wn077841@kulesh.obluda.cz> Resent-Message-ID: <200605291510.k4TFADBh055327@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 98091 >Category: kern >Synopsis: [ patch ] Makefile style of mfi kernel module broke the WARNS/NO_WERROR logic >Confidential: no >Severity: critical >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon May 29 15:10:12 GMT 2006 >Closed-Date: >Last-Modified: >Originator: Dan Lukes >Release: FreeBSD 6.1-STABLE i386 >Organization: Obludarium >Environment: System: FreeBSD kulesh.obluda.cz 6.1-STABLE FreeBSD 6.1-STABLE #3: Mon May 15 02:41:49 CEST 2006 dan@kulesh.obluda.cz:/usr/obj/usr/src/sys/KULESH i386 src/sys/modules/mfi/Makefile,v 1.1.2.1 2006/04/04 03:24:49 scottl >Description: The forced use of -Werror in CFLAGS made module uncompilable in some environments (when -O3 and requested, for example): /usr/src/sys/modules/mfi/../../dev/mfi/mfi.c: In function fi_attach': @/dev/mfi/mfivar.h:259: warning: inlining failed in call to 'mfi_dequeue_free': --param in line-unit-growth limit reached /usr/src/sys/modules/mfi/../../dev/mfi/mfi.c:434: warning: called from here @/dev/mfi/mfivar.h:259: warning: inlining failed in call to 'mfi_dequeue_free': --param in line-unit-growth limit reached /usr/src/sys/modules/mfi/../../dev/mfi/mfi.c:475: warning: called from here *** Error code 1 >How-To-Repeat: Add -O3 to CFLAGS then try to build the module >Fix: Use WARNS logic included in on mod.sys.mk, not direct setting of CFLAGS It allow the user to customize CFLAGS using the NO_WERROR if necesarry. --- sys/modules/mfi/Makefile.ORIG Mon May 29 16:37:21 2006 +++ sys/modules/mfi/Makefile Mon May 29 16:38:19 2006 @@ -6,7 +6,7 @@ SRCS= mfi.c mfi_pci.c mfi_disk.c SRCS+= opt_mfi.h SRCS+= device_if.h bus_if.h pci_if.h -CFLAGS+= -Wall -Werror +WARNS= 2 # To enable debug output from the driver, uncomment these two lines. #CFLAGS+= -DMFI_DEBUG=2 >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200605291501.k4TF11wn077841>