From owner-freebsd-ppc@FreeBSD.ORG Tue Jul 20 02:28:22 2004 Return-Path: Delivered-To: freebsd-ppc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B2E1F16A4CE for ; Tue, 20 Jul 2004 02:28:22 +0000 (GMT) Received: from liberty.onthenet.com.au (liberty.OntheNet.com.au [203.22.124.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2893843D39 for ; Tue, 20 Jul 2004 02:28:22 +0000 (GMT) (envelope-from grehan@freebsd.org) Received: from freebsd.org (CPE-19-111.dsl.OntheNet.net [203.144.19.111]) i6K2SDnP032351; Tue, 20 Jul 2004 12:28:13 +1000 (EST) (envelope-from grehan@freebsd.org) Message-ID: <40FC84D5.4060300@freebsd.org> Date: Tue, 20 Jul 2004 12:35:01 +1000 From: Peter Grehan User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.3.1) Gecko/20030524 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Andrew Gallatin References: <16634.61745.306200.480570@grasshopper.cs.duke.edu> <40FB1C83.3010800@freebsd.org> <16635.59569.415380.622398@grasshopper.cs.duke.edu> In-Reply-To: <16635.59569.415380.622398@grasshopper.cs.duke.edu> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit cc: freebsd-ppc@freebsd.org Subject: Re: kernel not bootable today? X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 20 Jul 2004 02:28:22 -0000 Hi Drew, > OK, now I'm really confused.. I thought I narrowed it down > to your elf_machdep.c changes (which is confusing, as I'm not loading > any modules). I added some printfs, and the resulting kernel boots > just fine. > > Is it possible there is some sort of size or alignment issue? I just comitted a fix. The mtmsr() inlines don't do an isync, since it isn't required for all bits in the msr, most noticeably the EE bit. However, an context-syncing instruction is required when changing the address relocation bits. I'm not exactly sure why putting in printfs or running with syscons didn't expose this, but it should be fixed now. > On a related note, I don't think that the linker file > is still unused in elf_cpu_load_file(). Ah yes. gcc didn't complain about that :-) Also, I found out that elf_cpu_load_file() is called when the kernel is loaded, so there's no need to sync the icache for the entire kernel when it's already been done for the loader. This might shave a microsecond off boot time :-) later, Peter.