Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The key challenge for defining a shared virtual platform definition is to first identify the various device driver types such a platform must provide, and to evaluate if existing work so far (e.g. VIRTIO) covers what the automotive industry needs: 


(Virtual) DeviceExplanation

Champion
+ interested people

Completeness / Applicability evaluation

(tick) (warning) (error)

Comments and discussionSpec complete

Ticket to track completion

Block StorageFlash/Disk/persistent storage

Kai

(tick)

Possibly definition not enough since it is very generic. What happens below when the challenges

Kai working on evaluating these details. Let's investigate practical implementation of TRIM command, as example.

Spec Needs more of clear requirements

Included also automotive persistence requirements.


(tick) ready for review
(error)

Network

Access to (shared) physical ethernet

and guest-to-guest communication

Need volunteer to write chapter

TODO

include vsock stuff

(tick)

Think about writing info how to share a physical network in practice

(Create bridge between virtual device and physical)

(tick)

(warning) vsock should be moved to separate section?

(warning) Partly written...(tick) ready for review
Jiraserver




ConsoleText terminal inputGunnar

(tick)

As far as I can understand, VIRTIO should suffice.

DONE, please review

Done initial browsing of the specification. Opinions still pending.

Conclusion:

  • Follow VIRTIO
  • Consoles to VMs are needed during development but should be possible to turn off for production, for security reasons.


(tick) ready for review

Jira
server

JIRA
serverId121ddff2-c571-320f-9e4d-d5b9371533bd
keyHV-9

cryptoAccess to cryptographic services
(hardware accelerated)

(tick) With new features, it is enough.
We also added some

Now includes:

  • RNG
    TEE
    RPMB
(tick) ready for review
GPUGraphics hardwareMatti/Dmitry

See GPU Summary, VIRTIO GPU Operation Highlights pages

(tick) Draft spec – requirements written

(warning) Uncertainty (and lots of ongoing development) around 3D APIs - Vulkan progress, etc.

See GPU Summary page

and requirements in spec draft

(question)

(warning) 2019-06: Updated status?

(blue star) Still a moving target (3D).  This is reflected in specification



InputTraditionally keyboard/mouse/etc
- for automotive = expanded?
MattiMatti

Oct 2018: Input standard being discussed for inclusion in VIRTIO but accepted in principle. Let's wait a few weeks and look at proposal once in VIRTIO.

9pfs

Now part of VIRTIO 1.1

Mouse/touch events may need to remap coordinates in combined virtual systems but interface may still not be affected by this.


(error)
vsockCommunication between guest (VM)
and host (hypervisor)
What does the team think of this?

(tick)Covered in networking chapter(tick) ready for review

Filesystem

9pfs and other


9P = protocol to expose host (hypervisor)
file systems to the guest. FS=filesystem.
Gunnar

Use-cases: ?

Completeness: Protocol: (tick), VIRTIO spec: (warning) (see comment)

Need in Embedded/Automotive:

(error)

 (tick) None? Can we find a use-case?

Applicability:

(warning)

 (tick) For what it does, seems ok. But might not be really needed and therefore "not applicable". Is there something else/more needed?

Essentially used for "shared folder" capability between host & guest, as in desktop (or maybe some server) usage. Its applicability to embedded hypervisor usage, in which the "host" is not really being used by itself) seems questionable. What's the use-case?

In VIRTIO spec: A PCI type device can indicate that it is going to use the 9P protocol. The specification also has 9P as a specific separate device type. Other than that, I found no further description of such a device type. The protocol is specified elsewhere and complemented by scattered information regarding the specific implementations (Xen, KVM, QEMU, ...)

The protocol seems proven and supposedly OK for what it does. Possibly more security features needed, depending on use-case. VIRTIO however seems to defer the definition completely to "somewhere else"? At least a reference to a canonical specification would seem appropriate.

It is a minimalistic network file-system protocol. It seems apt for the task. Other network protocols like NFS, SMB/SAMBA etc. would be too heavy. It feels a bit esoteric, and while "reinventing" is bad, in this simple case would not be the worst ever, if VIRTIO had defined something else. Flexibility and security features seem somewhat glossed over. There's basically only "fixed user" or "pass-through" for mapping ownership on files in guest/host.

Links: Virtio 1.0 spec : {PCI-9P, 9P device type}.
Kernel support: Xen/Linux 4.12+ FE driver
Xen implementation details

A note on its documentation/definition not being very precise

A set of man pages seemingly defining P9? intro, others

QEMU instruction how to set up a VirtFS (P9).
Example/info how to natively mount a 9P network filesystem,
Source code for 9pfs FUSE driver

Example how to set up in Linux system

(tick)

(question) OK to have such a verbose chapter?

OK to be imprecise?

vIOMMU

IOMMU coordinates of DMA devices'
connection to memory.

Dmitry

See IOMMU Summary page

Applicability:

(tick) Limit guest devices' scope to access system memory during DMA

(tick) Enable scatter-gather accesses due to remapping (DMA buffers do not need to be physically-contiguous)

(question) Nested virtualization. Any use-cases for automotive?
(tick) Group conclusion: Not needed, generally speaking
→ see comments

ARM is actively working on the specification, more features are coming.

Nested virtualization? The use of Linux Containers inside a VM was mentioned. That in itself is not really nested virtualization. Namespace-based containers, is just a kernel feature providing separation independent of a hypervisor. However, Kata Containers is an approach to tie Linux containers into a hypervisor layer, making them "fully" virtualized. A theoretical situation arises that involves the use of Kata Containers on a Linux system that itself already runs in a VM. That might constitute an example of nested virtualization, but it was decided that this is not a mainstream idea, possibly not supported or feasible, and in each case likely more trouble than it is worth. "Flattening" the virtualization approach so that all units still run on one hypervisor is a likely outcome. Further research into partitioning methods is likely but for now this falls outside of a mainstream automotive virtual platform definition. We highlighted that Linux containers in their normal namespace based implementation are already a very useful system partition tool and it can be trivially applied also if the Linux kernel runs in a VM.

(tick)(question)

Links: Virtio 1.0 spec : {PCI-9P, 9P device type}.
Kernel support: Xen/Linux 4.12+ FE driver
Xen implementation details

A note on its documentation/definition not being very precise

A set of man pages seemingly defining P9? intro, others

QEMU instruction how to set up a VirtFS (P9).
Example/info how to natively mount a 9P network filesystem,
Source code for 9pfs FUSE driver

(tick) ready for review

(question) OK to have such a verbose chapter?  Maybe some more work...



vIOMMU

IOMMU coordinates of DMA devices'
connection to memory.

Dmitry

See IOMMU Summary page

Applicability:

(tick) Limit guest devices' scope to access system memory during DMA

(tick) Enable scatter-gather accesses due to remapping (DMA buffers do not need to be physically-contiguous)

(question) Nested virtualization. Any use-cases for automotive?
(tick) Group conclusion: Not needed nested virtualization - however there are still two levels because applications in guest are used to set up IOMMU (protection between applications) and then the VMs themselves are another level.   These levels drive the need for a virtualized IOMMU layer (and/or hardware support for the same)

ARM is actively working on the specification, more features are coming.

Nested virtualization? The use of Linux Containers inside a VM was mentioned. That in itself is not really nested virtualization. Namespace-based containers, is just a kernel feature providing separation independent of a hypervisor. However, Kata Containers is an approach to tie Linux containers into a hypervisor layer, making them "fully" virtualized. A theoretical situation arises that involves the use of Kata Containers on a Linux system that itself already runs in a VM. That might constitute an example of nested virtualization, but it was decided that this is not a mainstream idea, possibly not supported or feasible, and in each case likely more trouble than it is worth. "Flattening" the virtualization approach so that all units still run on one hypervisor is a likely outcome. Further research into partitioning methods is likely but for now this falls outside of a mainstream automotive virtual platform definition. We highlighted that Linux containers in their normal namespace based implementation are already a very useful system partition tool and it can be trivially applied also if the Linux kernel runs in a VM.

(warning)  Chapter has been written.

But:

Need a group review of text (verbose) and consider the comments here on the left. 

And also  VIRTIO parts have not been merged to official spec version.


Audio
Matti

 (warning)  VIRTIO proposal is being discussed - still pending 2019-09-25

Some info on Linux/Xen code here:
HVWS: Xen input and experience on Audio, Display, Input and TEE

Artem Mygaiev - can this comment be removed?  Should it affect the spec?



(warning) Information is quite complete.  and good understanding written.  Needs cleanup to become a proper chapter
Sensors

Automotive sensors:


Artem

(error)  Not covered by VIRTIO specifically.
Considering SCMI over VIRTIO as a future standard.


Artem proposed that Systems Control Management Interface (SCMI) protocol as a flexible and an appropriate abstraction for sensors. It is also appropriate for controlling power-management and related things. The hardware access implementation is according to ARM offloaded to a "Systems Control Processor" but this is a virtual concept. It could be a dedicated core in some cases, perhaps in others not. EPAM/Xen tried out putting code in ARM-TF, to act as this SCP.

SCMI destined (?) to become a ARM-wide standard in a currently fragmented reality.

Presentation attached (PDF)

Upper protocol defined, but could imagine different lower transport. One mailbox-style transport is kind-of defined by ARM spec? Discussion if VIRTIO transport would be appropriate. A "SCMI device" type added to VIRTIO?

Challenges:

  • Current situation in ARM is fragmented with many overlapping unique APIs across chip vendors.
  • Is this doable also on x86, and is it likely to be adopted?
  • Discuss applicability beyond "sensors" and where boundaries are drawn.

Reference:

What about PINCTRL, and handling the many multiplexed pins in a modern SoC. Any remaining need for lower-level protocols for accessing/virtualizing hardware?

AudioMatti

 TODO

Some info on Linux/Xen code here:

HVWS: Xen input and experience on Audio, Display, Input and TEE

(warning) Updates from ongoing VIRTIO standards process needed.

(error)Sensors

Automotive sensors:

Artem

Automotive sensors? Radar/LiDAR/? (or are they separate ECUs?)

Standard embedded sensor (ambient light...)

Some OS have requirements - eg. Android requires orientation sensor.

LIN-bus:

  • Source code for linux-lin driver (for Linux, not necessarily virtual environment):
  • Paper by Czech Technical University & Volkswagen Group Research:
    LIN based on SocketCAN → 1. OSADL article, 2. paper (PDF).
    • The paper concludes that LIN data frames are similar enough to CAN frames that it can reuse CAN software infrastructure (such as the SocketCAN standard). LIN is a serial bus, implemented with a UARTs, and therefore standard UART device drivers would be used. For virtual environments, we can rely on the same conclusions, and therefore refer to the answer given for CAN.
    • On the other hand, LIN is most popular for its simplicity / low cost (even lower than CAN) and used in very simple ECUs or to/from input devices like switches, knobs and buttons. On the larger CPU it is likely to be run by a separate dedicated microcontroller, or at least small on-chip CPU core. Therefore it can often be considered out-of-scope for the CPU that implements virtualization.
(error)CANFranz

virtio-can: VIRTIO-based CAN driver

Ethernet (incl. AvB/TSN)

Nikola (TSN)

Need new volunteer to complete it, perhaps from GHS?

The required features are not present in the network virtio devices as of virtio 1.0.

(warning) Is this → applicable enough to move into specification as requirements? --> 

Must have requirements:

  • IEEE 802.1AS compatible egress and ingress timestamps on ethernet frames available in the virtio consumer OS

Good to have:

General architectural considerations:

  • What if there is more than one consumer of the IEEE 802.1AS defined network timebase on the same system?
Bluetooth

Sang-bum

+OpenSynergy with BT experience

Is it possible? Needed?Memory Balloon DeviceGunnar



CPUs/SoCs have "internal" sensors too. Relating to temperature and power mgmt. Some internal control tweaks for power management (core frequency / voltage) are like tiny internal actuators. Virtual access to those? Same or different APIs?

(warning) So far, zero feedback on SCMI proposal...
→ Put into spec as proposal and move from there.

Artem proposed that Systems Control Management Interface (SCMI) protocol is flexible and an appropriate abstraction for sensors. It is also appropriate for controlling power-management and related things. The hardware access implementation is according to ARM offloaded to a "Systems Control Processor" but this is a virtual concept. It could be a dedicated core in some cases, perhaps in others not. EPAM/Xen tried out putting code in ARM-TF, to act as this SCP.

SCMI destined (?) to become a ARM-wide standard in a currently fragmented reality.

Presentation attached (PDF)

Upper protocol defined, but could imagine different lower transport. One mailbox-style transport is kind-of defined by ARM spec? Discussion if VIRTIO transport would be appropriate. A "SCMI device" type added to VIRTIO?

Challenges:

  • Current situation in ARM is fragmented with many overlapping unique APIs across chip vendors.
  • Is this doable also on x86, and is it likely to be adopted?
  • Discuss applicability beyond "sensors" and where boundaries are drawn.

Reference:

What about PINCTRL, and handling the many multiplexed pins in a modern SoC. Any remaining need for lower-level protocols for accessing/virtualizing hardware?

(warning) Very short chapter so far...  Not complete IMHOMedia Acceleration (VPUP, IPU, CODEC)Hardware support for codec/processing
Abstraction of SoC specifics
DSPs
Tensor processors
Artem

 TODO

VPU = "AI" CPU optimized for visual recognition(error)USBFranz
Example Assigning Host USB device to a Guest VM in KVM, here:

https://www.linux-kvm.org/page/USB_Host_Device_Assigned_to_Guest

(tick) Draft chapter written – see draft spec.

Which use cases do we want to address?

•USB 2.0 (EHCI controller)
•USB 3.0 (xHCI controllers will replace ECHI)
•USB C
•Host only
•Device Classes:

  • Mass storage. Enable use of USB device with volume provider
  • Communications (e.g. serial, Ethernet)
  • Human interface (e.g. keyboard, mouse)

•On-The-Go (system can function as both USB host and USB device)
•Hot-plug (partial support):

  • Static configuration of device “tree”. A device can be plugged into a port. Dynamically detect device type.
  • Device tree cannot grow dynamically, i.e. cannot plug in a hub
(warning) Needs update – see minutes.

Other Serial devices?

(Where does LIN, etc. fit in?)

(error) Spec chapter needs to be written.


Some OS have requirements that must be met by "platform" - eg. Android requires orientation sensor.


(warning) Good work done. 

Split out GPIO to separate chapter. 

Placeholder also for describing HW passthrough (in general)

All 3 need another review and cleanup to be complete.

(warning) Consider platform requirement for sensors that must exist (for Android etc.)


Media Acceleration (VPUP, IPU, CODEC)Hardware support for codec/processing

Artem

→ Dmitry

(warning)  Proposal to VIRTIO might come (OpenSynergy)


VPU
= "AI" CPU optimized for visual recognition



(warning) Prel. chapter written. 

coprocessors and other
dedicated hardware features

Abstraction of SoC specifics
DSPs
Tensor processors

(error)  Not really in VIRTIO scope

Matti: virtualize functions, not devices.

Gunnar: Analysis might extract some functions out of these...


(error) (not sure yet if we expect to cover it)
USB



Example Assigning Host USB device to a Guest VM in KVM, here:

https://www.linux-kvm.org/page/USB_Host_Device_Assigned_to_Guest


Which use cases do we want to address?

•USB 2.0 (EHCI controller)
•USB 3.0 (xHCI controllers will replace ECHI)
•USB C
•Host only
•Device Classes:

  • Mass storage. Enable use of USB device with volume provider
  • Communications (e.g. serial, Ethernet)
  • Human interface (e.g. keyboard, mouse)

•On-The-Go (system can function as both USB host and USB device)
•Hot-plug (partial support):

  • Static configuration of device “tree”. A device can be plugged into a port. Dynamically detect device type.
  • Device tree cannot grow dynamically, i.e. cannot plug in a hub

(warning) Needs update – see minutes.



Other Serial devices?

... and LIN bus




(error) VIRTIO applicability needs analysis

(error) Spec chapter needs to be written.

LIN-bus:

  • Source code for linux-lin driver (for Linux, not necessarily virtual environment):
  • Paper by Czech Technical University & Volkswagen Group Research:
    LIN based on SocketCAN → 1. OSADL article, 2. paper (PDF).
    • The paper concludes that LIN data frames are similar enough to CAN frames that it can reuse CAN software infrastructure (such as the SocketCAN standard). LIN is a serial bus, implemented with a UARTs, and therefore standard UART device drivers would be used. For virtual environments, we can rely on the same conclusions, and therefore refer to the answer given for CAN.
    • On the other hand, LIN is most popular for its simplicity / low cost (even lower than CAN) and used in very simple ECUs or to/from input devices like switches, knobs and buttons. On the larger CPU it is likely to be run by a separate dedicated microcontroller, or at least small on-chip CPU core. Therefore it can often be considered out-of-scope for the CPU that implements virtualization.
(error)
CAN

(error)


virtio-can: VIRTIO-based CAN driver(error) Decide opinion and write chapter
Time Sensitive Networks

Nikola (TSN)

Need new volunteer to complete it, perhaps from GHS?

The required features are not present in the network virtio devices as of virtio 1.0.


(warning) Is this → applicable enough to move into specification as requirements? --> 

Must have requirements:

  • IEEE 802.1AS compatible egress and ingress timestamps on ethernet frames available in the virtio consumer OS

Good to have:

General architectural considerations:

  • What if there is more than one consumer of the IEEE 802.1AS defined network timebase on the same system?
(error)
Bluetooth

OpenSynergy with BT experience ?

(error) Not in VIRTIO scope



Virtualization of BT hardware might not be required.  However, commenting on various system designs seems appropriate.

Example: There exists an interface for virtualized audio device (virtio-sound), but Bluetooth is also an audio device (among other things...)  What does this mean for how to build an architecture that (for example) uses both virtualization for audio, and bluetooth technologies.

(star) Write at least a Discussions chapter.


Memory Balloon Device
Gunnar(tick) In VIRTIO.  Applicability to automative is questionable.

(warning) May be partly applicable - I could write something here to get us started. - Gunnar


(error) TODO

Random Number Generator

Although used also for crypto. Look at what VIRTIO proposes. (Discussion should cover hardware-supported random generator, of course).




(tick)Covered in the Crypto chapter.(tick)
Watchdog

Very important for embedded systems... Let's see what is there and what we need to do.


Planned SBSA presentation from ARM as a starting point.(error)


All related JIRA Tickets


Jira
serverJIRA
columnskey,summary,type,created,updated,due,assignee,reporter,priority,status,resolution
maximumIssues20
jqlQuery"Epic Link" = HV-6
serverId121ddff2-c571-320f-9e4d-d5b9371533bd

...