Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 9 Jan 2003 16:51:36 -0800
From:      Marcel Moolenaar <marcel@xcllnt.net>
To:        Gordon Tetlow <gordont@gnf.org>
Cc:        current@FreeBSD.org
Subject:   Re: HEADS UP: VFS changes breaks GPT
Message-ID:  <20030110005136.GA1425@athlon.pn.xcllnt.net>
In-Reply-To: <20030109235716.GA53114@roark.gnf.org>
References:  <20030109091230.GA4320@dhcp01.pn.xcllnt.net> <20030109235716.GA53114@roark.gnf.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Jan 09, 2003 at 03:57:16PM -0800, Gordon Tetlow wrote:
> On Thu, Jan 09, 2003 at 01:12:30AM -0800, Marcel Moolenaar wrote:
> > Gang,
> > 
> > GPT based systems are unable to mount the root file system. I
> > haven't had the time to dig into this, but we must be making
> > assumptions we previously didn't make. In any case ia64 is
> > hosed. More to come...
> 
> I'll own up to this one. I forgot about alignment issues on non-i386
> platforms when I committed rev 1.36 of src/sys/ufs/ffs/fs.h. I've
> committed the fix that marcel has provided. If there are anymore
> troubles, please don't hesitate in reverting to rev 1.35.

Nah... :-)

Jake has a good point and I've got a dotless i, so what about
the following patch to dot the, well, i:

\begin{patch}
Index: fs.h
===================================================================
RCS file: /home/ncvs/src/sys/ufs/ffs/fs.h,v
retrieving revision 1.37
diff -u -r1.37 fs.h
--- fs.h	9 Jan 2003 23:53:30 -0000	1.37
+++ fs.h	10 Jan 2003 00:50:17 -0000
@@ -312,7 +312,7 @@
 	u_char	 fs_fsmnt[MAXMNTLEN];	/* name mounted on */
 	u_char	 fs_volname[MAXVOLLEN];	/* volume name */
 	u_int64_t fs_swuid;		/* system-wide uid */
-	int32_t  fs_pad;		/* padding for non-i386 */
+	int32_t  fs_pad;		/* due to alignment of fs_swuid */
 /* these fields retain the current block allocation info */
 	int32_t	 fs_cgrotor;		/* last cg searched */
 	void 	*fs_ocsp[NOCSPTRS];	/* padding; was list of fs_cs buffers */@@ -350,6 +350,11 @@
 					/* old fs_rotbloff */
 	int32_t	 fs_magic;		/* magic number */
 };
+
+/* Sanity checking. */
+#ifdef CTASSERT
+CTASSERT(sizeof(struct fs) == 1376);
+#endif
 
 /*
  * Filesystem identification
\end{patch}

Note that the padding is not specific to non-i386. The reason or
cause of the padding is specific to non-i386, because it's due to
the alignment requirements of fs_swuid. A nit, but will probably
avoid some confusion..

-- 
 Marcel Moolenaar	  USPA: A-39004		 marcel@xcllnt.net

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




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