From owner-freebsd-arm@freebsd.org Wed Mar 27 19:35:43 2019 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 612BD1558D63 for ; Wed, 27 Mar 2019 19:35:43 +0000 (UTC) (envelope-from kevans@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 01C7B8BA06 for ; Wed, 27 Mar 2019 19:35:43 +0000 (UTC) (envelope-from kevans@freebsd.org) Received: from mail-lj1-f177.google.com (mail-lj1-f177.google.com [209.85.208.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) (Authenticated sender: kevans) by smtp.freebsd.org (Postfix) with ESMTPSA id AAACC15868 for ; Wed, 27 Mar 2019 19:35:42 +0000 (UTC) (envelope-from kevans@freebsd.org) Received: by mail-lj1-f177.google.com with SMTP id p14so14508330ljg.5 for ; Wed, 27 Mar 2019 12:35:42 -0700 (PDT) X-Gm-Message-State: APjAAAUfTdwGc6GvVAvZ4omlOWgnSAYO0VnkGLsfOddc9QPhYp2j0grN IEBve6zUoB94dd2VJ4yxkAVFnlcOVWHGlx6wtVg= X-Google-Smtp-Source: APXvYqyd3cHEEGeoqvSS1niz2CmccQE31jWb1Hqkj3+gg7BIrhTvLyKrufBRcbSRrPXb8o7XdAk7jg3dMio6/zVziJk= X-Received: by 2002:a2e:8991:: with SMTP id c17mr3343601lji.83.1553715341093; Wed, 27 Mar 2019 12:35:41 -0700 (PDT) MIME-Version: 1.0 References: <20190327192320.GA64908@freebsd-t450.fritz.box> In-Reply-To: <20190327192320.GA64908@freebsd-t450.fritz.box> From: Kyle Evans Date: Wed, 27 Mar 2019 14:35:26 -0500 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: efi-loader ignores dtb files? To: =?UTF-8?Q?Manuel_St=C3=BChn?= Cc: "freebsd-arm@freebsd.org" Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: 01C7B8BA06 X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-6.98 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; NEURAL_HAM_SHORT(-0.98)[-0.984,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; REPLY(-4.00)[] X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Mar 2019 19:35:43 -0000 On Wed, Mar 27, 2019 at 2:26 PM Manuel St=C3=BChn wrote: > > While trying to get FreeBSD 12.0 up and running on a NanoPI NEO2 > (aarch64 Allwinner H5) I'm stumbling over issues with > loader/loader.conf. FreeBSD starts fine, but it uses the > devicetree-blob provided by uboot/EFI. I've tried to load the FreeBSD > one by adding these lines to loader.conf: > > sun50i-h5-nanopi-neo2.dtb_load=3D"YES" > sun50i-h5-nanopi-neo2.dtb_type=3D"dtb" > > and put the dtb file into /boot/dtb/sun50i-h5-nanopi-neo2.dtb, but this > did not work at all. It got completely ignored by loader. The rest of > the file was read and applied correctly (kernel-modules i'd added for > testing purposes were loaded correctly). > > I tried to load it by hand like this: > > load -t dtb sun50i-h5-nanopi-neo2.dtb > > which worked, the dtb file was loaded and used. After consulting > loader.conf(5) i found this way to load modules: > > dtbfile_load=3D"YES" > dtbfile_type=3D"dtb" > dtbfile_name=3D"sun50i-h5-nanopi-neo2.dtb" > > and this finally triggered loader(8) to actually load the dtb. > Unfortunatley the problem occurred again when i tried to add overlays. > Those are, again, not recognized at all: > > /boot/loader.conf: > fdt_overlays=3D"sun50i-nanopi-neo2-codec.dtbo,sun50i-nanopi-neo2-sid.dtbo= ,sun50i-nanopi-neo2-ths.dtbo" > > Any ideas? Yes- for your first problem, loader doesn't recognize a period as a valid module name, so those directives would not have gotten recognized as modules to load. I'm not sure off-hand why fdt_overlays were not recognized. I would drop to loader prompt and double check that it actually ended up in the environment, but I don't see any reason off-hand that it wouldn't. It might be a good idea to drop to loader prompt and trigger overlay application. No output at all? > BTW, is there a way to keep the u-boot logs printed before the > FreeBSD-boot-menu gets drawn? The console gets cleared and erases some > (valuable?) information. I was always to slow to stop the boot right > after the last line of u-boot and the first of EFI. Any reason you need to keep the loader menu? Disabling it (beastie_disable=3D"YES") and lack of password prompts will stop the screen clearing in recent-ish versions of the lua scripts from head. Thanks, Kyle Evans