From owner-freebsd-virtualization@freebsd.org Tue Jun 28 22:06:51 2016 Return-Path: Delivered-To: freebsd-virtualization@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 BDF7FB86434 for ; Tue, 28 Jun 2016 22:06:51 +0000 (UTC) (envelope-from jbeich@vfemail.net) Received: from vfemail.net (onethreetwo.vfemail.net [199.16.11.132]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 37D8E227D for ; Tue, 28 Jun 2016 22:06:50 +0000 (UTC) (envelope-from jbeich@vfemail.net) Received: (qmail 66036 invoked by uid 89); 28 Jun 2016 22:06:44 -0000 Received: from localhost (HELO freequeue.vfemail.net) (127.0.0.1) by localhost with (DHE-RSA-AES256-SHA encrypted) SMTP; 28 Jun 2016 22:06:44 -0000 Received: (qmail 66014 invoked by uid 89); 28 Jun 2016 22:06:26 -0000 Received: by simscan 1.3.1 ppid: 66010, pid: 66012, t: 0.0027s scanners:none Received: from unknown (HELO smtp102-2.vfemail.net) (172.16.100.62) by FreeQueue with SMTP; 28 Jun 2016 22:06:26 -0000 Received: (qmail 20398 invoked by uid 89); 28 Jun 2016 22:06:26 -0000 Received: by simscan 1.4.0 ppid: 20380, pid: 20394, t: 0.9747s scanners:none Received: from unknown (HELO nil) (amJlaWNoQHZmZW1haWwubmV0@172.16.100.27) by mail.vfemail.net with ESMTPA; 28 Jun 2016 22:06:25 -0000 From: Jan Beich To: Peter Grehan Cc: "freebsd-virtualization\@freebsd.org" Subject: Re: VirtIO Ethernet driver in DragonFlyBSD under FreeBSD bhyve In-Reply-To: (Peter Grehan's message of "Tue, 28 Jun 2016 08:08:13 -0700") References: <9893747.yFCcEWVR7f@gizmo.my.domain> <56ABFE12.4060805@freebsd.org> <60sv-b0so-wny@vfemail.net> Date: Wed, 29 Jun 2016 00:06:16 +0200 Message-ID: MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-BeenThere: freebsd-virtualization@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: "Discussion of various virtualization techniques FreeBSD supports." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 28 Jun 2016 22:06:51 -0000 --=-=-= Content-Type: text/plain Oleg Ginzburg writes: >>> /usr/sbin/bhyve -c 1 -m 4294967296 -A -H -P -s 0:0,hostbridge -s 2:0,virtio- >>> rnd -s 3:0,virtio-net,tap0 ... Does it crash with less than 4G of RAM for you as well? $ bhyve -m 1G ... Unhandled memory access to 0x100000000 Failed to emulate instruction [0x81 0x3c 0x8f 0x5f 0x4d 0x50 0x5f 0x75 0x0e 0xeb 0x05 0xb9 0x00 0x00 0x00] at 0xffffffff80a2e0a7 Peter Grehan writes: >> Any news since then? virtio-net and virtio-blk work fine if using Qemu + >> OVMF 20160418 (a8c39ba) on the same DragonFly disk image where Bhyve + >> BHYVE_UEFI_20160526.fd fails. VirtIO issue isn't specific to UEFI but also happens with Grub2. >> virtio_pci0: port 0x2000-0x203f mem >> 0xc0002000-0xc0003fff irq 6 at device 4.0 on pci0 > > The irq value doesn't seem correct for that slot compared to booting > FreeBSD. > > Was this with a recent Dragonfly snapshot ? If you can point me to > the release I'd like to give it a try. I've used a daily snapshot where the installer still doesn't support GPT/EFI yet. Tested as $ bhyve -l com1,stdio -l bootrom,BHYVE_UEFI.fd -m 4G -s 0,hostbridge \ -s 31,lpc -s 4,virtio-blk,/dev/md0 -s 5,virtio-net,tap0 vm0 vs. $ qemu-system-x86_64 -nographic -bios OVMF.fd -m 256M \ -drive if=virtio,file=/dev/md0 -net nic,model=virtio -net tap,ifname=tap0 after preparing image as follows # see https://www.dragonflybsd.org/mirrors/ $ fetch http://mirrors.nycbug.org/pub/DragonflyBSD/snapshots/x86_64/images/DragonFly-x86_64-20160628-DEV-v4.5.0.1264.gc57fa.img.bz2 $ bunzip2 DragonFly-x86_64-20160628-DEV-v4.5.0.1264.gc57fa.img.bz2 $ mdconfig -f DragonFly-x86_64-20160628-DEV-v4.5.0.1264.gc57fa.img $ gpart destroy -F md0 $ gpart create -s GPT md0 $ gpart add -b 2112 -t dragonfly-ufs md0 $ gpart add -t efi md0 $ newfs_msdos -F 12 -m 0xf8 /dev/md0p2 $ mount -t msdosfs /dev/md0p2 /mnt $ mkdir -p /mnt/efi/boot/ $ mkdir /mnt2 $ mount -t ufs /dev/md0p1 /mnt2 $ install -p /mnt2/boot/boot1.efi /mnt/efi/boot/bootx64.efi $ echo boot_serial=YES >>/mnt2/boot/loader.conf $ echo vfs.root.mountfrom=\"ufs:vbd0s0\" >>/mnt2/boot/loader.conf $ umount /mnt; umount /mnt2; rmdir /mnt2 --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQF8BAEBCgBmBQJXcvTYXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXREQjQ0MzY3NEM3RDIzNTc4NkUxNDkyQ0VF NEM3Nzg4MzQ3OURCRERCAAoJEOTHeINHnb3blcgH/jFuZGkCoqtUDaZ/nk6Xhn0c Nm1dpe17kVHlZocWu+ileOnPVIXbyuEJhyicJgtZR3W89hP1+bv02SeyBrhegoMi LUs/K76ZhpiMJBLCAKDJ1oJA3zpNZHoPP/cvlVbI9BxpsFxprzL/k78Xelhs8cZ1 9Sfqo4OQ6w7KN2vx/FowtkBu0JmKj3fBDKkptjWUnhEB5rwqBqMt4h9qlSOH9YGX mCywULP/lO9sKyztDhtgnQVJsWiUzAnNXvClAV2LdvfOa3ct8wJ6ONb7X9OSVMh1 JR89oQ45VYwaUsuI3s9Ay8H0sYuIOZCyE5dyVLtJbCNITH4eREVDmR1kqDCDSvM= =2v2z -----END PGP SIGNATURE----- --=-=-=--