Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 15 Nov 2001 15:40:58 -0700
From:      "Kenneth D. Merry" <ken@kdm.org>
To:        Poul-Henning Kamp <phk@critter.freebsd.dk>
Cc:        Dirk Froemberg <dirk@FreeBSD.ORG>, stable@FreeBSD.ORG
Subject:   Re: kernel panic if using SCSI CDROM as root device
Message-ID:  <20011115154058.A35230@panzer.kdm.org>
In-Reply-To: <5832.1005863617@critter.freebsd.dk>; from phk@critter.freebsd.dk on Thu, Nov 15, 2001 at 11:33:37PM %2B0100
References:  <20011115152226.A35113@panzer.kdm.org> <5832.1005863617@critter.freebsd.dk>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Nov 15, 2001 at 23:33:37 +0100, Poul-Henning Kamp wrote:
> In message <20011115152226.A35113@panzer.kdm.org>, "Kenneth D. Merry" writes:
> >On Thu, Nov 15, 2001 at 23:11:16 +0100, Dirk Froemberg wrote:
> >> Hi Kenneth!
> >> 
> >> On Thu, Nov 15, 2001 at 02:56:15PM -0700, Kenneth D. Merry wrote:
> >> > [...]
> >> > Can you find out what line of code in dsioctl is causing the problem?
> >> > 
> >> > If you built a debug kernel, you can do the following:
> >> > 
> >> > gdb -k kernel.debug
> >> > list *(dsioctl+0x42)
> >> > 
> >> > That should indicate which line in dsioctl is blowing up.
> >> 
> >> Yes, of course:
> >> 
> >> % gdb -k kernel.debug
> >> GNU gdb 4.18
> >> [...]
> >> (kgdb) list *(dsioctl+0x42)
> >> 0xc01b5216 is in dsioctl (/usr/src/sys/kern/subr_diskslice.c:357).
> >> 352		struct partition *pp;
> >> 353	
> >> 354		slice = dkslice(dev);
> >> 355		ssp = *sspp;
> >> 356		sp = &ssp->dss_slices[slice];
> >> 357		lp = sp->ds_label;
> >> 358		switch (cmd) {
> >> 359	
> >> 360		case DIOCGDVIRGIN:
> >> 361			lp = (struct disklabel *)data;
> >> (kgdb) 
> >> 
> >> 	Regards Dirk
> >
> >Thanks!
> >
> >Poul-Henning, any idea why this might be blowing up?  It looks like the
> >slice pointer isn't initialized for some reason.
> 
> Has the disk actually been opened ?

Good question, I dunno.

You'd figure this stuff would work, since the CD installation process boots
off of a CD.

But of course Dirk may be using the new El Torito boot code that enables
non-emulation booting.  (i.e. you're not booting off of a floppy image
anymore)  Is that what you're using Dirk?

That would change things around somewhat, since the ISO9660 code would now
be running the root device where before it was probably the msdos
filesystem code.

> I have fixed some instances where some of the boot-glue would issue
> ioctl' calls to disks which were not yet opened, that used to work,
> despite being a gross error.

Yeah, I can certainly see how that could cause problems.

Ken
-- 
Kenneth Merry
ken@kdm.org

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-stable" in the body of the message




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