Subject: kern/2364: [aha.c and wds.c] mbi.stat is initialized wrong type of constant.
To: None <gnats-bugs@NetBSD.ORG>
From: None <enami@ba2.so-net.or.jp>
List: netbsd-bugs
Date: 05/02/1996 20:27:21
>Number:         2364
>Category:       kern
>Synopsis:       mbi.stat is initalized constant for mbo.cmd.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    kern-bug-people (Kernel Bug People)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu May  2 07:35:06 1996
>Last-Modified:
>Originator:     enami tsugutomo
>Organization:
>Release:        NetBSD-current 1996 Apr. 20
>Environment:
System: NetBSD pavlov 1.1B NetBSD 1.1B (PAVLOV) #13: Sat Apr 13 00:47:47 JST 1996 enami@pavlov:/a/NetBSD/src.960406/sys/arch/i386/compile/PAVLOV i386


>Description:
	In source file sys/dev/isa/aha.c and sys/dev/isa/wds.c,
	mbi.stat is initialized constant for mbo.cmd.
>How-To-Repeat:
	Read the source.  It is the only way to find the bug, because the
	generated object code is quite correct.
>Fix:
Index: aha.c
===================================================================
RCS file: /a/cvsroot/NetBSD/sys/dev/isa/aha.c,v
retrieving revision 1.1.1.3
diff -u -r1.1.1.3 aha.c
--- aha.c	1996/04/30 18:07:37	1.1.1.3
+++ aha.c	1996/05/02 11:14:17
@@ -995,7 +995,7 @@
 	 */
 	for (i = 0; i < AHA_MBX_SIZE; i++) {
 		wmbx->mbo[i].cmd = AHA_MBO_FREE;
-		wmbx->mbi[i].stat = AHA_MBO_FREE;
+		wmbx->mbi[i].stat = AHA_MBI_FREE;
 	}
 	wmbx->cmbo = wmbx->tmbo = &wmbx->mbo[0];
 	wmbx->tmbi = &wmbx->mbi[0];
Index: wds.c
===================================================================
RCS file: /a/cvsroot/NetBSD/sys/dev/isa/wds.c,v
retrieving revision 1.1.1.2
diff -u -r1.1.1.2 wds.c
--- wds.c	1996/04/30 18:07:35	1.1.1.2
+++ wds.c	1996/05/02 11:24:52
@@ -857,7 +857,7 @@
 	 */
 	for (i = 0; i < WDS_MBX_SIZE; i++) {
 		wmbx->mbo[i].cmd = WDS_MBO_FREE;
-		wmbx->mbi[i].stat = WDS_MBO_FREE;
+		wmbx->mbi[i].stat = WDS_MBI_FREE;
 	}
 	wmbx->cmbo = wmbx->tmbo = &wmbx->mbo[0];
 	wmbx->tmbi = &wmbx->mbi[0];
>Audit-Trail:
>Unformatted: