Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 23 Feb 2003 20:57:24 -0800
From:      Kirk McKusick <mckusick@beastie.mckusick.com>
To:        David Syphers <dsyphers@uchicago.edu>
Cc:        freebsd-current@FreeBSD.ORG
Subject:   Re: BOOT2_UFS=UFS1_ONLY works for today's current 
Message-ID:  <200302240457.h1O4vOFL066334@beastie.mckusick.com>
In-Reply-To: Your message of "Sun, 23 Feb 2003 14:49:52 CST." <200302231449.52766.dsyphers@uchicago.edu> 

next in thread | previous in thread | raw e-mail | index | archive | help
	From: David Syphers <dsyphers@uchicago.edu>
	To: Kirk McKusick <mckusick@beastie.mckusick.com>
	Subject: Re: BOOT2_UFS=UFS1_ONLY works for today's current
	Date: Sun, 23 Feb 2003 14:49:52 -0600
	Cc: freebsd-current@FreeBSD.ORG

	On Sunday 23 February 2003 11:10 am, Richard Arends wrote:
	> On Sun, 23 Feb 2003, David Syphers wrote:
	> > I added BOOT2_UFS=UFS2_ONLY to my make.conf, and my buildworld still
	> > dies in boot2. I'm trying to upgrade from a Feb. 19 -current
	> > (because it's crashing all the time, and I need to enable debugging
	> > stuff). Is there a fix, or would other information be helpful?
	>
	> Same problem over here. I reverted back the last commit on
	> /usr/src/sys/ufs/ffs/fs.h in my source tree and that "fixed" the
	> build. Of course, this is a workaround !!

	Okay, I've verified that the problem is due to rev. 1.39 of
	/usr/src/sys/ufs/ffs/fs.h. Peter Wemm pointed out that the problem
	is not the commit, but gcc's bad handling of 64-bit operations.
	Nonetheless, this commit does break world for a lot of people...
	is there some official solution? The make.conf line only works for
	UFS1 - if it's set to UFS2, buildworld still fails. (Am I correct
	in assuming a 5.0-R install defaults to UFS2?)

	-David

	-- 
	http://www.seektruth.org

	Astronomy and Astrophysics Center
	The University of Chicago

I have committed the following "fix" which reverts to using the
previous broken version of cgbase in ufsread.c. It will work fine
provided that your filesystem is smaller than 1.5Tb.

	Kirk McKusick

Index: ufsread.c
===================================================================
RCS file: /usr/ncvs/src/sys/boot/common/ufsread.c,v
retrieving revision 1.9
diff -c -r1.9 ufsread.c
*** ufsread.c	2002/12/14 19:39:44	1.9
--- ufsread.c	2003/02/24 04:44:50
***************
*** 28,33 ****
--- 28,35 ----
  
  #include <ufs/ufs/dinode.h>
  #include <ufs/ffs/fs.h>
+ #undef cgbase
+ #define cgbase(fs, c)   ((ufs2_daddr_t)((fs)->fs_fpg * (c)))
  
  /*
   * We use 4k `virtual' blocks for filesystem data, whatever the actual

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?200302240457.h1O4vOFL066334>