From nobody Thu May 30 20:12:38 2024 X-Original-To: freebsd-virtualization@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4VqyFX2SDkz5LLc1 for ; Thu, 30 May 2024 20:16:32 +0000 (UTC) (envelope-from emil@etsalapatis.com) Received: from mail-pf1-x441.google.com (mail-pf1-x441.google.com [IPv6:2607:f8b0:4864:20::441]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VqyFW3ddVz4PJ7 for ; Thu, 30 May 2024 20:16:31 +0000 (UTC) (envelope-from emil@etsalapatis.com) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=etsalapatis-com.20230601.gappssmtp.com header.s=20230601 header.b="zGQ/OSSR"; dmarc=none; spf=pass (mx1.freebsd.org: domain of emil@etsalapatis.com designates 2607:f8b0:4864:20::441 as permitted sender) smtp.mailfrom=emil@etsalapatis.com Received: by mail-pf1-x441.google.com with SMTP id d2e1a72fcca58-70234843a67so903872b3a.1 for ; Thu, 30 May 2024 13:16:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=etsalapatis-com.20230601.gappssmtp.com; s=20230601; t=1717100190; x=1717704990; darn=freebsd.org; h=to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=jCo3qrKzQCZ5tcLP7xnPFS62uchsrQ+dV2Zx2aBbAqU=; b=zGQ/OSSRfXUEU94uczSMu3BLf/7x4tUgPgdydSUHnKNo1Ztyvmv3+vhflOLgcJ1L4h YfqYWPjmk90YSAxxgGFa30hvkUYhkceoh9l9h/hni3YWv3vwWdDk5c41VzBSaK2hDwLd 8Xm8EPe0mCTR1HHG2zuvja2YjzZ5mLeLgyDldgtYwiB4TZn0+YNvFN8XaL7AFkyFcUKU SGK6h1Id3xtTYZhjQw+PX2LUC9jshhRX6+R+VwxDX1aL1+1B5q0IM8l5gt04erx6viXB iRkULgLS9HYATtlrgbKp5VKf3eMfIYoOzzSeaZzYpvsAhbmL9893vuAR3m5O//6MX6cV CIyQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717100190; x=1717704990; h=to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=jCo3qrKzQCZ5tcLP7xnPFS62uchsrQ+dV2Zx2aBbAqU=; b=N4O7enNiuH1OZFum0s1A4hLogXxV2/f7rehijkFIVIO70VBJIS+7PXuLSaZZiBd0Cz Yf2Pcx4gi8PX781nQmzE+f58jGen/N5g3X5IdzkPcVvi9vWlaMka5Bb1JKMYlNM5xy9t kkMpRTObGkYcxjzyOtm9oX63WnwJQm3OE7xHq536iEWkcCREw/A6fninTz0Hoc1Cd/TP oEl9BTLbhzZSQ/E91dA+XfU4FysB/cZgbrFYjk+Ou+eEBsZoofQpG2ovr/sPd6QUGiIG kzoaJ3f3UQG+afIPSdIKqWG9uoTCq1cUPHBGKFlHjk+dEm/Ty0wdUdNWi7G7tUOSWzxA rFCQ== X-Gm-Message-State: AOJu0YzdNfJ/rbdbzqSdQyGrW1ohsl9ss69xW1q8KXeVfewMbOdz514i J+nNaYZ6feE90K0akUgbF8y5z39OxZvH90I4XEyuS+Z+3gbD9dFBekBIoFxZgzwmS67mxE+5b9E X8QwD8zCrwCe2BoRsflXO4M+GSMAQK7si6wBxHbG9X/cSC3/m3oLWV8kLBtM= X-Google-Smtp-Source: AGHT+IF6RrCOmGDZyvI24yJ8WyxvRFrhZ0wSfm+LiMIZzIJYPPzZ8ssoafeqV0qg2uN+n6+RHXwt8TFoC3r0AUwPR0Q= X-Received: by 2002:a05:6a20:12cb:b0:1af:6911:7ff4 with SMTP id adf61e73a8af0-1b26f17e121mr52826637.7.1717100189617; Thu, 30 May 2024 13:16:29 -0700 (PDT) List-Id: Discussion List-Archive: https://lists.freebsd.org/archives/freebsd-virtualization List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: freebsd-virtualization@freebsd.org Sender: owner-freebsd-virtualization@FreeBSD.org MIME-Version: 1.0 From: Emil Tsalapatis Date: Thu, 30 May 2024 16:12:38 -0400 Message-ID: Subject: [RFC] virtio testing framework To: freebsd-virtualization@freebsd.org Content-Type: multipart/alternative; boundary="000000000000d8a9f60619b18adb" X-Spamd-Bar: --- X-Spamd-Result: default: False [-3.50 / 15.00]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_SHORT(-1.00)[-1.000]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; R_DKIM_ALLOW(-0.20)[etsalapatis-com.20230601.gappssmtp.com:s=20230601]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; RCPT_COUNT_ONE(0.00)[1]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; RCVD_COUNT_ONE(0.00)[1]; MISSING_XM_UA(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; DMARC_NA(0.00)[etsalapatis.com]; MLMMJ_DEST(0.00)[freebsd-virtualization@freebsd.org]; TO_DN_NONE(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::441:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; RCVD_TLS_LAST(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-virtualization@freebsd.org]; DKIM_TRACE(0.00)[etsalapatis-com.20230601.gappssmtp.com:+] X-Rspamd-Queue-Id: 4VqyFW3ddVz4PJ7 --000000000000d8a9f60619b18adb Content-Type: text/plain; charset="UTF-8" Hi everyone, while developing a virtiofs kernel driver I have written a debug virtio transport to test virtio drivers inside a VM without requiring nested virtualization or support from the host. The transport allows paravirt devices to be emulated in local userspace instead of a host, so we can create paravirt devices and test them as necessary. For virtiofs in particular, it allows us to reuse the existing FUSE tests since we can now run both the virtiofs driver and the FUSE server (which is normally in the host) in a single machine. I have uploaded the WIP code [here ], and an overview of the design [here ]. The patch has a ways to go, and currently only supports virtio-blk device emulation as a PoC, but feedback is welcome and appreciated. Please also let me know if there is interest in using this for testing other virtio devices apart from virtiofs. --Emil --000000000000d8a9f60619b18adb Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi everyone,

=C2=A0 =C2=A0 while developing a virti= ofs kernel driver I have written a debug virtio transport to test virtio dr= ivers inside a VM without requiring nested virtualization or support from= =20 the host. The transport allows paravirt devices to be emulated in local=20 userspace instead of a host, so we can create paravirt devices and test=20 them as necessary. For virtiofs in particular, it allows us to reuse the existing FUSE tests since we can now run both the virtiofs driver and=20 the FUSE server (which is normally in the host) in a single machine.

I have uploaded the WIP code [here], and an overview of the desi= gn [here]. The patch has a ways to go, and currently only supports virtio-blk=20 device emulation as a PoC, but feedback is welcome and appreciated.=20 Please also let me know if there is interest in using this for testing=20 other virtio devices apart from virtiofs.

= --Emil
--000000000000d8a9f60619b18adb--