From owner-freebsd-arm@freebsd.org Fri Sep 7 13:58:56 2018 Return-Path: Delivered-To: freebsd-arm@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0CCEAFFBAAB for ; Fri, 7 Sep 2018 13:58:56 +0000 (UTC) (envelope-from manu@bidouilliste.com) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id 996D48AB79 for ; Fri, 7 Sep 2018 13:58:55 +0000 (UTC) (envelope-from manu@bidouilliste.com) Received: by mailman.ysv.freebsd.org (Postfix) id 5B35EFFBAAA; Fri, 7 Sep 2018 13:58:55 +0000 (UTC) Delivered-To: arm@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 375E6FFBAA9 for ; Fri, 7 Sep 2018 13:58:55 +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 A80DE8AB78 for ; Fri, 7 Sep 2018 13:58:54 +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 63101a94; Fri, 7 Sep 2018 15:58:52 +0200 (CEST) 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=Hh7bJ9c970Y+kY2MxovQwo4f/OQ=; b=rUiao9UjCxu1CumEQCeICMwBeXX9 9FYqqnsw8ki2aWLRCHX4y6uKQBJ5KmH/QteFhNc02oLDt3DeLVp2+OApZirfEByc xF0nL9UYlmeBrSLJLj1kLHjZaXoAhuCVdlw7c2voNQ2gn4TZLXpgcFBHjjVT/WQ3 Thix3NneFLf+rt8= 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=qVuxCbX69HFoSe63c2N0VtNSLEO7oL9tzrpvqh6yDiYJwJsndfc8MPRR guGNGZXbtYFJ3g20+gYdG1mo3PsfiPuO+dy+xzbSl52Vds3IPLfj7Q72+b8PfPhj pgFBFZr5hGBrP/Jplwg6Zd7WQeNo28Mo35E4xY43sLkd3JN8d0A= Received: from knuckles.blih.net (213.208.238.22 [213.208.238.22]) by mail.blih.net (OpenSMTPD) with ESMTPSA id a8c8f9e8 TLS version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO; Fri, 7 Sep 2018 15:58:52 +0200 (CEST) Date: Fri, 7 Sep 2018 15:58:52 +0200 From: Emmanuel Vadot To: Jakob Alvermark Cc: "freebsd-arm@freebsd.org" Subject: Re: allwinner/nanopi neo boot issues Message-Id: <20180907155852.cfbfae454347ada23378e0e5@bidouilliste.com> In-Reply-To: <9a911ee0-379f-d8b0-a71a-7b5302d9e5d4@alvermark.net> References: <42AA3AE2-E101-4B7B-B373-BEC178321671@cs.huji.ac.il> <0fdbd315-f37d-e3d3-9309-612f53c4d379@alvermark.net> <8459A9BA-183A-461B-9050-3631C51218F9@cs.huji.ac.il> <474af48e-ba82-62ce-34a3-70dfc4382723@alvermark.net> <20180901224629.3997b4de29e4bf5f893dac79@bidouilliste.com> <03d4cb0a-c218-a186-936d-765261da2775@alvermark.net> <20180902172444.c4911c8c65a99a7d5e9fe8fa@bidouilliste.com> <4410f41b-79f5-f397-b0b1-84bceae82bd0@alvermark.net> <855C0010-888D-4988-8056-7788CBCF5A48@cs.huji.ac.il> <20180904181603.916a3a6fbf05ecce149f6ea1@bidouilliste.com> <79e69d73-b4f0-177a-15da-786c4101697a@alvermark.net> <20180905144108.7a2e361108cdcf3c16ed8b66@bidouilliste.com> <6a6d0683-cb07-ec4d-77f8-418d84c41f08@alvermark.net> <9a911ee0-379f-d8b0-a71a-7b5302d9e5d4@alvermark.net> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.32; 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.27 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Sep 2018 13:58:56 -0000 On Wed, 5 Sep 2018 17:34:05 +0200 Jakob Alvermark wrote: > On 9/5/18 5:24 PM, Jakob Alvermark wrote: > > > > On 9/5/18 2:41 PM, Emmanuel Vadot wrote: > >> On Tue, 4 Sep 2018 19:10:53 +0200 > >> Jakob Alvermark wrote: > >> > >>> On 9/4/18 6:16 PM, Emmanuel Vadot wrote: > >>>> On Mon, 3 Sep 2018 11:21:09 +0300 > >>>> Daniel Braniss wrote: > >>>> > >>>>>> On 3 Sep 2018, at 11:05, Jakob Alvermark =20 > >>>>>> wrote: > >>>>>> > >>>>>> > >>>>>> On 9/3/18 9:01 AM, Daniel Braniss wrote: > >>>>>>>> On 2 Sep 2018, at 19:33, Jakob Alvermark >>>>>>>> > wrote: > >>>>>>>> > >>>>>>>> On 9/2/18 5:24 PM, Emmanuel Vadot wrote: > >>>>>>>>> On Sun, 2 Sep 2018 17:14:10 +0200 > >>>>>>>>> Jakob Alvermark >>>>>>>>> > wrote: > >>>>>>>>> > >>>>>>>>>> On 9/1/18 10:46 PM, Emmanuel Vadot wrote: > >>>>>>>>>>> On Sat, 1 Sep 2018 15:50:25 +0200 > >>>>>>>>>>> Jakob Alvermark >>>>>>>>>>> > wrote: > >>>>>>>>>>> > >>>>>>>>>>>> On 8/29/18 2:22 PM, Daniel Braniss wrote: > >>>>>>>>>>>>>> On 29 Aug 2018, at 15:17, Jakob Alvermark=20 > >>>>>>>>>>>>>> > >>>>>>>>>>>>>> >>>>>>>>>>>>>> >> wrote: > >>>>>>>>>>>>>> > >>>>>>>>>>>>>> > >>>>>>>>>>>>>> On 8/24/18 10:02 AM, Daniel Braniss wrote: > >>>>>>>>>>>>>>>> On 24 Aug 2018, at 09:34, Daniel Braniss=20 > >>>>>>>>>>>>>>>> > >>>>>>>>>>>>>>>> >>>>>>>>>>>>>>>> >> wrote: > >>>>>>>>>>>>>>>> > >>>>>>>>>>>>>>>> hi, > >>>>>>>>>>>>>>>> with the latest current r338243 no longer boots via=20 > >>>>>>>>>>>>>>>> ubldr, efi does > >>>>>>>>>>>>>>>> but with overlays I have to manually enter the root=20 > >>>>>>>>>>>>>>>> partition. > >>>>>>>>>>>>>>>> > >>>>>>>>>>>>>>>> this is where it hangs via ubldr: > >>>>>>>>>>>>>>>> > >>>>>>>>>>>>>>>> Autoboot in 8 seconds, hit [Enter] to boot or any other= =20 > >>>>>>>>>>>>>>>> key to stop > >>>>>>>>>>>>>>>> > >>>>>>>>>>>>>>>> Loading kernel... > >>>>>>>>>>>>>>>> /boot/kernel/kernel text=3D0x8a0950 data=3D0xae160+0x184= 520 > >>>>>>>>>>>>>>>> syms=3D[0x4+0xa6d70+0x4+0x109f17] > >>>>>>>>>>>>>>>> Loading configured modules... > >>>>>>>>>>>>>>>> /boot/entropy size=3D0x1000 > >>>>>>>>>>>>>>>> /boot/dtb/sun8i-h3-nanopi-neo.dtb size=3D0x601b > >>>>>>>>>>>>>>>> Loaded DTB from file 'sun8i-h3-nanopi-neo.dtb'. > >>>>>>>>>>>>>>>> Kernel entry at 0x42400180... > >>>>>>>>>>>>>>>> Kernel args: (null) > >>>>>>>>>>>>>>>> > >>>>>>>>>>>>>>>> older - r337232 - boots fine, > >>>>>>>>>>>>>>>> > >>>>>>>>>>>>>>>> any ideas where to look? > >>>>>>>>>>>>>>> should have done an update before writing! > >>>>>>>>>>>>>>> > >>>>>>>>>>>>>>> with the latest (and greatest) all is back to normal! > >>>>>>>>>>>>>>> so now on to test orange pi one(h3), nanopi neo 2 (h5)=20 > >>>>>>>>>>>>>>> and nanopi > >>>>>>>>>>>>>>> neo a64 > >>>>>>>>>>>>>>> > >>>>>>>>>>>>>>> thanks, > >>>>>>>>>>>>>>> danny > >>>>>>>>>>>>>> Hi, > >>>>>>>>>>>>>> > >>>>>>>>>>>>>> > >>>>>>>>>>>>>> I am trying to get an Orange Pi R1 going, I get the same. > >>>>>>>>>>>>>> > >>>>>>>>>>>>>> Loading kernel... > >>>>>>>>>>>>>> /boot/kernel/kernel text=3D0x89ee40 data=3D0xae620+0x1f5ba0 > >>>>>>>>>>>>>> syms=3D[0x4+0xa6d20+0x4+0x109e51] > >>>>>>>>>>>>>> Loading configured modules... > >>>>>>>>>>>>>> Could not load one or more modules! > >>>>>>>>>>>>>> /boot/dtb/sun8i-h2-plus-orangepi-r1.dtb size=3D0x6333 > >>>>>>>>>>>>>> Loaded DTB from file 'sun8i-h2-plus-orangepi-r1.dtb'. > >>>>>>>>>>>>>> Kernel entry at 0x42400180... > >>>>>>>>>>>>>> Kernel args: (null) > >>>>>>>>>>>>>> > >>>>>>>>>>>>>> This is at r338369. > >>>>>>>>>>>>>> > >>>>>>>>>>>>>> > >>>>>>>>>>>>> try booting via efi; > >>>>>>>>>>>>> make sure to copy /boot/loader.efi to=20 > >>>>>>>>>>>>> /boot/msdos/EFI/BOOT/bootaa64.efi > >>>>>>>>>>>>> remove /boot/msdos/boot.scr > >>>>>>>>>>>>> good luck, > >>>>>>>>>>>>> danny > >>>>>>>>>>>> I tried the ALPHA4 snapshot, this happens: > >>>>>>>>>>>> > >>>>>>>>>>>> Hit any key to stop autoboot:=A0 0 > >>>>>>>>>>>> switch to partitions #0, OK > >>>>>>>>>>>> mmc0 is current device > >>>>>>>>>>>> Scanning mmc 0:1... > >>>>>>>>>>>> 25395 bytes read in 4 ms (6.1 MiB/s) > >>>>>>>>>>>> Found EFI removable media binary efi/boot/bootarm.efi > >>>>>>>>>>>> Scanning disks on usb... > >>>>>>>>>>>> Disk usb0 not ready > >>>>>>>>>>>> Disk usb1 not ready > >>>>>>>>>>>> Disk usb2 not ready > >>>>>>>>>>>> Disk usb3 not ready > >>>>>>>>>>>> Scanning disks on mmc... > >>>>>>>>>>>> MMC Device 1 not found > >>>>>>>>>>>> MMC Device 2 not found > >>>>>>>>>>>> MMC Device 3 not found > >>>>>>>>>>>> Found 3 disks > >>>>>>>>>>>> 508704 bytes read in 26 ms (18.7 MiB/s) > >>>>>>>>>>>> ## Starting EFI application at 42000000 ... > >>>>>>>>>>>> Consoles: EFI console > >>>>>>>>>>>> failed to allocate staging area: 14 > >>>>>>>>>>>> failed to allocate staging area > >>>>>>>>>>>> ## Application terminated, r =3D 5 > >>>> =A0=A0 So this is weird, it mean that loader.efi couldn't allocate s= ome=20 > >>>> pages. > >>>> > >>>> =A0=A0 I've just tried ALPHA4 on my orangepi-zero (closer board that= I=20 > >>>> have), > >>>> I've just overwritten u-boot using the port we have for it and the > >>>> board boots just fine. > >>>> =A0=A0 How did you generate the image for this one ? > >>>> =A0=A0 Could you test with my method ? Thanks. > >>> Which image should I use? For ALPHA3 there is a GENERICSD image, but= =20 > >>> not > >>> for ALPHA4. > >> =A0 Build fail due to some (maybe) race condition. > >> > >>> I just tried with > >>> FreeBSD-12.0-ALPHA4-arm-armv7-CUBIEBOARD2-20180831-r338410.img > >> =A0 Any of the armv7 image will do, they are all the same except the > >> u-boot part. > >> > >>> dd the u-boot from the port (latest one, u-boot-orangepi_r1-2018.07_3) > >>> > >>> Put the SD card in and this happened: > >>> > >>> Hit any key to stop autoboot:=A0 0 > >>> switch to partitions #0, OK > >>> mmc0 is current device > >>> Scanning mmc 0:1... > >>> 25395 bytes read in 3 ms (8.1 MiB/s) > >>> Found EFI removable media binary efi/boot/bootarm.efi > >>> Scanning disks on usb... > >>> Disk usb0 not ready > >>> Disk usb1 not ready > >>> Disk usb2 not ready > >>> Disk usb3 not ready > >>> Scanning disks on mmc... > >>> MMC Device 1 not found > >>> MMC Device 2 not found > >>> MMC Device 3 not found > >>> Found 3 disks > >>> 508704 bytes read in 25 ms (19.4 MiB/s) > >>> ## Starting EFI application at 42000000 ... > >>> Consoles: EFI console > >>> failed to allocate staging area: 14 > >>> failed to allocate staging area > >>> ## Application terminated, r =3D 5 > >>> EFI LOAD FAILED: continuing... > >>> > >>> > >> =A0 Could you try to decrease EFI_STAGING_SIZE to 32 in > >> stand/efi/loader/copy.c ? > > > > Didn't make any difference: > > > > Found EFI removable media binary efi/boot/bootarm.efi > > Scanning disks on usb... > > Disk usb0 not ready > > Disk usb1 not ready > > Disk usb2 not ready > > Disk usb3 not ready > > Scanning disks on mmc... > > MMC Device 1 not found > > MMC Device 2 not found > > MMC Device 3 not found > > Found 3 disks > > 508704 bytes read in 26 ms (18.7 MiB/s) > > ## Starting EFI application at 42000000 ... > > Consoles: EFI console > > failed to allocate staging area: 14 > > failed to allocate staging area > > ## Application terminated, r =3D 5 > > EFI LOAD FAILED: continuing... >=20 >=20 > Disregard that. I copied the wrong file. >=20 > I boots with EFI_STAGING_SIZE set 32. Ok, thanks. I'm wondering if we should try with EFI_STAGING_SIZE/2 if the first allocate_pages failed ... >=20 >=20 > > > >> =A0 We currently request 64M for the staging size which seems to be too > >> big for this board. > >> =A0 U-Boot cannot find enough memory it seems, > >> https://elixir.bootlin.com/u-boot/latest/source/lib/efi_loader/efi_mem= ory.c#L300=20 > >> > >> > > _______________________________________________ > > freebsd-arm@freebsd.org mailing list > > https://lists.freebsd.org/mailman/listinfo/freebsd-arm > > To unsubscribe, send any mail to "freebsd-arm-unsubscribe@freebsd.org" --=20 Emmanuel Vadot