From owner-freebsd-arm@FreeBSD.ORG Tue Dec 25 20:37:35 2012 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id ED9BAE3E for ; Tue, 25 Dec 2012 20:37:35 +0000 (UTC) (envelope-from gonzo@id.bluezbox.com) Received: from id.bluezbox.com (id.bluezbox.com [88.198.91.248]) by mx1.freebsd.org (Postfix) with ESMTP id 878428FC17 for ; Tue, 25 Dec 2012 20:37:35 +0000 (UTC) Received: from [207.6.254.8] (helo=[192.168.1.67]) by id.bluezbox.com with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.77 (FreeBSD)) (envelope-from ) id 1TnbFd-0005LA-EF; Tue, 25 Dec 2012 12:37:27 -0800 Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 6.2 \(1499\)) Subject: Re: Raspberry Pi questions From: Oleksandr Tymoshenko In-Reply-To: <1356466883.1144.8.camel@revolution.hippie.lan> Date: Tue, 25 Dec 2012 12:37:06 -0800 Content-Transfer-Encoding: quoted-printable Message-Id: <08125E73-C46A-4DDF-BFD8-59D5B86136B8@bluezbox.com> References: <1356466883.1144.8.camel@revolution.hippie.lan> To: Ian Lepore X-Mailer: Apple Mail (2.1499) Sender: gonzo@id.bluezbox.com X-Spam-Level: -- X-Spam-Report: Spam detection software, running on the system "id.bluezbox.com", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see The administrator of that system for details. Content preview: On 2012-12-25, at 12:21 PM, Ian Lepore wrote: > I got my RPi running this morning, more or less. I used the boot > partition from the latest image at http://www.peach.ne.jp/archives/rpi/ > but I'm loading my own custom built kernel and world. I have a few > questions... > > Can I get ubldr to load a kernel using tftp, bootp, etc? [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: freebsd-arm@freebsd.org X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 25 Dec 2012 20:37:36 -0000 On 2012-12-25, at 12:21 PM, Ian Lepore = wrote: > I got my RPi running this morning, more or less. I used the boot > partition from the latest image at = http://www.peach.ne.jp/archives/rpi/ > but I'm loading my own custom built kernel and world. I have a few > questions... >=20 > Can I get ubldr to load a kernel using tftp, bootp, etc? =20 Yes. ubldr checks U-Boot devices (SD and net), then tries to locate FFS partition on SD card and if fails - falls back to NFS/bootp. You can = fetch my image, boot partition there contains ubldr, FDT blob, config.txt and = boot scripts: http://people.freebsd.org/~gonzo/arm/rpi/freebsd-pi-r243778.img.gz > Are there any > docs on ubldr in general? (Right now I'm skipping ubldr and using > u-boot's DHCP command to load the kernel.) No, there are BSDCan slides by raj@ but as far as I know that's the only = bit of=20 documentation for ubldr. = http://www.bsdcan.org/2008/schedule/attachments/49_2008_uboot_freebsd.pdf > My RPi comes up with a random ethernet mac address on every boot, but > when I look at the driver code it seems that there should be an = address > stored in an eeprom. Do I have to program that myself? SMSC might or might not have EEPROM. The one in RPI does not have EEPROM so it's driver responsibility to set MAC address. There are = two options: get it from FDT blob or generate random. On Raspberry Pi it = works like this: firmware loads FDT blob at fixed address, fixes up board-specific info = like memory sizes, MAC address, board serial/revision. Then it loads u-boot, u-boot loads = ubldr, ubldr generates kernel meta-data, loads kernel and passes control to the = kernel.=20 Kernel gets FDT blob from meta-data and uses it to determine MAC = address. In order to make ubldr recognize FDT blob you'll need "fdt addr 0x100" = in /boot/loader.rc either on SD card FFS partition or on your NFS root.=20 >=20 > When I try to use an nfs-mounted root I get "Mounting from > nfs:172.22.42.240:/rpi failed with error 19." but if I mount root from > the sdcard then after it gets to multiuser mode I can manually = nfs-mount > the same directory. Has anybody got an nfs-mounted root working? This is most likely due to NFS version mismatch. We have nfs and = oldnfs for NFSv4 and NFSv3. I have working NFS root for raspberry pi. My = kernel config: options NFSCL #Network Filesystem Client=20 options NFS_ROOT #NFS usable as /, requires = NFSCLIENT options BOOTP_NFSROOT options BOOTP_COMPAT options BOOTP options BOOTP_NFSV3 options BOOTP_WIRED_TO=3Due0 I use FreeBSD 9.0 as NFS server.=20