From owner-freebsd-arm@freebsd.org Thu Dec 15 11:39:04 2016 Return-Path: Delivered-To: freebsd-arm@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E98CBC81B10 for ; Thu, 15 Dec 2016 11:39:04 +0000 (UTC) (envelope-from manu@bidouilliste.com) Received: from mail.blih.net (mail.blih.net [212.83.177.182]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mail.blih.net", Issuer "mail.blih.net" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 73B4487B for ; Thu, 15 Dec 2016 11:39:03 +0000 (UTC) (envelope-from manu@bidouilliste.com) Received: from mail.blih.net (mail.blih.net [212.83.177.182]) by mail.blih.net (OpenSMTPD) with ESMTP id cb319bf0; Thu, 15 Dec 2016 12:39:00 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=bidouilliste.com; h=date :from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-type:content-transfer-encoding; s=mail; bh=tHpWOUDeuHh66iQ/8/w7gulEZLY=; b=bRriPDYqGNZWRglOA2lj3SLPp/AC DxzOSiKxnjZGT6ArqPV7HpsAWbw32rXoaOId4Jm5oK32rirm7wHz6e2+dErPR69j GlYHm8oiddXhgbi5F1TWdK7DiNCCsyselKgTQXMkLOJeCXzS2l1gaUMo4buuSOfx xThqs/uCIzsX8l4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=bidouilliste.com; h=date :from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-type:content-transfer-encoding; q=dns; s= mail; b=snZ8dsUy/vmNYw6Qz70JUVlvjhXwLLfc5nzCCQfecsI9lvD+p17xOPkv dtuKnFlFxduA6w5NAKXLA4FTW3OU++aUwCk3XMZFzzSDoBNX29lb5+LpJJSRwnCf jkvZebgA5ejpQn6XWRBOwLrQ2G2mlDgqHi3CnQR07lDre60eylM= Received: from knuckles.blih.net (ip-54.net-82-216-203.roubaix.rev.numericable.fr [82.216.203.54]) by mail.blih.net (OpenSMTPD) with ESMTPSA id 97033a81 TLS version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO; Thu, 15 Dec 2016 12:39:00 +0100 (CET) Date: Thu, 15 Dec 2016 12:39:00 +0100 From: Emmanuel Vadot To: Mihai Carabas Cc: freebsd-arm@freebsd.org, Alex Ivan Subject: Re: Cubieboard2 with custom bootloader Message-Id: <20161215123900.f141d13bd9814d43feb3f736@bidouilliste.com> In-Reply-To: References: <20161212160553.dee9d435125f9c6b67355d21@bidouilliste.com> X-Mailer: Sylpheed 3.5.1 (GTK+ 2.24.29; amd64-portbld-freebsd12.0) Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2016 11:39:05 -0000 On Thu, 15 Dec 2016 08:29:20 +0200 Mihai Carabas wrote: > Hello Manu, >=20 > We've tried multiple methods: > 1. precompiled u-boot from FreeBSD packages + ubldr > 2. u-boot compiled from sources + your patches + ubldr > 3. precompiled u-boot from FreeBSD packages + kernel > 4. u-boot compiled from sources + your patches + kernel >=20 > For 1 and 2 we didn't manage to start ubldr. Do we need to add any custom > option to u-boot? >=20 > For 3, we manage to boot it normally. >=20 > With 4, we have the following error: > =3D> setenv bootcmd "fatload mmc 0:1 0x42000000 kernel.bin; go 0x42000000" > =3D> boot > reading kernel.bin > 6758372 bytes read in 589 ms (10.9 MiB/s) > ## Starting application at 0x42000000 ... > panic: mtx_lock() of spin mutex (null) @ > /root/bhyve-ARM/src/sys/arm/arm/pmap-v6.c:6350 > cpuid =3D 0 > Uptime: 1s >=20 > How did we compile u-boot: > - we took 2016.11 from here[1] (u-boot-2016.11.tar.bz2) >=20 > - apply patches and compile > root@bsd:~/u-boot-2016.11 # patch -p1 -i ../ > people.freebsd.org/\~manu/uboot/0001-.... > root@bsd:~/u-boot-2016.11 # make CROSS_COMPILE=3Darm-none-eabi- > Cubieboard2_config > root@bsd:~/u-boot-2016.11 # make CROSS_COMPILE=3Darm-none-eabi- >=20 > - and used the u-boot-sunxi-with-spl.bin > ? > Do you have any insight? (at least for thr 4th method) >=20 > Thank you, > Mihai For 1 and 2, as Ganbold said ubldr is broken since clang 3.9 import (well only ubldr.bin for me ...) For 3 and 4 I've never tested booting kernel directly, I'll try that. Does your kernel have a static dtb compiled in ? --=20 Emmanuel Vadot