From owner-freebsd-arm@freebsd.org Sun Feb 21 10:53:51 2021 Return-Path: Delivered-To: freebsd-arm@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id B4E04552ED4 for ; Sun, 21 Feb 2021 10:53:51 +0000 (UTC) (envelope-from samm@freebsd.org) Received: from reindeer.net-art.cz (reindeer.net-art.cz [IPv6:2001:15e8:110:513c::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "reindeer.net-art.cz", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Dk2HM2jbYz4Wld for ; Sun, 21 Feb 2021 10:53:51 +0000 (UTC) (envelope-from samm@freebsd.org) Received: by reindeer.net-art.cz (Postfix, from userid 65534) id 34BD75EEF5; Sun, 21 Feb 2021 10:53:48 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on reindeer X-Spam-Level: X-Spam-Status: No, score=-0.9 required=10.0 tests=BAYES_00,HTML_MESSAGE, KHOP_HELO_FCRDNS,NICE_REPLY_A,SPF_HELO_NONE,SPF_SOFTFAIL autolearn=no autolearn_force=no version=3.4.2 Received: from owl.net-art.cz (surikat.net-art.cz [IPv6:2a03:6920:0:10::101]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "owl.net-art.cz", Issuer "R3" (not verified)) by reindeer.net-art.cz (Postfix) with ESMTPS id C186C5EE23 for ; Sun, 21 Feb 2021 10:53:47 +0000 (GMT) Received: from [2001:1a48:6:10:b0a8:f54:9b4c:56e2] (account samm@net-art.cz HELO Administrators-MacBook-Pro.local) by owl.net-art.cz (CommuniGate Pro SMTP 6.1.20) with ESMTPSA id 796220 for freebsd-arm@freebsd.org; Sun, 21 Feb 2021 11:53:47 +0100 Received-SPF: softfail receiver=owl.net-art.cz; client-ip=2001:1a48:6:10:b0a8:f54:9b4c:56e2; envelope-from=samm@freebsd.org Subject: Re: RPI4 USB Boot: Unable to find firmware device From: Alex Samorukov To: freebsd-arm@freebsd.org References: Message-ID: <4083ff7e-bb6e-c937-898b-9cd96b3d58da@freebsd.org> Date: Sun, 21 Feb 2021 11:53:45 +0100 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.16; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 MIME-Version: 1.0 In-Reply-To: Content-Language: en-US X-Rspamd-Queue-Id: 4Dk2HM2jbYz4Wld X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [0.00 / 15.00]; local_wl_from(0.00)[freebsd.org]; ASN(0.00)[asn:24806, ipnet:2001:15e8::/32, country:CZ] Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.34 X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Porting FreeBSD to ARM processors List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 21 Feb 2021 10:53:51 -0000 Answering myself - i was able to fix that and localize an issue. Steps i did: 1. Installed on another USB disk raspbian and tried to select using raspi-config usb as default one. 2. Overwritten most of the files from /boot of raspbian to msdosfs in freebsd. This fixed the issue. However, i decided to find a root cause. After all i found that it is enough to replace _only_ bcm2711-rpi-4-b.dtb. I decompiled both and put them to gh git: https://gist.github.com/samm-git/c56e9e16e07339cea8606a78a7da7f58 I think most relevant part is https://gist.github.com/samm-git/c56e9e16e07339cea8606a78a7da7f58#file-bcm2711-rpi-4-b-dtb-txt-diff-L1344 where bcm2835-firmware is attached to simple-mfd and not simple-bus. Do we need to do some overlay for that? Good news is that now powerd is working and i am getting 1500 CPU frequency. But would be great to understand and document this in the RPI wiki for other users. So any comments are welcome. On 20.02.2021 16:56, Alex Samorukov wrote: > Hello, > > > I am booting FreeBSD generic 13.0-BETA3 from the USB. All works, but on > boot i see "Unable to find firmware device" for the bcm2835_cpufreq0. As > result - powerd is not working. I think it somehow expects firmware on > mmc (which is missing) and fails to load it from USB. I did not found > how to point kernel to the correct firmware device/path. Any hints? > >