From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.90_1) id 1lxCih-00085h-6h for mharc-grub-devel@gnu.org; Sat, 26 Jun 2021 14:07:55 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:33452) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lxCie-00085Y-KI for grub-devel@gnu.org; Sat, 26 Jun 2021 14:07:52 -0400 Received: from mail-out.m-online.net ([212.18.0.9]:40311) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lxCib-0003rF-Ui for grub-devel@gnu.org; Sat, 26 Jun 2021 14:07:52 -0400 Received: from frontend01.mail.m-online.net (unknown [192.168.8.182]) by mail-out.m-online.net (Postfix) with ESMTP id 4GC20D6YTHz1qt44; Sat, 26 Jun 2021 20:07:40 +0200 (CEST) Received: from localhost (dynscan1.mnet-online.de [192.168.6.70]) by mail.m-online.net (Postfix) with ESMTP id 4GC20D5T1kz1qwZ4; Sat, 26 Jun 2021 20:07:40 +0200 (CEST) X-Virus-Scanned: amavisd-new at mnet-online.de Received: from mail.mnet-online.de ([192.168.8.182]) by localhost (dynscan1.mail.m-online.net [192.168.6.70]) (amavisd-new, port 10024) with ESMTP id 5VQ20pIUeHLz; Sat, 26 Jun 2021 20:07:39 +0200 (CEST) X-Auth-Info: NQkHjMnyKiWhyZj14v/1pVPScCZfN3dsrAVSOqut1oUBCMVaTIjfIBXeMxSd8HiZ Received: from igel.home (ppp-46-244-178-40.dynamic.mnet-online.de [46.244.178.40]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.mnet-online.de (Postfix) with ESMTPSA; Sat, 26 Jun 2021 20:07:39 +0200 (CEST) Received: by igel.home (Postfix, from userid 1000) id 930542C1836; Sat, 26 Jun 2021 20:07:38 +0200 (CEST) From: Andreas Schwab To: Nikita Ermakov Cc: GRUB development mailing list , Ard Biesheuvel , Atish Patra , Daniel Kiper , Heinrich Schuchardt , Leif Lindholm Subject: Re: [PATCH v2 0/7] Add LoadFile2 and riscv Linux loader References: <20210602211235.377366-1-arei@altlinux.org> X-Yow: My polyvinyl cowboy wallet was made in Hong Kong by Montgomery Clift! Date: Sat, 26 Jun 2021 20:07:38 +0200 In-Reply-To: <20210602211235.377366-1-arei@altlinux.org> (Nikita Ermakov's message of "Thu, 3 Jun 2021 00:12:28 +0300") Message-ID: <8735t4lct1.fsf@igel.home> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=212.18.0.9; envelope-from=whitebox@nefkom.net; helo=mail-out.m-online.net X-Spam_score_int: -22 X-Spam_score: -2.3 X-Spam_bar: -- X-Spam_report: (-2.3 / 5.0 requ) BAYES_00=-1.9, HEADER_FROM_DIFFERENT_DOMAINS=0.249, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jun 2021 18:07:52 -0000 On Jun 03 2021, Nikita Ermakov wrote: > This series contains patches to add support for LoadFile2 protocol to load > initrd on EFI systems. Also it contains patches to load Linux kernel with EFI > stub on riscv platforms and unites arm and riscv codes together into common > loader code for EFI systems. That doesn't work with a CD image. When I try to run http://download.opensuse.org/ports/riscv/tumbleweed/iso/openSUSE-Tumbleweed-NET-riscv64-Media.iso with qemu, the initrd fails to load. $ qemu-system-riscv64 -M virt -nographic -serial mon:stdio -smp 4 -m 8g -kernel u-boot.bin -drive format=raw,if=virtio,media=cdrom,file=openSUSE-Tumbleweed-NET-riscv64-Media.iso OpenSBI v0.9 ____ _____ ____ _____ / __ \ / ____| _ \_ _| | | | |_ __ ___ _ __ | (___ | |_) || | | | | | '_ \ / _ \ '_ \ \___ \| _ < | | | |__| | |_) | __/ | | |____) | |_) || |_ \____/| .__/ \___|_| |_|_____/|____/_____| | | |_| Platform Name : riscv-virtio,qemu Platform Features : timer,mfdeleg Platform HART Count : 4 Firmware Base : 0x80000000 Firmware Size : 124 KB Runtime SBI Version : 0.2 Domain0 Name : root Domain0 Boot HART : 1 Domain0 HARTs : 0*,1*,2*,3* Domain0 Region00 : 0x0000000080000000-0x000000008001ffff () Domain0 Region01 : 0x0000000000000000-0xffffffffffffffff (R,W,X) Domain0 Next Address : 0x0000000080200000 Domain0 Next Arg1 : 0x00000000bf000000 Domain0 Next Mode : S-mode Domain0 SysReset : yes Boot HART ID : 1 Boot HART Domain : root Boot HART ISA : rv64imafdcsu Boot HART Features : scounteren,mcounteren,time Boot HART PMP Count : 16 Boot HART PMP Granularity : 4 Boot HART PMP Address Bits: 54 Boot HART MHPM Count : 0 Boot HART MHPM Count : 0 Boot HART MIDELEG : 0x0000000000000222 Boot HART MEDELEG : 0x000000000000b109 U-Boot 2021.04 (Jun 09 2021 - 00:00:00 +0000) CPU: rv64imafdcsu Model: riscv-virtio,qemu DRAM: 8 GiB In: uart@10000000 Out: uart@10000000 Err: uart@10000000 Net: No ethernet found. Hit any key to stop autoboot: 0 Device 0: 1af4 VirtIO Block Device Type: Hard Disk Capacity: 225.7 MB = 0.2 GB (462376 x 512) ... is now current device ** Invalid partition 3 ** ** Invalid partition 4 ** ** Invalid partition 2 ** Scanning virtio 0:1... ** Unable to read file / ** Failed to load '/' libfdt fdt_check_header(): FDT_ERR_BADMAGIC Scanning disk virtio-blk#8... Found 2 disks No EFI system partition BootOrder not defined EFI boot manager: Cannot load any image Found EFI removable media binary efi/boot/bootriscv64.efi 2584576 bytes read in 3 ms (821.6 MiB/s) libfdt fdt_check_header(): FDT_ERR_BADMAGIC Booting /efi\boot\bootriscv64.efi Welcome to GRUB! Please press 't' to show the boot menu on this console error: ../../grub-core/video/video.c:761:no suitable video mode found. openSUSE Tumbleweed ┌────────────────────────────────────────────────────────────────────────────┐ │ Boot from Hard Disk │ │*Installation │ │ Upgrade │ │ More ... │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ └────────────────────────────────────────────────────────────────────────────┘ Use the ▲ and ▼ keys to select which entry is highlighted. Press enter to boot the selected OS, `e' to edit the commands before booting or `c' for a command-line. Loading kernel ... Loading initial ramdisk ... EFI stub: Booting Linux Kernel... EFI stub: Using DTB from configuration table EFI stub: ERROR: Failed to load initrd! EFI stub: Exiting boot services and installing virtual address map... -- Andreas Schwab, schwab@linux-m68k.org GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510 2552 DF73 E780 A9DA AEC1 "And now for something completely different."