Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 13 Oct 1996 00:45:11 +0900 (JST)
From:      Hidetoshi Shimokawa <simokawa@sat.t.u-tokyo.ac.jp>
To:        FreeBSD-gnats-submit@freebsd.org
Subject:   kern/1779: recent ncr.c change doesn't work with ncr875
Message-ID:  <199610121545.AAA05137@uno.sat.t.u-tokyo.ac.jp>
Resent-Message-ID: <199610121550.IAA06389@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         1779
>Category:       kern
>Synopsis:       recent ncr.c change doesn't work with ncr875
>Confidential:   yes
>Severity:       serious
>Priority:       high
>Responsible:    freebsd-bugs
>State:          open
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Oct 12 08:50:01 PDT 1996
>Last-Modified:
>Originator:     Hidetoshi Shimokawa
>Organization:
Univ. of Tokyo
>Release:        FreeBSD 2.2-CURRENT i386
>Environment:

With Tekram DC-390U

>Description:

kernel panics with trap 12 during probe of ncr875.
It is because ncr_getlock is called before np->reg hasn't been initialized.

>How-To-Repeat:

Build current kernel and reboot.

>Fix:
	
- Apply the following patch
or
- Define NCR_IOMAPPED (I have not checked yet)

*** ncr.c.orig  Sat Oct 12 18:49:13 1996
--- ncr.c       Sun Oct 13 00:30:31 1996
***************
*** 3286,3291 ****
--- 3286,3299 ----
        if (!pci_map_mem (config_id, 0x14, &np->vaddr, &np->paddr))
                return;
  
+       /*
+       **      Make the controller's registers available.
+       **      Now the INB INW INL OUTB OUTW OUTL macros
+       **      can be used safely.
+       */
+ 
+       np->reg = (struct ncr_reg*) np->vaddr;
+ 
  #ifdef NCR_IOMAPPED
        /*
        **      Try to map the controller chip into iospace.
***************
*** 3340,3353 ****
  
        np->jump_tcb.l_cmd      = SCR_JUMP;
        np->jump_tcb.l_paddr    = NCB_SCRIPT_PHYS (np, abort);
- 
-       /*
-       **      Make the controller's registers available.
-       **      Now the INB INW INL OUTB OUTW OUTL macros
-       **      can be used safely.
-       */
- 
-       np->reg = (struct ncr_reg*) np->vaddr;
  
        /*
        **  Get SCSI addr of host adapter (set by bios?).
--- 3348,3353 ----

>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199610121545.AAA05137>