From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from atuin.qyliss.net (localhost [IPv6:::1]) by atuin.qyliss.net (Postfix) with ESMTP id 3530D10296; Sat, 09 Nov 2024 21:47:12 +0000 (UTC) Received: by atuin.qyliss.net (Postfix, from userid 993) id 3DEE910206; Sat, 09 Nov 2024 21:47:02 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on atuin.qyliss.net X-Spam-Level: X-Spam-Status: No, score=-0.7 required=5.0 tests=DMARC_MISSING, RCVD_IN_DNSWL_LOW,SPF_HELO_PASS autolearn=unavailable autolearn_force=no version=4.0.1 Received: from fhigh-a4-smtp.messagingengine.com (fhigh-a4-smtp.messagingengine.com [103.168.172.155]) by atuin.qyliss.net (Postfix) with ESMTPS id 7DE9E10203 for ; Sat, 09 Nov 2024 21:46:56 +0000 (UTC) Received: from phl-compute-08.internal (phl-compute-08.phl.internal [10.202.2.48]) by mailfhigh.phl.internal (Postfix) with ESMTP id 55C3B11400CE; Sat, 9 Nov 2024 16:46:54 -0500 (EST) Received: from phl-mailfrontend-01 ([10.202.2.162]) by phl-compute-08.internal (MEProxy); Sat, 09 Nov 2024 16:46:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alyssa.is; h=cc :cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm2; t=1731188814; x=1731275214; bh=vbCqhoeirV fBHghUX6vr+bFRYSd7FsIykx7N89lKPjM=; b=XFDibkrSx0XahmCG2evxcaRhb3 J3YPAs6XVl97O4lwe/RgE6o6SifFUmQKqA7i6JHk85Aq27H2GEquWXxMew1A9jYG jdKnwTvfhCHn6O/L4M/ABo2pU9B3IYLz1gne1+FkV8kVbRJhVHP001bFwsXzWTM5 vqM17xItWWnexZ8TuX7cuorhihTeFHZmucTiz/SImeKkKWiYEpNjUmv2eS+4rM9b qQ3VFV4h1O+CX/D0cNlS4214yvOYP1ELFbEjtxkB9qQleJxe5pt7FqP0sGUJkiDV se8NCPJxLCFMoRHk2OHSV2L3CVvzM6Yhsz4xxOnmzCNh8c6cTMJi+Atx2zag== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t= 1731188814; x=1731275214; bh=vbCqhoeirVfBHghUX6vr+bFRYSd7FsIykx7 N89lKPjM=; b=Cmx4Gdx9qw6zidqPbwu+HnzMyOq2pfcZYKE1IyxGk34fSt0yick NWp8JSzpfl+N5lIsoq/CtIxnd3ENSwRjqhbitxyCGYmSMXt1MHST1CSIlWlhh9nG T/B2xhuUEwg0tUhgoz6llrzqzUsXiPcNu5xNTC3C9yAdGPireh8llfotI/Tr9c+1 I+yWzlWm7t4+66ApPqVoW4WoH2pTPFJUqJ645CBTLPHtcJ/zmeW64shLdPyFNtR7 eO7MDp8li/IWbwJWGgWTOGfG6hwz7ycfsWyyH+Q9BbETs+AmYW9QX3gyzSEi9yX1 9y5YHEaaKyKPo1iZyqQPf3aXn1L9O+blGWg== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefuddrtdekgdduheefucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdggtfgfnhhsuhgsshgtrhhisggvpdfu rfetoffkrfgpnffqhgenuceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnh htshculddquddttddmnecujfgurhephffvvefujghffffkgggtsehgtderredttdejnecu hfhrohhmpeetlhihshhsrgcutfhoshhsuceohhhisegrlhihshhsrgdrihhsqeenucggtf frrghtthgvrhhnpeetheevudfgjefghefhieejudelkeeljeegvdekueeuhffhgedvveef teevgeetieenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhroh hmpehhihesrghlhihsshgrrdhishdpnhgspghrtghpthhtohepfedpmhhouggvpehsmhht phhouhhtpdhrtghpthhtohepughomhhinhhitgdrrhhoughrihhguhgviiesrhhoughrih hguhgviidrohhrghdruhhkpdhrtghpthhtohepshhhhihmvghgrgesshhhhihmvghgrgdr ohhrghdruhhkpdhrtghpthhtohepuggvvhgvlhesshhpvggtthhruhhmqdhoshdrohhrgh X-ME-Proxy: Feedback-ID: i12284293:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Sat, 9 Nov 2024 16:46:53 -0500 (EST) Received: by sf.qyliss.net (Postfix, from userid 1000) id 4031728DAB056; Sat, 09 Nov 2024 22:46:51 +0100 (CET) From: Alyssa Ross To: Dom RODRIGUEZ Subject: Re: [PATCH v2] crosvm: Rename `--vhost-user-{fs,gpu}` args In-Reply-To: <5s7bk55k6d6vr6gywsx65pn2k7kqj5j4z722762vuqccey4yol@hx6vzlml76tg> References: <20240906224329.2336996-1-shymega@shymega.org.uk> <877cbnfmdf.fsf@alyssa.is> <87bk07am4z.fsf@alyssa.is> <5s7bk55k6d6vr6gywsx65pn2k7kqj5j4z722762vuqccey4yol@hx6vzlml76tg> Date: Sat, 09 Nov 2024 22:46:47 +0100 Message-ID: <874j4g5bco.fsf@alyssa.is> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Message-ID-Hash: ANGIWSO7P3J7QIN7QCOSULXNHXWDBZZ2 X-Message-ID-Hash: ANGIWSO7P3J7QIN7QCOSULXNHXWDBZZ2 X-MailFrom: hi@alyssa.is X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-devel.spectrum-os.org-0; header-match-devel.spectrum-os.org-1; header-match-devel.spectrum-os.org-2; header-match-devel.spectrum-os.org-3; header-match-devel.spectrum-os.org-4; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Dom Rodriguez , devel@spectrum-os.org X-Mailman-Version: 3.3.9 Precedence: list List-Id: Patches and low-level development discussion Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Dom RODRIGUEZ writes: > On 28.09.2024 16:27, Alyssa Ross wrote: >>Dom Rodriguez writes: >> >>> On 07.09.2024 18:40, Alyssa Ross wrote: >>>>Dom Rodriguez writes: >>>> >>>>> crosvm was producing warnings when using `--vhost-user-gpu` and >>>>> `--vhost-user-fs`. >>>>> >>>>> In this commit, I have adjusted the `crosvm` invocations to look >>>>> something like `--vhost-user $DEVICE,socket=3D$PATH`, where `$DEVICE`= is, in this case, >>>>> `gpu` or `fs`, and `$PATH` is the path to the Unix socket. >>>>> >>>>> Signed-off-by: Dom Rodriguez >>>>> --- >>>>> img/app/Makefile | 4 ++-- >>>>> release/checks/wayland/default.nix | 2 +- >>>>> 2 files changed, 3 insertions(+), 3 deletions(-) >>>>> >>>>> diff --git a/img/app/Makefile b/img/app/Makefile >>>>> index 3adf8c4..11ef6e1 100644 >>>>> --- a/img/app/Makefile >>>>> +++ b/img/app/Makefile >>>>> @@ -152,8 +152,8 @@ run-crosvm: $(imgdir)/appvm/blk/root.img start-vh= ost-user-gpu start-virtiofsd >>>>> --disk $(RUN_IMG) \ >>>>> -p "console=3DttyS0 root=3DPARTLABEL=3Droot" \ >>>>> --net tap-name=3Dtap0 \ >>>>> - --vhost-user-fs build/virtiofsd.sock:virtiofs0 \ >>>>> - --vhost-user-gpu build/vhost-user-gpu.sock \ >>>>> + --vhost-user fs,socket=3Dbuild/virtiofsd.sock:virtiofs0 \ >>>>> + --vhost-user gpu,socket=3Dbuild/vhost-user-gpu.sock \ >>>>> --vsock cid=3D3 \ >>>>> --serial type=3Dfile,hardware=3Dserial,path=3Dbuild/serial.log \ >>>>> --serial type=3Dstdout,hardware=3Dvirtio-console,stdin=3Dtrue \ >>>> >>>>This is still not right, I'm afraid. >>>> >>>>When I run nix-shell --run 'make clean && make run' VMM=3Dcrosvm in >>>>img/app, I get this error: >>>> >>>>[2024-09-07T16:36:32.592274891+00:00 ERROR crosvm] exiting with error 1= : failed to connect to vhost-user socket path build/virtiofsd.sock:virtiofs0 >>>> >>>>Probably the tag should also be a comma-separated key=3Dvalue option? >>>> >>>>(This doesn't have any automated test, because it's just part of the >>>>development environment, and setting up a test environment to resemble a >>>>development machine isn't trivial. Should be possible though.) >>> >>> It's bizarre. I've done some more testing, and it seems that >>> `--vhost-user` isn't *quite* there yet on feature parity with >>> `--vhost-user-fs`. Maybe I'm going wrong here, but it doesn't recognise >>> the tag as a k/v option. >>> >>> I have managed to get the tests running with `--vhost-user-fs`, but it >>> does look mismatched now. >>> >>> Would you prefer I revert the changes to `--vhost-user fs` =3D> >>> `--vhost-user-fs`? >> >>You're right! I've just spent the last little while looking around >>trying to figure out what's up here, and I think I've figured it out. >> >>In this commit[1] they made the vhost-user-fs tag optional, because it >>can now be set with virtiosfd instead of the VMM. This is probably >>good, because the more generic vhost-user becomes, the more hope >>Spectrum has of one day not needing Cloud Hypervisor patches. :) So we >>could try using --vhost-user fs for crosvm, and then passing --tag to >>virtiofsd, but it'd need to be tested with VMM=3Dqemu and >>VMM=3Dcloud-hypervisor as well, because I'm not sure whether they support >>a backend-provided tag. > > Finally got round to this. > > By the looks of it, currently `cloud-hypervisor` and QEMU do not support a > backend-provided tag. > > We could introduce an abstraction [function] in the Makefile over > `vhost-user-fs` arguments for each hypervisor, which we could use whilst > waiting for QEMU and cloud-hypervisor to support backend-provided tags > with `vhost-user-fs`, and in the meantime use the abstraction for > crosvm. > > I envision the abstraction as taking a few arguments: hypervisor, > virtiofsd socket path, and tag. The abstraction would then construct & > return the correct command-line argument for the hypervisor. We would > call the abstractive function in the call to the `run` Make target.=20 > > That way, we're prepared for the future. > > What do you think? Given that they don't support the optional protocol feature, I'd expect cloud-hypervisor and QEMU to just ignore the tag given to virtiofsd =E2=80= =94 can we not just set the tag on the virtiofsd invocation for crosvm, and keep setting it in the cloud-hypervisor and QEMU command lines for them? --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQRV/neXydHjZma5XLJbRZGEIw/wogUCZy/YSAAKCRBbRZGEIw/w ohujAP9KvCRyed/OtuOerulLpG7NDvSlc+y/d9NsLhoGtrouNQEAuGf3bS9PKteA TOpW2fWjX6XKSWd6bqwSH4LX71nRKQM= =GR7C -----END PGP SIGNATURE----- --=-=-=--