virtio_ring: Cut and paste bugs in vring_create_virtqueue_packed()
authorDan Carpenter <dan.carpenter@oracle.com>
Fri, 4 Dec 2020 14:23:00 +0000 (17:23 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 30 Dec 2020 10:54:00 +0000 (11:54 +0100)
commitbfffbd34bb0a2f8b93214df8eb7441ade58844f6
treed5cf9a1b13d899fb184dcf0ab0c402c8dc074af0
parent069fedf3fba21a6406104222f0c680c613828890
virtio_ring: Cut and paste bugs in vring_create_virtqueue_packed()

[ Upstream commit ae93d8ea0fa701e84ab9df0db9fb60ec6c80d7b8 ]

There is a copy and paste bug in the error handling of this code and
it uses "ring_dma_addr" three times instead of "device_event_dma_addr"
and "driver_event_dma_addr".

Fixes: 1ce9e6055fa0 (" virtio_ring: introduce packed ring support")
Reported-by: Robert Buhren <robert.buhren@sect.tu-berlin.de>
Reported-by: Felicitas Hetzelt <file@sect.tu-berlin.de>
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Link: https://lore.kernel.org/r/X8pGRJlEzyn+04u2@mwanda
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/virtio/virtio_ring.c