]> git.baikalelectronics.ru Git - kernel.git/commit
virtio: support VIRTIO_F_ORDER_PLATFORM
authorTiwei Bie <tiwei.bie@intel.com>
Wed, 23 Jan 2019 09:50:26 +0000 (17:50 +0800)
committerMichael S. Tsirkin <mst@redhat.com>
Thu, 24 Jan 2019 15:15:42 +0000 (10:15 -0500)
commit8771ff3986a502f6f6bea2b9fe20ab71dfc58051
treeb25548cd2da896976f1cf718b4b97fd67efece92
parent607d144b83b16847bc18fb058d4d51857c4ff9c6
virtio: support VIRTIO_F_ORDER_PLATFORM

This patch introduces the support for VIRTIO_F_ORDER_PLATFORM.
If this feature is negotiated, the driver must use the barriers
suitable for hardware devices. Otherwise, the device and driver
are assumed to be implemented in software, that is they can be
assumed to run on identical CPUs in an SMP configuration. Thus
a weaker form of memory barriers is sufficient to yield better
performance.

It is recommended that an add-in card based PCI device offers
this feature for portability. The device will fail to operate
further or will operate in a slower emulation mode if this
feature is offered but not accepted.

Signed-off-by: Tiwei Bie <tiwei.bie@intel.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
drivers/virtio/virtio_ring.c
include/uapi/linux/virtio_config.h