Re: MFS still hosed

1999-05-23 Thread Poul-Henning Kamp

Can somebody please try if this fixes MFS ?

Poul-Henning

Index: ufs/mfs/mfs_vfsops.c
===
RCS file: /home/ncvs/src/sys/ufs/mfs/mfs_vfsops.c,v
retrieving revision 1.63
diff -u -r1.63 mfs_vfsops.c
--- mfs_vfsops.c1999/05/14 20:40:23 1.63
+++ mfs_vfsops.c1999/05/23 09:22:20
@@ -62,6 +62,10 @@
 
 MALLOC_DEFINE(M_MFSNODE, MFS node, MFS vnode private part);
 
+/* XXX: this is bogus, should be (NUMCDEV-1) or use dynamic allocation */
+#define CDEV_MAJOR 255
+#define BDEV_MAJOR 255
+
 #ifdef MFS_ROOT
 static caddr_t mfs_rootbase;   /* address of mini-root in kernel virtual 
memory */
 static u_long  mfs_rootsize;   /* size of mini-root in bytes */
@@ -462,8 +466,6 @@
 mfs_init(vfsp)
struct vfsconf *vfsp;
 {
-   dev_t dev = NODEV;
-   cdevsw_add(dev, mfs_cdevsw, NULL);
-   cdevsw_add_generic(255, major(dev), mfs_cdevsw);
+   cdevsw_add_generic(BDEV_MAJOR, CDEV_MAJOR, mfs_cdevsw);
return (0);
 }
--
Poul-Henning Kamp FreeBSD coreteam member
p...@freebsd.org   Real hackers run -current on their laptop.
FreeBSD -- It will take a long time before progress goes too far!


To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message



Re: MFS still hosed

1999-05-23 Thread Sheldon Hearn


On Sun, 23 May 1999 11:32:27 +0200, Poul-Henning Kamp wrote:

 Can somebody please try if this fixes MFS ?

Do you want your patch applied alongside Luoqi Chen's patch to
kern_conf.c from last week? I've been able to mount_mfs without problems
since then.

Ciao,
Sheldon/


To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message



Re: MFS still hosed

1999-05-23 Thread Poul-Henning Kamp
In message 4478.927463...@axl.noc.iafrica.com, Sheldon Hearn writes:


On Sun, 23 May 1999 11:32:27 +0200, Poul-Henning Kamp wrote:

 Can somebody please try if this fixes MFS ?

Do you want your patch applied alongside Luoqi Chen's patch to
kern_conf.c from last week? I've been able to mount_mfs without problems
since then.

Yes.  The problem here is to get MFS-rootfs to work.

--
Poul-Henning Kamp FreeBSD coreteam member
p...@freebsd.org   Real hackers run -current on their laptop.
FreeBSD -- It will take a long time before progress goes too far!


To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message



Re: MFS still hosed

1999-05-19 Thread Sheldon Hearn


On Wed, 19 May 1999 12:04:54 +1000, Bruce Evans wrote:

 dumping to dev (0, 131089), offset 524288
 dump device bad
 
 The dev_t changes obfuscated it by printing it in %d format instead of
 as part of the dev number in [0x]%x format.

So you reckon that whatever problem is making it imp[ossible for me to
take dumps, it was present before the dev_t changes and I should be
looking elsewhere?

Ciao,
Sheldon.


To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message



Re: MFS still hosed

1999-05-19 Thread Bruce Evans
 dumping to dev (0, 131089), offset 524288
 dump device bad
 
 The dev_t changes obfuscated it by printing it in %d format instead of
 as part of the dev number in [0x]%x format.

So you reckon that whatever problem is making it imp[ossible for me to
take dumps, it was present before the dev_t changes and I should be
looking elsewhere?

dump device bad is printed for d_dump() returning ENXIO, which is
fairly unambiguous.  The new wd driver's d_dump would return ENODEV,
so you must be using the old wd driver.  The old wd_driver's d_dump
only returns ENXIO when the drive doesn't exist or has never been
opened or is not labeled.

Bruce


To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message



Re: MFS still hosed

1999-05-19 Thread Sheldon Hearn


On Wed, 19 May 1999 17:40:50 +1000, Bruce Evans wrote:

 so you must be using the old wd driver.  The old wd_driver's d_dump
 only returns ENXIO when the drive doesn't exist or has never been
 opened or is not labeled.

I'm using the old wd driver (controller wdc in CURRENT). The disk is
labeled and I assume it's opened by swapon when it's configured as a
swap device.

So I'm at a loss as to why I get ENXIO (I did look at that part of the
source, but thought it best to avoid talking in source terms, since I
don't fully understand the meanings of the errors).

Ciao,
Sheldon.


To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message



Re: MFS still hosed

1999-05-18 Thread Sheldon Hearn


On Mon, 17 May 1999 13:02:29 -0400, Luoqi Chen wrote:

 Are you sure you have the latest -current? I committed a fix Friday
 night.

Hi Luoqi,

I remade world and kernel (config -g -r) with yesterday's HEAD and still
get a panic mounting MFS. My kernel config includes MFS but not
MFS_ROOT.

Shout if you want a trace. I haven't provided one here, since I'll need
to copy it down by hand because I'm using the ATA* driver that's still
under development and doesn't support crashdumps.

Ciao,
Sheldon.


To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message



Re: MFS still hosed

1999-05-18 Thread Sheldon Hearn


On Tue, 18 May 1999 08:53:49 +0200, Sheldon Hearn wrote:

 I remade world and kernel (config -g -r) with yesterday's HEAD and still
 get a panic mounting MFS. My kernel config includes MFS but not
 MFS_ROOT.
 
 Shout if you want a trace. I haven't provided one here, since I'll need
 to copy it down by hand because I'm using the ATA* driver that's still
 under development and doesn't support crashdumps.

I think I know why a lot of people _aren't_ seeing this panic: it
doesn't show up if you #undef DEVT_FASCIST in kern/kern_conf.c .

I found this by accident because I can't get a crash dump using the wd
driver. I get 

dumping to dev (0, 131089), offset 524288
dump device bad

Suspecting this whole major/minor/dev_t business, I #undef'd
DEVT_FASCIST and all of a sudden I can't reproduce the panic to test
dumps. ;-)

I'm not whining, I just want to make sure that it's a known issue, not
something that's completely resolved.

Ciao,
Sheldon.


To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message



Re: MFS still hosed

1999-05-18 Thread Bruce Evans
I think I know why a lot of people _aren't_ seeing this panic: it
doesn't show up if you #undef DEVT_FASCIST in kern/kern_conf.c .

#undef DEVT_FASICIST weakens tthe error detection.

I found this by accident because I can't get a crash dump using the wd
driver. I get 

dumping to dev (0, 131089), offset 524288
dump device bad

131089 is the ordinary minor number 0x20011 (slice 2, unit 2, partition
1) (for wd2s1b).  The dev_t changes obfuscated it by printing it in %d
format instead of as part of the dev number in [0x]%x format.  They
should have used %#x format.

Bruce


To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message



Re: MFS still hosed

1999-05-17 Thread Luoqi Chen
 With todays -current, mounting /tmp using
 swap /tmp mfs rw,nosuid,nodev,-s=32768 0 0
 yields a
 
Are you sure you have the latest -current? I committed a fix Friday night.

-lq


To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message



Re: MFS still hosed

1999-05-17 Thread Jos Backus
On Mon, May 17, 1999 at 01:02:29PM -0400, Luoqi Chen wrote:
 Are you sure you have the latest -current? I committed a fix Friday night.

I'm quite positive, because I experimented with a fresh -current/kernel
yesterday.  Changing NUMCDEV from 256 to 255 in kern_conf.c fixes the problem
though. I'm not sure which fix you're alluding to...

-- 
Jos Backus  _/ _/_/_/  Reliability means never
   _/ _/   _/   having to say you're sorry.
  _/ _/_/_/ -- D. J. Bernstein
 _/  _/ _/_/
jos.bac...@nl.origin-it.com  _/_/  _/_/_/  use Std::Disclaimer;


To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message



Re: MFS still hosed

1999-05-17 Thread Jos Backus
On Mon, May 17, 1999 at 03:37:36PM -0400, Luoqi Chen wrote:
 If you don't have `options MFS' in your config file, you will need to
 recompile the mfs kld module.

I know, I did that this evening (did a make world/kernel rebuild around 8pm
CEST):

-r-xr-xr-x  1 root  wheel   12874 May 17 21:20 mfs.ko*

Still crashes without the NUMCDEV adjustment though...

-- 
Jos Backus  _/ _/_/_/  Reliability means never
   _/ _/   _/   having to say you're sorry.
  _/ _/_/_/ -- D. J. Bernstein
 _/  _/ _/_/
jos.bac...@nl.origin-it.com  _/_/  _/_/_/  use Std::Disclaimer;


To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message



MFS still hosed

1999-05-16 Thread Jos Backus
With todays -current, mounting /tmp using
swap /tmp mfs rw,nosuid,nodev,-s=32768 0 0
yields a

Fatal trap 12: page fault while in kernel mode
fault virtual address= 0x9d203590
fault code   = supervisor read, page not present
instruction pointer  = 0x8:0xc016f30c
stack pointer= 0x10:0xc5aa2d70
frame pointer= 0x10:0xc5aa2d9c
code segment = base 0x0, limit 0x, type 0x1b
 = DPL 0, pres 1, def32 1, gran 1
processor eflags = interrupt enabled, resume, IOPL = 0
current process  = 362 (mount_mfs)

Stopped at checkalias+0x13c: movl cdevsw(%eax),%eax

%eax contains 0xdcfba6d0

This line in checkalias() in vfs_subr.c seems to be the culprit:

1488:   56  pushl  %esi
1489:   e8 fc ff ff ff  call   148a checkalias+0x12e
148e:   8b 04 85 00 00  movl   0x0(,%eax,4),%eax
1493:   00 00
1495:   c1 e0 02shll   $0x2,%eax
=  1498:   8b 80 00 00 00  movl   0x0(%eax),%eax
149d:   00
149e:   89 45 e4movl   %eax,0xffe4(%ebp)

(I'm not sure yet which source line this section corresponds to :-)

Anyone else seen this?

-- 
Jos Backus  _/ _/_/_/  Reliability means never
   _/ _/   _/   having to say you're sorry.
  _/ _/_/_/ -- D. J. Bernstein
 _/  _/ _/_/
jos.bac...@nl.origin-it.com  _/_/  _/_/_/  use Std::Disclaimer;


To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message



Re: MFS still hosed

1999-05-16 Thread Doug White
On Sun, 16 May 1999, Jos Backus wrote:

 With todays -current, mounting /tmp using
 swap /tmp mfs rw,nosuid,nodev,-s=32768 0 0
 yields a
 
 Fatal trap 12: page fault while in kernel mode
 fault virtual address= 0x9d203590

I've been getting this for a week now. :(  Luoqui Chen suggested bumping
NUMCDEV in src/sys/kern/kern_conf.c to 255 to get around it, and a couple
of people had success, including myself. 

I've filed PR kern/11737 with the fix.

Doug White   
Internet:  dwh...@resnet.uoregon.edu| FreeBSD: The Power to Serve
http://gladstone.uoregon.edu/~dwhite| www.freebsd.org



To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message



Re: MFS still hosed

1999-05-16 Thread Jos Backus
On Sun, May 16, 1999 at 01:36:44PM -0700, Doug White wrote:
 I've been getting this for a week now. :(  Luoqui Chen suggested bumping
 NUMCDEV in src/sys/kern/kern_conf.c to 255 to get around it, and a couple
 of people had success, including myself. 

I'll do that then. Thanks!

Groetjes,
-- 
Jos Backus  _/ _/_/_/  Reliability means never
   _/ _/   _/   having to say you're sorry.
  _/ _/_/_/ -- D. J. Bernstein
 _/  _/ _/_/
jos.bac...@nl.origin-it.com  _/_/  _/_/_/  use Std::Disclaimer;


To Unsubscribe: send mail to majord...@freebsd.org
with unsubscribe freebsd-current in the body of the message