]> Gentwo Git Trees - linux/.git/commit
virtio_pci_modern: allow configuring extended features
authorPaolo Abeni <pabeni@redhat.com>
Tue, 8 Jul 2025 15:54:52 +0000 (17:54 +0200)
committerPaolo Abeni <pabeni@redhat.com>
Tue, 8 Jul 2025 16:05:07 +0000 (18:05 +0200)
commit69b9461512246599ed80cf13358e7e6aff7285f9
tree92c52fe8869e86c6387b525cfce0fc4c2b2527e2
parente7d4c1c5a54648fd5b787a4a0f81521ec7260bcd
virtio_pci_modern: allow configuring extended features

The virtio specifications allows for up to 128 bits for the
device features. Soon we are going to use some of the 'extended'
bits features (above 64) for the virtio_net driver.

Extend the virtio pci modern driver to support configuring the full
virtio features range, replacing the unrolled loops reading and
writing the features space with explicit one bounded to the actual
features space size in word and implementing the get_extended_features
callback.

Note that in vp_finalize_features() we only need to cache the lower
64 features bits, to process the transport features.

Acked-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
drivers/virtio/virtio_pci_modern.c
drivers/virtio/virtio_pci_modern_dev.c
include/linux/virtio_pci_modern.h