virtio-ring: factor out desc_extra allocation
authorJason Wang <jasowang@redhat.com>
Fri, 4 Jun 2021 05:53:46 +0000 (13:53 +0800)
committerMichael S. Tsirkin <mst@redhat.com>
Thu, 8 Jul 2021 11:49:01 +0000 (07:49 -0400)
commit5a22242160201b819be2fe67e15cc9338f3ee582
tree1cfc2996e37194518e9091367a27bde6ea0aad2f
parent1f28750f2e113132791161563c6e7b99eaa4c46b
virtio-ring: factor out desc_extra allocation

A helper is introduced for the logic of allocating the descriptor
extra data. This will be reused by split virtqueue.

Signed-off-by: Jason Wang <jasowang@redhat.com>
Link: https://lore.kernel.org/r/20210604055350.58753-4-jasowang@redhat.com
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
drivers/virtio/virtio_ring.c