From: Marc Zyngier <maz@kernel.org>
To: Mark Brown <broonie@kernel.org>
Cc: Shuah Khan <shuah@kernel.org>, James Morse <james.morse@arm.com>,
Alexandru Elisei <alexandru.elisei@arm.com>,
Suzuki K Poulose <suzuki.poulose@arm.com>,
linux-arm-kernel@lists.infradead.org,
kvmarm@lists.cs.columbia.edu, linux-kselftest@vger.kernel.org
Subject: Re: [PATCH] kselftest: kvm/arm64: Skip tests if we can't create a vgic-v3
Date: Wed, 26 Jan 2022 13:32:28 +0000 [thread overview]
Message-ID: <87bkzy7hcj.wl-maz@kernel.org> (raw)
In-Reply-To: <YfFKzWxNd5l26Ebk@sirena.org.uk>
aOn Wed, 26 Jan 2022 13:21:17 +0000,
Mark Brown <broonie@kernel.org> wrote:
>
> [1 <text/plain; us-ascii (7bit)>]
> On Wed, Jan 26, 2022 at 01:05:01PM +0000, Marc Zyngier wrote:
> > Mark Brown <broonie@kernel.org> wrote:
>
> > > > So you now only test whether it is possible to create a virtual GICv3,
> > > > but don't actually create it. How does this work?
>
> > > Oh, that's rather obscure in the API - so the file descriptor returned
> > > if the test flag is specified can't actually be used?
>
> > No file descriptor is returned at all from the kernel, so you should
> > always get -1 as populated by kvm_create_device().
>
> > See virt/kvm/kvm_main.c::kvm_ioctl_create_device().
>
> Ugh, right - the descriptor is returned separately to the return code
> but is then mapped onto the return code by the library since the library
> just aborts on error in the non-test case and in the test case the kernel
> returns an inverted boolean which gets passed straight through. Like I
> say the API seems a bit confusing here.
That's a very... "kind" way of putting it.
M.
--
Without deviation from the norm, progress is not possible.
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
prev parent reply other threads:[~2022-01-26 13:33 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-25 19:28 [PATCH] kselftest: kvm/arm64: Skip tests if we can't create a vgic-v3 Mark Brown
2022-01-25 19:48 ` Shuah Khan
2022-01-26 1:23 ` Ricardo Koller
2022-01-26 9:07 ` Marc Zyngier
2022-01-26 12:52 ` Mark Brown
2022-01-26 13:05 ` Marc Zyngier
2022-01-26 13:21 ` Mark Brown
2022-01-26 13:32 ` Marc Zyngier [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87bkzy7hcj.wl-maz@kernel.org \
--to=maz@kernel.org \
--cc=alexandru.elisei@arm.com \
--cc=broonie@kernel.org \
--cc=james.morse@arm.com \
--cc=kvmarm@lists.cs.columbia.edu \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=shuah@kernel.org \
--cc=suzuki.poulose@arm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).