From darrylo@hpnmhjw.sr.hp.com  Tue Aug 27 22:37:00 1996
Received: from hp.com (hp.com [15.255.152.4])
          by freefall.freebsd.org (8.7.5/8.7.3) with ESMTP id WAA00970
          for <FreeBSD-gnats-submit@freebsd.org>; Tue, 27 Aug 1996 22:37:00 -0700 (PDT)
Received: from srmail.sr.hp.com by hp.com with ESMTP
	(1.37.109.16/15.5+ECS 3.3) id AA215730618; Tue, 27 Aug 1996 22:36:59 -0700
Received: from hpnmhjw.sr.hp.com by srmail.sr.hp.com with ESMTP
	(1.37.109.16/15.5+ECS 3.3) id AA143290618; Tue, 27 Aug 1996 22:36:58 -0700
Received: from mina.sr.hp.com by hpnmhjw.sr.hp.com with SMTP
	(1.37.109.16/15.5+ECS 3.3) id AA065250617; Tue, 27 Aug 1996 22:36:57 -0700
Message-Id: <199608280536.AA065250617@hpnmhjw.sr.hp.com>
Date: Tue, 27 Aug 1996 22:36:57 -0700
From: darrylo@sr.hp.com
Sender: darrylo@hpnmhjw.sr.hp.com
Reply-To: darrylo@sr.hp.com
To: FreeBSD-gnats-submit@freebsd.org
Subject: ncrcontrol won't work with FAILSAFE kernel
X-Send-Pr-Version: 3.2

>Number:         1547
>Category:       bin
>Synopsis:       ncrcontrol won't work with FAILSAFE kernel
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    se
>State:          closed
>Quarter:
>Keywords:
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Aug 27 22:40:01 PDT 1996
>Closed-Date:    Sun Dec 22 08:34:14 PST 1996
>Last-Modified:  Sun Dec 22 08:38:11 PST 1996
>Originator:     Darryl Okahata
>Release:        FreeBSD 2.2-960801-SNAP i386
>Organization:
Home
>Environment:

	NCR-815-based SCSI controller and FreeBSD 2.2-960801-SNAP kernel
	with the "FAILSAFE" kernel option enabled.

>Description:

	If you have an NCR-based SCSI controller, and if your kernel is
	compiled with the "FAILSAFE" kernel option, the "ncrcontrol"
	program will fail with the message:

		ncrcontrol: incompatible with kernel. Rebuild!

	The program outputs this message because:

		ncr_version != kernel_version

	This is due to the size of the "struct ncb" structure having
	different sizes when FAILSAFE is defined.

	If FAILSAFE is not compiled into the kernel, there is no
	problem.

>How-To-Repeat:

	Assuming an NCR SCSI controller is present, run:

		ncrcontrol -i

>Fix:
	
	(Workaround.)  Hand compile ncrcontrol with -DFAILSAFE.

	The real fix is a bummer, and I'll leave that for people with
	more free time on their hands.  ;-)
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->feedback 
State-Changed-By: scrappy 
State-Changed-When: Tue Oct 22 22:21:47 PDT 1996 
State-Changed-Why:  

Confirm Status: ncrcontrol won't work with FAILSAFE kernel 

State-Changed-From-To: feedback->closed 
State-Changed-By: scrappy 
State-Changed-When: Tue Oct 22 22:47:11 PDT 1996 
State-Changed-Why:  

Originator Confirmed Closure 
State-Changed-From-To: closed->open 
State-Changed-By: scrappy 
State-Changed-When: Wed Oct 23 12:39:42 PDT 1996 
State-Changed-Why:  

It's obviously still broken.   A struct depends on MAX_TARGET which 
depends on SCSI_NCR_DFLT_TAGS which depends on FAILSAFE.  I tested 
this.  It is broken :-). 

I have to use the equivalent of FAILSAFE here for a Toshiba MK547FB 
boot drive, but I didn't notice the problem because I changed the 
source to define SCSI_NCR_DEFLT_TAGS as 0 before FAILSAFE existed, 
and have never used FAILSAFE. 

Bruce 

Responsible-Changed-From-To: freebsd-bugs->se 
Responsible-Changed-By: scrappy 
Responsible-Changed-When: Mon Nov 4 06:49:11 PST 1996 
Responsible-Changed-Why:  
working on fixes for this and a couple of other problems 
State-Changed-From-To: open->closed 
State-Changed-By: se 
State-Changed-When: Sun Dec 22 08:34:14 PST 1996 
State-Changed-Why:  
Fixed in rev. 1.86 of /sys/pci/ncr.c: 
FAILSAFE does no longer define MAX_LUN, which caused a data structure  
to become incompatible between the kernel and ncrcontrol, before. 
>Unformatted:
