From owner-freebsd-current Sun Jan 4 05:30:24 1998 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id FAA27562 for current-outgoing; Sun, 4 Jan 1998 05:30:24 -0800 (PST) (envelope-from owner-freebsd-current) Received: from godzilla.zeta.org.au (godzilla.zeta.org.au [203.2.228.19]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id FAA27550 for ; Sun, 4 Jan 1998 05:30:13 -0800 (PST) (envelope-from bde@godzilla.zeta.org.au) Received: (from bde@localhost) by godzilla.zeta.org.au (8.8.7/8.8.7) id AAA03268; Mon, 5 Jan 1998 00:26:04 +1100 Date: Mon, 5 Jan 1998 00:26:04 +1100 From: Bruce Evans Message-Id: <199801041326.AAA03268@godzilla.zeta.org.au> To: freebsd-current@FreeBSD.ORG, shimon@simon-shapiro.org Subject: Re: Interesting Panic in ffs Sender: owner-freebsd-current@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk >Having done the following newfs: > >newfs -b 65536 -c 128 -f 32768 /dev/rsd24s1a > >I have gotten this panic when trying to mount the filesystem: > >Page fault while in kernel mode newfs creates bad file systems for fragment sizes > SBSIZE = 8192. Try this fix. It seems to work here. Bruce diff -c2 mkfs.c~ mkfs.c *** mkfs.c~ Sun Sep 14 15:22:31 1997 --- mkfs.c Mon Jan 5 00:10:08 1998 *************** *** 502,505 **** --- 502,507 ---- sblock.fs_postblformat = FS_DYNAMICPOSTBLFMT; sblock.fs_sbsize = fragroundup(&sblock, sizeof(struct fs)); + if (sblock.fs_sbsize > SBSIZE) + sblock.fs_sbsize = SBSIZE; if (sblock.fs_ntrak == 1) { sblock.fs_cpc = 0; *************** *** 533,536 **** --- 535,540 ---- } sblock.fs_sbsize = fragroundup(&sblock, totalsbsize); + if (sblock.fs_sbsize > SBSIZE) + sblock.fs_sbsize = SBSIZE; /* * calculate the available blocks for each rotational position