Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 23 Dec 2001 16:27:51 +0100
From:      Thomas Moestl <tmm@FreeBSD.org>
To:        Jamey Wood <Jamey.Wood@Sun.COM>
Cc:        freebsd-sparc@freebsd.org
Subject:   Re: compiling a sparc64 kernel?
Message-ID:  <20011223162751.C659@crow.dom2ip.de>
In-Reply-To: <1483c13c42.13c421483c@smi.sun.com>; from Jamey.Wood@Sun.COM on Sat, Dec 22, 2001 at 07:01:51PM -0800
References:  <1483c13c42.13c421483c@smi.sun.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, 2001/12/22 at 19:01:51 -0800, Jamey Wood wrote:
> I've been trying for a few days to build the sparc64 kernel,
> but kept running into compiler errors (detailed notes below).
> I put in some hacks to get everything to compile, but the resulting 
> kernel doesn't look to get as far into a boot as the binary version I 
> downloaded per tmm's sparc64 README.  Note that I've got an Ultra 1
> (so I understand the boot won't get very far because of no sbus
> support, which is where I'm hoping I might be able to help the port).

Cool!
 
> For me, tmm's kernel results in:
> 
>   /kernel data=0x202fb8+0xdfdc0 syms=[0x8+0x36210+0x8+0x2887c]
>   Hit [Enter] to boot immediately, or any other key for command prompt.
>   Booting [/kernel]...
>   calling autoload
>   nothing to autoload yet.
>   post autoload
>   jumping to kernel entry at 0xc0030000.
>   sparc64_init: mdp=0xc0344000 kmdp=0xc0344000 boothowto=0
>     envp=0xc0342000 end=0x0
>   panic: trap_dmmu_miss: vmspace NULL
>   Debugger("panic")
>   Stopped at      0xc018479c:     ta              %xcc, 1

Hmmm, well, it should get quite a bit farther. Can you please post a
backtrace of that panic?
 
> And my custom-compiled version (with the potentially bogus hacks
> I explain in detail below) gets:
> 
>   /kernel data=0x134ab8+0x4d2b8 syms=[0x8+0x255c0+0x8+0x1b653]
>   Hit [Enter] to boot immediately, or any other key for command prompt.
>   Booting [/kernel]...
>   calling autoload
>   nothing to autoload yet.
>   post autoload
>   jumping to kernel entry at 0xc0028000.
> 
>   RED State Exception
> 
>   TL=0000.0000.0000.0005 TT=0000.0000.0000.0080
>   TPC=0000.0000.c002.4200 TnPC=0000.0000.c002.4204   
>   TSTATE=0000.0099.5800.1506
>   TL=0000.0000.0000.0004 TT=0000.0000.0000.0010
>   TPC=0000.0000.c002.4d50 TnPC=0000.0000.c002.4d54 
>   TSTATE=0000.0099.5804.1406
>   TL=0000.0000.0000.0003 TT=0000.0000.0000.0068
>   TPC=0000.0000.c002.82a8 TnPC=0000.0000.c002.82ac 
>   TSTATE=0000.0099.5800.1506
>   TL=0000.0000.0000.0002 TT=0000.0000.0000.0034
>   TPC=0000.0000.c00e.3dac TnPC=0000.0000.c00e.3db0 
>   TSTATE=0000.0099.5800.1605
>   TL=0000.0000.0000.0001 TT=0000.0000.0000.004e
>   TPC=000
> 
>   <note that this one never gets to the sparc64_init: printf>
> 
> I'm trying to compile from a 5.0-current system (updated buildworld 
> >from yesterday), using tmm's toolchain.
> 
> I'm just looking for an understanding of how to cleanly compile a 
> kernel that'll get as far into the boot as the tmm version.  Thanks in 
> advance for any help.

Jake has committed fixes for these build problems yesterday. If this
problem still persists, you can debug such crashes that drop you back
into the firmware by using e.g. the gdb that is included in the
toolchain archive to find the instruction that caused the trap (the
kernel runs at trap level 1 after the early initialization, so
depending on the point of crash the interesting tpc is stored in the
trap registers for trap level 1 or 2).

	- thomas

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




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