public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] mpparse.c:231: warning: comparison is always false
@ 2006-09-13  6:50 Jarek Poplawski
  2006-09-13 16:42 ` Dave Jones
       [not found] ` <20060914181754.bd963f6d.akpm@osdl.org>
  0 siblings, 2 replies; 14+ messages in thread
From: Jarek Poplawski @ 2006-09-13  6:50 UTC (permalink / raw)
  To: linux-kernel

Hello,

Probably after 2.6.18-rc6-git1 there is this cc warning: 
"arch/i386/kernel/mpparse.c:231: warning: comparison is
always false due to limited range of data type".
Maybe this patch will be helpful.

Jarek P.


diff -Nurp linux-2.6.18-rc6-git4-/arch/i386/kernel/mpparse.c linux-2.6.18-rc6-git4/arch/i386/kernel/mpparse.c
--- linux-2.6.18-rc6-git4-/arch/i386/kernel/mpparse.c	2006-09-13 00:01:00.000000000 +0200
+++ linux-2.6.18-rc6-git4/arch/i386/kernel/mpparse.c	2006-09-13 00:01:00.000000000 +0200
@@ -228,12 +228,14 @@ static void __init MP_bus_info (struct m
 
 	mpc_oem_bus_info(m, str, translation_table[mpc_record]);
 
+#if 0xFF >= MAX_MP_BUSSES
 	if (m->mpc_busid >= MAX_MP_BUSSES) {
 		printk(KERN_WARNING "MP table busid value (%d) for bustype %s "
 			" is too large, max. supported is %d\n",
 			m->mpc_busid, str, MAX_MP_BUSSES - 1);
 		return;
 	}
+#endif
 
 	if (strncmp(str, BUSTYPE_ISA, sizeof(BUSTYPE_ISA)-1) == 0) {
 		mp_bus_id_to_type[m->mpc_busid] = MP_BUS_ISA;

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2006-09-16  6:19 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-09-13  6:50 [PATCH] mpparse.c:231: warning: comparison is always false Jarek Poplawski
2006-09-13 16:42 ` Dave Jones
2006-09-14  5:36   ` Jarek Poplawski
2006-09-14  6:35     ` Dave Jones
2006-09-14  7:36       ` Jarek Poplawski
2006-09-14 10:12   ` Andi Kleen
2006-09-14 16:08     ` Dave Jones
2006-09-15  6:43       ` Andi Kleen
     [not found] ` <20060914181754.bd963f6d.akpm@osdl.org>
2006-09-15  8:11   ` Jarek Poplawski
2006-09-15  8:23     ` Andrew Morton
2006-09-15  9:08       ` Jarek Poplawski
2006-09-15 15:23       ` Dave Jones
2006-09-15 19:33         ` Andrew Morton
2006-09-16  6:19           ` Andi Kleen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox