From owner-freebsd-sparc64@FreeBSD.ORG Tue Aug 3 03:07:35 2004 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8BA5B16A4CE; Tue, 3 Aug 2004 03:07:35 +0000 (GMT) Received: from ns.kt-is.co.kr (ns.kt-is.co.kr [211.218.149.125]) by mx1.FreeBSD.org (Postfix) with ESMTP id 054CD43D53; Tue, 3 Aug 2004 03:07:35 +0000 (GMT) (envelope-from yongari@kt-is.co.kr) Received: from michelle.kt-is.co.kr (ns2.kt-is.co.kr [220.76.118.193]) (authenticated bits=128) by ns.kt-is.co.kr (8.12.10/8.12.10) with ESMTP id i7336TAh045385 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL); Tue, 3 Aug 2004 12:06:29 +0900 (KST) Received: from michelle.kt-is.co.kr (localhost.kt-is.co.kr [127.0.0.1]) by michelle.kt-is.co.kr (8.12.10/8.12.10) with ESMTP id i7337NiH004781 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 3 Aug 2004 12:07:23 +0900 (KST) (envelope-from yongari@kt-is.co.kr) Received: (from yongari@localhost) by michelle.kt-is.co.kr (8.12.10/8.12.10/Submit) id i7337NIH004780; Tue, 3 Aug 2004 12:07:23 +0900 (KST) (envelope-from yongari@kt-is.co.kr) Date: Tue, 3 Aug 2004 12:07:22 +0900 From: Pyun YongHyeon To: Garance A Drosihn Message-ID: <20040803030722.GA4716@kt-is.co.kr> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.1i X-Filter-Version: 1.11a (ns.kt-is.co.kr) cc: freebsd-sparc64@freebsd.org Subject: Re: Odd problem with ofw_console on Ultra-10 X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: yongari@kt-is.co.kr List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Aug 2004 03:07:35 -0000 On Mon, Aug 02, 2004 at 10:04:31PM -0400, Garance A Drosihn wrote: > Back on July 21/2004, > in the thread "Installworld problem on sparc64?" > I (Garance) wrote: > > > >I did a buildworld/buildkernel/installkernel yesterday, and it > >seemed to work fine. I then went to reboot, to do the installworld. > >If I try to boot in single-user mode, the startup process hangs > >right after: Mounting root from ufs:/dev/ad0a > > > >If I just boot up normally (not bothering with single-user), it > >comes up fine. The line that shows up after "Mounting root" is: > > Pre-seeding PRNG: kickstart. > > > >So I do the normal boot-up, and then type `shutdown' to get into > >single-user mode. Again the machine hangs. I have to power-off > >and back on to get it's attention. > > > >Eventually I booted up multi-user, just killed a few daemons, > >and ran installworld. That seems to have gone okay. I was able > >to reboot after doing the installworld, and it comes up pretty > >much okay (a few minor messages from ntpd, but otherwise nothing > >seems unusual). A `shutdown -r' also works fine. However, if I > >try to do a plain 'shutdown now', the machine again hangs. It > >stops after writing out: > > Stopping cron. > > Shutting down local daemons:. > > Writing entropy file:. > > Terminated > > . > >and never comes up asking me for which shell I want to run (where > >/bin/sh would be the default). Also, now that I have completely > >upgraded, I still can not seem to boot in single-user mode, as I > >described above. > > >My install is working off the regular console (keyboard/monitor > >setup), not a serial-console setup, on an Ultra-10. > Me too. I hate serial cable... > From the onslaught of replies to this (aka "Zero"), I assume I am > still the only person seeing this. Well, I still do not quite > understand all the details of the problem. But after much time, > several blind alleys, and many buildworlds later, I have narrowed > it down to the following commit: > > obrien 2004-06-24 02:57:12 UTC > FreeBSD src repository > > Log: > Better OFW console support on Sun Ultra2 machines. > Ultra2 users may want to set OFWCONS_POLL_HZ to a value of '20'. > I have left default value at '4' as higher values can consume > a more than is acceptable amount of CPU, and we don't have a > consensus yet what is an optimal value. > > Submitted by: Pyun YongHyeon > > Revision Changes Path > 1.11 +1 -0 src/sys/conf/options.sparc64 > 1.25 +17 -9 src/sys/dev/ofw/ofw_console.c > 1.7 +2 -0 src/sys/sparc64/conf/NOTES > > If I take my non-working system, and backout revision 1.25 of > ofw_console.c, then it goes back to working fine in single-user > mode. Before doing that, I also tried adding the line: > > option OFWCONS_POLL_HZ=30 # 20 or more works best on Ultra2 > > (to increase it up from the default of '4'), but that didn't > seem to do any good. I suspect my main problem is that I run > my ultra-10 from a regular keyboard/console, while everyone else > seems to be doing it via a serial console. > > Now that I think I have a way around the single-user problem, I'm > going to try to bring my system up-to-date (minus the above change), > and see how well that works. That'll take me another day, though... > > There is much about the behavior I see from this bug which does > not make sense to me. Given the behavior I see, real issue might > be something pretty simple. Like maybe something that needs to be > reset in /sbin/init . > Here is untested patch(copy & pasted). I thought Peter Grehan already committed it since it also breaks powerpc console. Rebuilding new kernel now and let you know the result. --- ofw_console.c.orig Tue Aug 3 12:02:15 2004 +++ ofw_console.c Tue Aug 3 11:54:27 2004 @@ -129,7 +129,7 @@ ttychars(tp); tp->t_iflag = TTYDEF_IFLAG; tp->t_oflag = TTYDEF_OFLAG; - tp->t_cflag = TTYDEF_CFLAG; + tp->t_cflag = TTYDEF_CFLAG | CLOCAL; tp->t_lflag = TTYDEF_LFLAG; tp->t_ispeed = tp->t_ospeed = TTYDEF_SPEED; ttsetwater(tp); > -- > Garance Alistair Drosehn = gad@gilead.netel.rpi.edu > Senior Systems Programmer or gad@freebsd.org > Rensselaer Polytechnic Institute or drosih@rpi.edu Best regards, Pyun YongHyeon -- Pyun YongHyeon