From mboxrd@z Thu Jan 1 00:00:00 1970 From: Adrian Bunk Subject: [patch] sym53c8xx_2 uses SYM_MEM_CLUSTER_SHIFT before its #define'd Date: Sat, 7 Feb 2004 21:30:58 +0100 Sender: linux-scsi-owner@vger.kernel.org Message-ID: <20040207203058.GA7388@fs.tum.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from hermes.fachschaften.tu-muenchen.de ([129.187.202.12]:55254 "HELO hermes.fachschaften.tu-muenchen.de") by vger.kernel.org with SMTP id S265795AbUBGUbG (ORCPT ); Sat, 7 Feb 2004 15:31:06 -0500 Content-Disposition: inline List-Id: linux-scsi@vger.kernel.org To: matthew@wil.cx, linux-scsi@vger.kernel.org, James.Bottomley@SteelEye.com, linux-kernel@vger.kernel.org When compiling 2.6.2-mm1 (this problem doesn't seem to be specific to -mm) with -Wundef I got many of the following warnings: <-- snip --> ... In file included from drivers/scsi/sym53c8xx_2/sym_glue.h:446, from drivers/scsi/sym53c8xx_2/sym_fw.c:56: drivers/scsi/sym53c8xx_2/sym_hipd.h:186:30: warning: "SYM_MEM_CLUSTER_SIZE" is not defined ... <-- snip --> This seems to be a bug: SYM_MEM_CLUSTER_SIZE is used before it's #define'd. The patch below fixes this issue. cu Adrian --- linux-2.6.2-mm1/drivers/scsi/sym53c8xx_2/sym_hipd.h.old 2004-02-07 21:20:04.000000000 +0100 +++ linux-2.6.2-mm1/drivers/scsi/sym53c8xx_2/sym_hipd.h 2004-02-07 21:20:54.000000000 +0100 @@ -171,6 +171,15 @@ #define SYM_CONF_MIN_ASYNC (40) /* + * Shortest memory chunk is (1<