The virtio CAN guest driver entered mainline with Linux 7.2 on 16 August 2026, four years after the first RFC, and AGL Vibrant Vimba already carries it as a backport onto its 6.18 kernel. What merged is the guest half: the guest cannot set bit timing, sees no error-passive state and has no CAN XL path, because the VIRTIO 1.4 specification gives it none. The host half is still in flight, with no virtio CAN device in mainline QEMU and the rust-vmm backend described by its own README as work in progress.
A Linux guest running under a hypervisor in a vehicle has commonly reached a CAN bus in one of two ways: the controller is passed through to that one guest, or the integrator carries an out-of-tree paravirtual driver. The virtio CAN driver that merged in Linux 7.2 offers a third, standard way, in which several guests share one physical controller through a device that the hypervisor or a host process implements. This post is for engineers building or evaluating a Linux guest on an automotive hypervisor. It sets out what merged, what the guest can and cannot see through it, which half of the work is still unmerged, and which kernels carry it as of 17 November 2026.
What merged, and by which route
The anchor is a single commit, 083082a4e6d8, “can: virtio: Add virtio CAN driver”. Its author date is 26 May 2026, which is the posting date of the fifteenth revision of the series by Matias Ezequiel Vara Larsen of Red Hat. It was committed by Michael S. Tsirkin on 10 June 2026, and the earliest tag containing it is v7.2-rc1, tagged on 28 June 2026. Linux 7.2 itself was tagged on 16 August 2026. The file drivers/net/can/virtio_can.c is absent at v7.1, which was tagged on 14 June 2026.
The commit touches five files: a new 1,022-line driver, a new 78-line UAPI header include/uapi/linux/virtio_can.h, a Kconfig entry CAN_VIRTIO_CAN (tristate, depends on VIRTIO, default n), a one-line Makefile rule and a MAINTAINERS entry naming Harald Mommer and Matias Ezequiel Vara Larsen, with both the virtualisation and linux-can lists. The trailers name Harald Mommer, Mikhail Golubev-Ciuchea and Marc Kleine-Budde as co-developers and Francesco Valla as reviewer and tester.
It came through the virtio tree, not the CAN maintainers’ tree. On 10 June Tsirkin replied to v15 that it was in linux-next and asked Marc Kleine-Budde and Vincent Mailhol whether to send it upstream; in the two archives I read, no reply from either is visible, and the commit carries no Acked-by from a CAN maintainer.
Four years from RFC to mainline
The VIRTIO 1.2 committee specification, tagged in July 2022, already reserved device ID 36 for a CAN device in its device-ID table, but contained no CAN device section. Harald Mommer of OpenSynergy posted “[RFC PATCH 1/1] can: virtio: Initial virtio CAN driver” on 25 August 2022, describing bus-off handling as code complete but “largely untested”. Marc Kleine-Budde’s first question, two days later, was whether an open-source implementation of the host side existed. The device specification text was committed to the OASIS virtio-spec repository on 9 June 2023. The driver went through RFC v4 on 7 June 2023 and a non-RFC v5 on 8 January 2024, both sent by Mikhail Golubev-Ciuchea, and then stalled.
Matias Ezequiel Vara Larsen picked up v5 in October 2025. The review that month with Francesco Valla settled how a failed transmission is reported: a kernel log warning was judged insufficient because the sending application cannot see it, so the driver now delivers a CAN error frame with CAN_ERR_CRTL_UNSPEC and counts the frame as dropped. Versions v6 to v15 followed between 31 October 2025 and 26 May 2026, mostly fixing lifecycle correctness, ending with two use-after-free fixes in v15.
Meanwhile the CAN section reached an OASIS committee specification: VIRTIO 1.4 CS01, dated 8 April 2026, where the CAN device is section 5.20. The merged commit message states that the driver is based on VIRTIO 1.4.
The same arc is visible in Automotive Grade Linux. AGL’s meta-egvirt layer added the OpenSynergy driver as an external kernel module on 10 November 2022 and updated it on 6 November 2024. The Ultimate Unagi branch, at tag 21.0.5, still carries that out-of-tree module. On 1 July 2026 Scott Murray of Konsulko reworked the layer into meta-virtio, and the commit message states that the local driver source was replaced “with backport of the recently upstreamed version of the driver”. The patch file in the layer is the mainline commit 083082a4e6d8 verbatim, marked Upstream-Status: Backport, and it is present at the Vibrant Vimba tags 22.0.0 and 22.0.1. The kernel configuration fragment AGL applies is short:
CONFIG_CAN_DEV=m
CONFIG_CAN_VIRTIO_CAN=m
CONFIG_VIRTIO=yThe Unagi module is not the same code: it differs from the mainline file by roughly five hundred changed lines and predates the review changes, including the unknown-bitrate handling described below.
What the virtio CAN guest can and cannot do
There are three virtqueues: transmit, receive and control. The control queue carries exactly two messages, start and stop. The device configuration space has a single field, status, with a single defined bit, VIRTIO_CAN_S_CTRL_BUSOFF. There are four feature bits: classic CAN, CAN FD, remote transmission request frames, and late transmit acknowledgement.
The first consequence is that the guest does not own bit timing. There is no control message for bitrate, sample point or data-phase timing, and the driver sets both the nominal and the data bitrate to CAN_BITRATE_UNKNOWN at probe. The usage given in the commit message brings the interface up with ip link set up can0 and no bitrate. The reason follows from what the device is for. The specification says the bus behind the device may be physical, a virtual bus between virtual machines, or a combination of both. When two guests share one physical controller, neither guest can be allowed to change the bit timing that the other depends on, so the configuration belongs to whoever implements the device: the hypervisor, or a host-side process.
On the guest, apart from the missing bitrate, starting the interface and sending a frame looks as it does on native hardware:
root@qemuarm64:~# modprobe virtio_can
root@qemuarm64:~# ip link set up can0
root@qemuarm64:~# cansend can0 123#DEADBEEFThe second consequence is a reduced error-state model. The driver moves the interface between error-active, bus-off, stopped and sleeping, and nowhere else. A native SocketCAN controller driver typically also reports error-warning and error-passive transitions and exposes the transmit and receive error counters; the virtio CAN specification defines no message or status bit that carries either, so the guest cannot report them. For a guest whose diagnostics depend on seeing a node degrade towards bus-off, the transition arrives as a single step.
The third point is transmit confirmation. SocketCAN loops a transmitted frame back to local sockets as an echo, and applications use that echo as confirmation that the frame was sent. The driver releases the echo when the device returns the transmit buffer. With VIRTIO_CAN_F_LATE_TX_ACK negotiated, the specification requires the device to return the buffer only after the controller has acknowledged transmission on the bus. Without it, the device may return the buffer as soon as the frame has been scheduled for transmission. The driver offers the feature bit; whether the echo means “transmitted on the bus” or “accepted by the host” therefore depends on what the device implementation grants.
The fourth is CAN XL. The message layout reserves for it: the length field comment allows up to 2,048 bytes, and there is a field named reserved_xl_priority. There is no CAN XL feature bit in VIRTIO 1.4 and no CAN XL path in the driver. A guest using this device cannot use the CAN XL netlink interface that merged in Linux 6.19, whatever the physical controller supports. The specification also defines no acceptance filtering.
The host side is where the work is still in flight
Something has to implement the device, and that half is not in a mainline project.
Mainline QEMU has no virtio CAN device. Its hw/net/can directory, read on 17 November 2026, contains emulations of real controllers, including FlexCAN, CTU CAN FD, SJA1000 variants and the Xilinx controllers, and no virtio device. QEMU did import the UAPI header on 1 July 2026, as part of a routine header update to v7.2-rc1, but a header is not a device. The OpenSynergy QEMU device referenced throughout the kernel series is not in mainline QEMU.
The open-source backend that does exist is vhost-device-can in the rust-vmm vhost-device repository: a vhost-user process that forwards frames between a guest and a host SocketCAN interface. Its initial implementation was added to the staging workspace on 9 January 2024 by Timos Ampelikiotis of Virtual Open Systems, it moved to the main workspace on 10 November 2024, and version 0.1.0, published on crates.io on 15 November 2024, is still the only release. The unreleased changelog lists a fix making its feature values conform to the specification.
The README calls the device work in progress, and lists four limitations: transmission to the host interface is always synchronous, so the backend waits for transmission whether or not late acknowledgement was negotiated; undefined flags are not checked; the start and stop control messages do not change the host interface’s state; and the device has been tested only with vcan, the virtual CAN interface, rather than a physical controller. Its dependency notes still name a CONFIG_VIRTIO_CAN option; the merged symbol is CAN_VIRTIO_CAN. On the host it is started like this:
raghu@techveda.org:~$ vhost-device-can --socket-path=can.sock --can-devices="vcan0"To attach it, the README gives two QEMU options. One is QEMU’s generic vhost-user-test-device-pci with virtio-id=36, which requires QEMU 10.2 or newer and has no CAN-specific code. The other is a vhost-user-can-pci device that lives only in a Virtual Open Systems QEMU branch named vhu-can-rfc. AGL’s 1 July rework switched its recipe to the latest crates.io version, which is 0.1.0.
The device side matters more here than for most virtio devices. Bit timing, error-state behaviour, whether the echo means transmission, and how frames from several guests reach one controller are all left to the device. The guest driver can be identical across two products while bus behaviour differs, so the integrator’s question is what the device implementation does in each of those four places. Commercial hypervisors may implement the device too; this post did not survey them, and a team relying on one should ask which VIRTIO version and feature bits it implements.
Review findings opened after the merge
On 9 June 2026, the day before the commit was applied, an automated review bot posting from kernel.org listed ten potential issues against v15: seven marked high and three medium. They include an unbounded wait in the control-message path, a transmit flow-control race that could stall the queue, remote transmission request frames dropped by a length check, frames dropped while error-passive, and a bus-off indication that can be lost. These are automated findings; no maintainer has confirmed or rejected them on the list in the archives I read.
I checked one against the source, because it connects to the state model above. The receive path discards frames when the controller state is error-passive or worse. Since the driver never enters error-passive, that check takes effect only in bus-off, stopped or sleeping, so the finding does not show up as lost frames in the current code; it would matter if a future revision of the specification adds error-passive reporting. The other nine I did not verify.
What can be stated as fact is the state of the tree. The commit log for drivers/net/can/virtio_can.c shows the single merge commit and nothing after it, both in mainline at v7.4-rc3 (15 November 2026) and in linux-next at next-20261116. No fix for any of the ten findings has reached either tree.
Which kernels carry the virtio CAN driver
As of 17 November 2026, kernel.org lists 7.2.15, released on 1 November 2026, as the final 7.2 release and marks the series end of life. The driver is therefore maintained in 7.3.x stable and in 7.4-rc mainline. Every current longterm series (6.18, 6.12, 6.6, 6.1, 5.15 and 5.10) predates 7.2, and new drivers are not backported to them. A programme on a current longterm kernel carries a backport, as AGL Vimba does on 6.18, or an older out-of-tree copy, as AGL Unagi does.
The arm64 defconfig at v7.4-rc3 does not enable CAN_VIRTIO_CAN, so a guest kernel needs it set explicitly. Which longterm kernel will first contain the driver has not been announced.
What this post does not claim
No production vehicle, OEM or Tier 1 is named as using virtio CAN, and nothing here implies one. No latency or throughput figure appears, because none was measured. I did not open the Virtual Open Systems QEMU branch. Because virtualising the controller moves fault reporting into the device implementation, any safety argument for a function on that bus moves there too; no implementation is assessed here. The hypervisor side of that argument, and which hypervisor fits which integrity level, is covered in the earlier post on automotive hypervisors and integrity levels.
Key takeaways
- The virtio CAN guest driver, commit
083082a4e6d8, was released in Linux 7.2 on 16 August 2026 against VIRTIO 1.4. - The guest cannot set bit timing, sees only error-active and bus-off, and has no CAN XL path. Those are properties of the specification, not gaps in the driver.
- Whether the transmit echo means the frame reached the bus depends on the device granting late transmit acknowledgement. The rust-vmm backend always transmits synchronously.
- No mainline QEMU device exists.
vhost-device-can0.1.0 is the only release and its README calls it work in progress, tested only withvcan. - No longterm kernel carries the driver. AGL Vimba backports the mainline commit onto 6.18; AGL Unagi still carries a pre-review out-of-tree copy.
Frequently asked questions
Which kernel version first includes the virtio CAN driver?
Linux 7.2, released on 16 August 2026. The driver is absent at v7.1 and present from v7.2-rc1, and no longterm series carries it as of 17 November 2026.
Can a Linux guest set the CAN bitrate through virtio CAN?
No. The VIRTIO 1.4 specification has only start and stop control messages, and the driver reports the bitrate as unknown. Bit timing is configured by whatever implements the device, which matters when several guests share one controller.
Does virtio CAN support CAN XL?
Not today. The message layout reserves a length range and a priority field for CAN XL, but VIRTIO 1.4 defines no CAN XL feature bit and the driver has no CAN XL path.
What can I run on the host to back a virtio CAN guest?
The open-source option is vhost-device-can from rust-vmm, version 0.1.0, attached through QEMU’s generic vhost-user test device in QEMU 10.2 or newer. Mainline QEMU has no virtio CAN device of its own.
Further reading
- Primary: Mainline log for
drivers/net/can/virtio_can.c— commit 083082a4e6d8, “can: virtio: Add virtio CAN driver”. - Primary: [PATCH v15] can: virtio: Add virtio CAN driver, Matias Ezequiel Vara Larsen, 26 May 2026, with the linux-can thread view carrying the 9 June review findings and the 10 June reply.
- Primary: Virtual I/O Device (VIRTIO) Version 1.4, Committee Specification 01, OASIS, 8 April 2026 — section 5.20, CAN Device.
- Primary: virtio-spec
device-types/can— the specification source, first committed 9 June 2023. - Primary: [RFC PATCH 1/1] can: virtio: Initial virtio CAN driver, Harald Mommer, 25 August 2022.
- Primary: Review of v5 on transmit-failure reporting, Francesco Valla, 14 October 2025.
- Primary: AGL
meta-virtiolog — the 1 July 2026 rework and the backported driver patch. - Primary: vhost-device-can README, rust-vmm — limitations and QEMU attachment options.
- Primary: kernel.org releases — 7.2 end of life and the current longterm series.




