From owner-freebsd-stable@FreeBSD.ORG Wed Apr 4 19:46:09 2007 Return-Path: X-Original-To: freebsd-stable@freebsd.org Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id BBEDF16A405 for ; Wed, 4 Apr 2007 19:46:09 +0000 (UTC) (envelope-from nikolas.britton@gmail.com) Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.251]) by mx1.freebsd.org (Postfix) with ESMTP id 785B713C448 for ; Wed, 4 Apr 2007 19:46:09 +0000 (UTC) (envelope-from nikolas.britton@gmail.com) Received: by an-out-0708.google.com with SMTP id c24so375368ana for ; Wed, 04 Apr 2007 12:46:08 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=JsAz5Z55bme6VisT1utISj5T5254q6JC21YOtCAjZTnpjGBFULS7tcUBJQ4Chl74fjBALTzYnSYdvfhvNZk/IRYRqvj56yVuQKhGeX5WXR05zEaV0uO4zvVytWufzpqYQgCkGgNGAbnS415KE3aem/M1wgt85k2qbOg3oWX35dg= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=WjUqqBaT+E8Dd3ul1pCXkmoJlVtNRKwEBW7HPCp+Md/7AdjAHu5B/VbR7P6coUyl8hKGY5wSMAnz4A8UnIpsYYrxrjbuWsc2RDr71XgMa5Jt37+iIHCrvCtVzfvmRRXfYrSbe9p8hoMsnVIhwUePBGc7poVYH0vNWyHMEFwhtfM= Received: by 10.100.57.14 with SMTP id f14mr782510ana.1175715968685; Wed, 04 Apr 2007 12:46:08 -0700 (PDT) Received: by 10.100.109.12 with HTTP; Wed, 4 Apr 2007 12:46:08 -0700 (PDT) Message-ID: Date: Wed, 4 Apr 2007 14:46:08 -0500 From: "Nikolas Britton" To: "Rink Springer" In-Reply-To: <20070404081534.GC2546@rink.nu> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20070404081534.GC2546@rink.nu> Cc: FreeBSD Stable Subject: Re: Porting FreeBSD to a new Architecture? X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 Apr 2007 19:46:09 -0000 On 4/4/07, Rink Springer wrote: > Hi Nikolas, > > On Wed, Apr 04, 2007 at 02:23:44AM -0500, Nikolas Britton wrote: > > I'm looking for documentation that could possibly help me port FreeBSD > > to a new architecture. I'm mainly interested in how you guys did the > > xbox and amd64 ports. i.e. x86 instruction set. > > I can answer the Xbox question for you... basically, what I did was get > a good understanding of how the xbox internals worked (i.e. what the > exact differences are between an ordinary PC and an Xbox). > > Based on this understanding, I patched the Xbox boot loader (Cromwell) > so it could properly load FreeBSD ELF images. Once that was done, I > worked my way up from the first piece of code executed > (that is in i386/i386/locore.s). I crafted some assembly code which > could control the Xbox LED's, and I used this to determine where the > Xbox would crash... > > Once I got the initial machine-dependant stuff out of the way, I created > a console driver so I could see what was going on (which I later on > totally rewrote); and worked my way up from here... Expect a lot of > painstaking debugging in the progress... > Thanks! Can anyone explain how the /usr/src/sys/conf directory works? I'd like to get a better feel of how everything is laid out in sys but I can't find anything in the developer handbook or man hier.