From: "Alex Bennée" <alex.bennee@linaro.org>
To: Stefano Stabellini <stefano.stabellini@xilinx.com>
Cc: AKASHI Takahiro <takahiro.akashi@linaro.org>,
Stefan Hajnoczi <stefanha@redhat.com>,
Stefano Stabellini <sstabellini@kernel.org>,
Stratos Mailing List <stratos-dev@op-lists.linaro.org>,
virtio-dev@lists.oasis-open.org,
Arnd Bergmann <arnd.bergmann@linaro.org>,
Viresh Kumar <viresh.kumar@linaro.org>,
Jan Kiszka <jan.kiszka@siemens.com>,
Carl van Schaik <cvanscha@qti.qualcomm.com>,
pratikp@quicinc.com, Srivatsa Vaddagiri <vatsa@codeaurora.org>,
Jean-Philippe Brucker <jean-philippe@linaro.org>,
Mathieu Poirier <mathieu.poirier@linaro.org>,
Wei.Chen@arm.com, olekstysh@gmail.com,
Oleksandr_Tyshchenko@epam.com, Bertrand.Marquis@arm.com,
Artem_Mygaiev@epam.com, julien@xen.org, jgross@suse.com,
paul@xen.org, xen-devel@lists.xen.org,
Elena Afanasova <eafanasova@gmail.com>
Subject: [virtio-dev] Re: Enabling hypervisor agnosticism for VirtIO backends
Date: Tue, 14 Sep 2021 15:25:22 +0100 [thread overview]
Message-ID: <878rzzusyp.fsf@linaro.org> (raw)
In-Reply-To: <alpine.DEB.2.21.2109131615570.10523@sstabellini-ThinkPad-T480s>
Stefano Stabellini <stefano.stabellini@xilinx.com> writes:
> On Mon, 6 Sep 2021, AKASHI Takahiro wrote:
>> > the second is how many context switches are involved in a transaction.
>> > Of course with all things there is a trade off. Things involving the
>> > very tightest latency would probably opt for a bare metal backend which
>> > I think would imply hypervisor knowledge in the backend binary.
>>
>> In configuration phase of virtio device, the latency won't be a big matter.
>> In device operations (i.e. read/write to block devices), if we can
>> resolve 'mmap' issue, as Oleksandr is proposing right now, the only issue is
>> how efficiently we can deliver notification to the opposite side. Right?
>> And this is a very common problem whatever approach we would take.
>>
>> Anyhow, if we do care the latency in my approach, most of virtio-proxy-
>> related code can be re-implemented just as a stub (or shim?) library
>> since the protocols are defined as RPCs.
>> In this case, however, we would lose the benefit of providing "single binary"
>> BE.
>> (I know this is is an arguable requirement, though.)
>
> In my experience, latency, performance, and security are far more
> important than providing a single binary.
>
> In my opinion, we should optimize for the best performance and security,
> then be practical on the topic of hypervisor agnosticism. For instance,
> a shared source with a small hypervisor-specific component, with one
> implementation of the small component for each hypervisor, would provide
> a good enough hypervisor abstraction. It is good to be hypervisor
> agnostic, but I wouldn't go extra lengths to have a single binary.
I agree it shouldn't be a primary goal although a single binary working
with helpers to bridge the gap would make a cool demo. The real aim of
agnosticism is avoid having multiple implementations of the backend
itself for no other reason than a change in hypervisor.
> I cannot picture a case where a BE binary needs to be moved between
> different hypervisors and a recompilation is impossible (BE, not FE).
> Instead, I can definitely imagine detailed requirements on IRQ latency
> having to be lower than 10us or bandwidth higher than 500 MB/sec.
>
> Instead of virtio-proxy, my suggestion is to work together on a common
> project and common source with others interested in the same problem.
>
> I would pick something like kvmtool as a basis. It doesn't have to be
> kvmtools, and kvmtools specifically is GPL-licensed, which is
> unfortunate because it would help if the license was BSD-style for ease
> of integration with Zephyr and other RTOSes.
This does imply making some choices, especially the implementation
language. However I feel that C is really the lowest common denominator
here and I get the sense that people would rather avoid it if they could
given the potential security implications of a bug prone back end. This
is what is prompting interest in Rust.
> As long as the project is open to working together on multiple
> hypervisors and deployment models then it is fine. For instance, the
> shared source could be based on OpenAMP kvmtool [1] (the original
> kvmtool likely prefers to stay small and narrow-focused on KVM). OpenAMP
> kvmtool was created to add support for hypervisor-less virtio but they
> are very open to hypervisors too. It could be a good place to add a Xen
> implementation, a KVM fatqueue implementation, a Jailhouse
> implementation, etc. -- work together toward the common goal of a single
> BE source (not binary) supporting multiple different deployment models.
>
>
> [1] https://github.com/OpenAMP/kvmtool
--
Alex Bennée
---------------------------------------------------------------------
To unsubscribe, e-mail: virtio-dev-unsubscribe@lists.oasis-open.org
For additional commands, e-mail: virtio-dev-help@lists.oasis-open.org
WARNING: multiple messages have this Message-ID (diff)
From: "Alex Bennée" <alex.bennee@linaro.org>
To: Stefano Stabellini <stefano.stabellini@xilinx.com>
Cc: AKASHI Takahiro <takahiro.akashi@linaro.org>,
Stefan Hajnoczi <stefanha@redhat.com>,
Stefano Stabellini <sstabellini@kernel.org>,
Stratos Mailing List <stratos-dev@op-lists.linaro.org>,
virtio-dev@lists.oasis-open.org,
Arnd Bergmann <arnd.bergmann@linaro.org>,
Viresh Kumar <viresh.kumar@linaro.org>,
Jan Kiszka <jan.kiszka@siemens.com>,
Carl van Schaik <cvanscha@qti.qualcomm.com>,
pratikp@quicinc.com, Srivatsa Vaddagiri <vatsa@codeaurora.org>,
Jean-Philippe Brucker <jean-philippe@linaro.org>,
Mathieu Poirier <mathieu.poirier@linaro.org>,
Wei.Chen@arm.com, olekstysh@gmail.com,
Oleksandr_Tyshchenko@epam.com, Bertrand.Marquis@arm.com,
Artem_Mygaiev@epam.com, julien@xen.org, jgross@suse.com,
paul@xen.org, xen-devel@lists.xen.org,
Elena Afanasova <eafanasova@gmail.com>
Subject: Re: Enabling hypervisor agnosticism for VirtIO backends
Date: Tue, 14 Sep 2021 15:25:22 +0100 [thread overview]
Message-ID: <878rzzusyp.fsf@linaro.org> (raw)
In-Reply-To: <alpine.DEB.2.21.2109131615570.10523@sstabellini-ThinkPad-T480s>
Stefano Stabellini <stefano.stabellini@xilinx.com> writes:
> On Mon, 6 Sep 2021, AKASHI Takahiro wrote:
>> > the second is how many context switches are involved in a transaction.
>> > Of course with all things there is a trade off. Things involving the
>> > very tightest latency would probably opt for a bare metal backend which
>> > I think would imply hypervisor knowledge in the backend binary.
>>
>> In configuration phase of virtio device, the latency won't be a big matter.
>> In device operations (i.e. read/write to block devices), if we can
>> resolve 'mmap' issue, as Oleksandr is proposing right now, the only issue is
>> how efficiently we can deliver notification to the opposite side. Right?
>> And this is a very common problem whatever approach we would take.
>>
>> Anyhow, if we do care the latency in my approach, most of virtio-proxy-
>> related code can be re-implemented just as a stub (or shim?) library
>> since the protocols are defined as RPCs.
>> In this case, however, we would lose the benefit of providing "single binary"
>> BE.
>> (I know this is is an arguable requirement, though.)
>
> In my experience, latency, performance, and security are far more
> important than providing a single binary.
>
> In my opinion, we should optimize for the best performance and security,
> then be practical on the topic of hypervisor agnosticism. For instance,
> a shared source with a small hypervisor-specific component, with one
> implementation of the small component for each hypervisor, would provide
> a good enough hypervisor abstraction. It is good to be hypervisor
> agnostic, but I wouldn't go extra lengths to have a single binary.
I agree it shouldn't be a primary goal although a single binary working
with helpers to bridge the gap would make a cool demo. The real aim of
agnosticism is avoid having multiple implementations of the backend
itself for no other reason than a change in hypervisor.
> I cannot picture a case where a BE binary needs to be moved between
> different hypervisors and a recompilation is impossible (BE, not FE).
> Instead, I can definitely imagine detailed requirements on IRQ latency
> having to be lower than 10us or bandwidth higher than 500 MB/sec.
>
> Instead of virtio-proxy, my suggestion is to work together on a common
> project and common source with others interested in the same problem.
>
> I would pick something like kvmtool as a basis. It doesn't have to be
> kvmtools, and kvmtools specifically is GPL-licensed, which is
> unfortunate because it would help if the license was BSD-style for ease
> of integration with Zephyr and other RTOSes.
This does imply making some choices, especially the implementation
language. However I feel that C is really the lowest common denominator
here and I get the sense that people would rather avoid it if they could
given the potential security implications of a bug prone back end. This
is what is prompting interest in Rust.
> As long as the project is open to working together on multiple
> hypervisors and deployment models then it is fine. For instance, the
> shared source could be based on OpenAMP kvmtool [1] (the original
> kvmtool likely prefers to stay small and narrow-focused on KVM). OpenAMP
> kvmtool was created to add support for hypervisor-less virtio but they
> are very open to hypervisors too. It could be a good place to add a Xen
> implementation, a KVM fatqueue implementation, a Jailhouse
> implementation, etc. -- work together toward the common goal of a single
> BE source (not binary) supporting multiple different deployment models.
>
>
> [1] https://github.com/OpenAMP/kvmtool
--
Alex Bennée
next prev parent reply other threads:[~2021-09-14 14:34 UTC|newest]
Thread overview: 66+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-04 9:04 [virtio-dev] Enabling hypervisor agnosticism for VirtIO backends Alex Bennée
2021-08-04 19:20 ` Stefano Stabellini
2021-08-11 6:27 ` AKASHI Takahiro
2021-08-14 15:37 ` Oleksandr Tyshchenko
2021-08-16 10:04 ` Wei Chen
2021-08-17 8:07 ` AKASHI Takahiro
2021-08-17 8:39 ` Wei Chen
2021-08-18 5:38 ` AKASHI Takahiro
2021-08-18 8:35 ` Wei Chen
2021-08-20 6:41 ` AKASHI Takahiro
2021-08-26 9:40 ` AKASHI Takahiro
2021-08-26 12:10 ` Wei Chen
2021-08-30 19:36 ` Christopher Clark
2021-08-30 19:53 ` [virtio-dev] " Christopher Clark
2021-08-30 19:53 ` Christopher Clark
2021-09-02 7:19 ` AKASHI Takahiro
2021-09-07 0:57 ` [virtio-dev] " Christopher Clark
2021-09-07 0:57 ` Christopher Clark
2021-09-07 11:55 ` AKASHI Takahiro
2021-09-07 18:09 ` [virtio-dev] " Christopher Clark
2021-09-07 18:09 ` Christopher Clark
2021-09-10 3:12 ` AKASHI Takahiro
2021-08-31 6:18 ` AKASHI Takahiro
2021-09-01 11:12 ` Wei Chen
2021-09-01 12:29 ` AKASHI Takahiro
2021-09-01 16:26 ` Oleksandr Tyshchenko
2021-09-02 1:30 ` Wei Chen
2021-09-02 1:50 ` Wei Chen
[not found] ` <0100017b33e585a5-06d4248e-b1a7-485e-800c-7ead89e5f916-000000@email.amazonses.com>
2021-08-12 7:55 ` [Stratos-dev] " François Ozog
2021-08-13 5:10 ` AKASHI Takahiro
2021-09-01 8:57 ` [virtio-dev] " Alex Bennée
2021-09-01 8:57 ` Alex Bennée
2021-08-17 10:41 ` [virtio-dev] " Stefan Hajnoczi
2021-08-17 10:41 ` Stefan Hajnoczi
2021-08-23 6:25 ` AKASHI Takahiro
2021-08-23 9:58 ` [virtio-dev] " Stefan Hajnoczi
2021-08-23 9:58 ` Stefan Hajnoczi
2021-08-25 10:29 ` AKASHI Takahiro
2021-08-25 15:02 ` [virtio-dev] " Stefan Hajnoczi
2021-08-25 15:02 ` Stefan Hajnoczi
2021-09-01 12:53 ` [virtio-dev] " Alex Bennée
2021-09-01 12:53 ` Alex Bennée
2021-09-02 9:12 ` [virtio-dev] " Stefan Hajnoczi
2021-09-02 9:12 ` Stefan Hajnoczi
2021-09-03 8:06 ` AKASHI Takahiro
2021-09-03 9:28 ` [virtio-dev] " Alex Bennée
2021-09-03 9:28 ` Alex Bennée
2021-09-06 2:23 ` AKASHI Takahiro
2021-09-07 2:41 ` [virtio-dev] Re: [Stratos-dev] " Christopher Clark
2021-09-07 2:41 ` Christopher Clark
2021-09-10 2:50 ` AKASHI Takahiro
2021-09-10 9:35 ` [virtio-dev] " Alex Bennée
2021-09-10 9:35 ` Alex Bennée
2021-09-13 23:51 ` Stefano Stabellini
2021-09-14 6:08 ` [Stratos-dev] " François Ozog
2021-09-14 14:25 ` Alex Bennée [this message]
2021-09-14 14:25 ` Alex Bennée
2021-09-14 17:38 ` [Stratos-dev] " Trilok Soni
2021-09-15 3:29 ` Stefano Stabellini
2021-09-15 23:50 ` Trilok Soni
2021-09-16 2:11 ` Stefano Stabellini
2021-08-05 15:48 ` [virtio-dev] " Stefan Hajnoczi
2021-08-19 9:11 ` [virtio-dev] " Matias Ezequiel Vara Larsen
[not found] ` <20210820060558.GB13452@laputa>
2021-08-21 14:08 ` Matias Ezequiel Vara Larsen
[not found] ` <20210823012029.GB40863@laputa>
2021-10-04 11:33 ` Matias Ezequiel Vara Larsen
2021-09-01 8:43 ` Alex Bennée
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=878rzzusyp.fsf@linaro.org \
--to=alex.bennee@linaro.org \
--cc=Artem_Mygaiev@epam.com \
--cc=Bertrand.Marquis@arm.com \
--cc=Oleksandr_Tyshchenko@epam.com \
--cc=Wei.Chen@arm.com \
--cc=arnd.bergmann@linaro.org \
--cc=cvanscha@qti.qualcomm.com \
--cc=eafanasova@gmail.com \
--cc=jan.kiszka@siemens.com \
--cc=jean-philippe@linaro.org \
--cc=jgross@suse.com \
--cc=julien@xen.org \
--cc=mathieu.poirier@linaro.org \
--cc=olekstysh@gmail.com \
--cc=paul@xen.org \
--cc=pratikp@quicinc.com \
--cc=sstabellini@kernel.org \
--cc=stefanha@redhat.com \
--cc=stefano.stabellini@xilinx.com \
--cc=stratos-dev@op-lists.linaro.org \
--cc=takahiro.akashi@linaro.org \
--cc=vatsa@codeaurora.org \
--cc=viresh.kumar@linaro.org \
--cc=virtio-dev@lists.oasis-open.org \
--cc=xen-devel@lists.xen.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.