Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 8 Oct 1995 14:53:10 -0400
From:      Mark Starner <starner@clark.net>
To:        "'bugs@freebsd.org'" <bugs@freebsd.org>
Cc:        "'moriya@ifi.unicamp.br'" <moriya@ifi.unicamp.br>
Subject:   Bug accessing /dev/cd1
Message-ID:  <01BA958D.CA1F82A0@ras2.HAN.UnisysGSG.COM>

next in thread | raw e-mail | index | archive | help
Was a fix ever found for this bug? I had the same problem, and sent my system info to
(what were then) the appropriate people. I just loaded up the current snapshot 
and have the same problem... a panic as below, at the same place when accessing cd1.
(actually it may be worse, it used to never crash with cd0, now it does sometimes)

FYI, I am running with a AHA-3940, a NEC 3xi and Plextor 4-Plex CD.

Mark

>From:             Alexandre Moriya - esp <moriya@ifi.unicamp.br>
Subject:          KERNEL BUG !!!!
To:               bugs@FreeBSD.org
Date sent:        Fri, 11 Aug 1995 11:25:24 -0300 (BSC)
Copies to:        hackers@FreeBSD.org, questions@FreeBSD.org,
        moriya@ifi.unicamp.br (Alexandre Moriya - esp)

THIS mail has been sent to {bugs,hackers,questions}@FreeBSD.org

Hi all,

I don't if it is the right place for this question. If it isn't,
could you please send it to the right people ?

I believe it is a KERNEL BUG.

I have the following configuration:

	1 PC/FreeBSD-2.0.5
	1 Seven CD Tower (SCSI Express Tower / MDI)
	1 Adaptec 1542CF ISA-to-SCSI adaptor

The 1542CF adaptor is configured as the kernel messages bellow says:

Aug  9 12:54:30 by-tor /kernel: aha0: AHA-1542CF BIOS v2.01-VB.0, enabling mai
lbox, enabling residuals
Aug  9 12:54:30 by-tor /kernel: aha0: reading board settings, dma=5 int=11
 (bus speed defaulted)
Aug  9 12:54:30 by-tor /kernel: aha0 at 0x330-0x333 irq 11 drq 5 on isa
Aug  9 12:54:30 by-tor /kernel: aha0 waiting for scsi devices to settle
Aug  9 12:54:30 by-tor /kernel: (aha0:0:0): "MDI SE53CD 0925" type 5 removable
 SCSI 2
Aug  9 12:54:30 by-tor /kernel: cd0(aha0:0:0): CD-ROM 
Aug  9 12:54:30 by-tor /kernel: cd0(aha0:0:0): NOT READY asc:3a,0 Medium
not present
Aug  9 12:54:30 by-tor /kernel: can't get the size
Aug  9 12:54:31 by-tor /kernel: 
Aug  9 12:54:31 by-tor /kernel: (aha0:1:0): "MDI SE53CD 0925" type 5 removable
 SCSI 2
Aug  9 12:54:31 by-tor /kernel: cd1(aha0:1:0): CD-ROM 
Aug  9 12:54:31 by-tor /kernel: cd1(aha0:1:0): NOT READY asc:3a,0 Medium
not present
Aug  9 12:54:31 by-tor /kernel: can't get the size
Aug  9 12:54:31 by-tor /kernel: 
Aug  9 12:54:31 by-tor /kernel: (aha0:2:0): "MDI SE53CD 0925" type 5 removable
 SCSI 2
Aug  9 12:54:32 by-tor /kernel: cd2(aha0:2:0): CD-ROM 
Aug  9 12:54:32 by-tor /kernel: cd2(aha0:2:0): NOT READY asc:3a,0 Medium
not present
Aug  9 12:54:32 by-tor /kernel: can't get the size
Aug  9 12:54:32 by-tor /kernel: 
Aug  9 12:54:32 by-tor /kernel: (aha0:3:0): "MDI SE53CD 0925" type 5 removable
 SCSI 2
Aug  9 12:54:32 by-tor /kernel: cd3(aha0:3:0): CD-ROM cd present.[183255 x 204
8 byte records]
Aug  9 12:54:32 by-tor /kernel: (aha0:4:0): "MDI SE53CD 0925" type 5 removable
 SCSI 2
Aug  9 12:54:33 by-tor /kernel: cd4(aha0:4:0): CD-ROM 
Aug  9 12:54:33 by-tor /kernel: cd4(aha0:4:0): NOT READY asc:3a,0 Medium
not present
Aug  9 12:54:33 by-tor /kernel: can't get the size
Aug  9 12:54:33 by-tor /kernel: 
Aug  9 12:54:33 by-tor /kernel: (aha0:5:0): "MDI SE53CD 0925" type 5 removable
 SCSI 2
Aug  9 12:54:33 by-tor /kernel: cd5(aha0:5:0): CD-ROM 
Aug  9 12:54:33 by-tor /kernel: cd5(aha0:5:0): NOT READY asc:3a,0 Medium
not present
Aug  9 12:54:33 by-tor /kernel: can't get the size
Aug  9 12:54:33 by-tor /kernel: 

Aug  9 12:54:34 by-tor /kernel: (aha0:6:0): "MDI SE53CD 0925" type 5 removable
 SCSI 2
Aug  9 12:54:34 by-tor /kernel: cd6(aha0:6:0): CD-ROM 
Aug  9 12:54:34 by-tor /kernel: cd6(aha0:6:0): NOT READY asc:3a,0 Medium not p
resent
Aug  9 12:54:34 by-tor /kernel: can't get the size
Aug  9 12:54:34 by-tor /kernel: 


My problem is that I mounted a CD-ROM from the first device (/dev/cd0a)
in the directory /0 using "mount_cd9660 /dev/cd0a /0" or by a corresponding
line in the /fstab.

The CDROM has about 100MB of info in the root dir. When I try to "cat *" the /0 directory,
 everything is fine.

Everything works well when I mount the same CDROM in the /dev/cdNa, where N=[0,5].
(I have created all devices using "cd /dev; sh MAKEDEV cdN;" where N=[0,6])
It does not made any difference if I used /dev/cdNc instead of /dev/cdNa...

The "bug" appears when I mount the CDROM in the /dev/cd6a (the last CDROM device).
I used "mount_cd9660 /dev/cd6a /0 ; cd /0 ; cat *" and a few seconds later
I received the following message:

Fatal trap 12: page fault while in kernel mode

fault virtual address		= 0x10a
fault code			= supervisor read, page not present
instruction pointer		= 0x8:0xf011efdc
code segment			= base 0x0, limit 0xfffff, type 0x1b
processor eflags		= interrupt enabled, resume IOPL=0
current process			= 133(cat)
interrupt mask			= bio
panic: page fault

syncing disks..................... 4 4 4 4 4 4 4 4 4 giving up
Automaitc reboot in 15 seconds - press a key on the console to abort

-------

Is it easy to repair ? I took a look in the /usr/src/sys/i386/i386 dir and
found something, but nothing that lead me to any conclusion. I have seen
something concerning about this in the /usr/src/sys/scsi dir, too.

Can you help me ? Any tips ?
We here at CCJDR intend to use up to 3 "Seven CD Tower" but will
the kernel accept more than 6 devices (0-5) ? We want to use 21 !!!

Sorry for my poor english :-( If you have any doubt, ask me please.
We should have a solution to this problem as early as possible.

I believe that , if it is a kernel bug, it should be repaired before
the 2.1 release, isn't it ?

Finnaly, I'd like to thank you for the great work in the FreeBSD.
It'is working very nice !!!

	BYE (Ate mais)


-- 

Alexandre Moriya			(RA 910061)
Centro de Computacao John David Rogers 	(CCJDR)
Instituto de Fisica Gleb Wataghin	(IFGW)
Universidade Estadual de Campinas	(UNICAMP)
Campinas - SP - Brasil
e-mail:
	moriya@ifi.unicamp.br
	moriya@dcc.unicamp.br

--------------------
>From:             J Wunsch <j@uriah.heep.sax.de>
Subject:          Re: KERNEL BUG !!!!
To:               moriya@ifi.unicamp.br (Alexandre Moriya - esp)
Date sent:        Mon, 14 Aug 1995 20:30:30 +0200 (MET DST)
Copies to:        joerg_wunsch@uriah.heep.sax.de, starner@clark.net, lenzi@mtm.ufsc.br,
        davidg@freebsd.org (David Greenman)
Send reply to:    joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch)

As Alexandre Moriya - esp wrote:

> > > fault virtual address		= 0x10a
> This number is variable. Each time the bug happens we have
> a different number.

Understandable.  It's a bogus address.

> > > instruction pointer		= 0x8:0xf011efdc
> OOOPS !!! The number is wrong.
> The correct number is 0xf012135c

> > nm /kernel | sort | more
> Ok. the new result is:
> f0121314 T _incore
> f01213b0 T _inmem

The bug happens in line 694 of vfs_bio.c:

   686  incore(struct vnode * vp, daddr_t blkno)
   687  {
   688          struct buf *bp;
   689          struct bufhashhdr *bh;
   690  
   691          int s = splbio();
   692  
   693          bh = BUFHASH(vp, blkno);
   694          bp = bh->lh_first;
                     ^^^^

Apparently, the BUFHASH macro yielded a bogus number that was an
invalid address (but not zero, since you're writing the number is
different each time).

I'm Cc'ing David Greenman, i think he's the one who would best
understand what happens here.

-- 
cheers, J"org

joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/
Never trust an operating system you don't have sources for. ;-)




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