Skip to content

Commit

Permalink
virtio-mmio: Delete an error message in vm_find_vqs()
Browse files Browse the repository at this point in the history
The function “platform_get_irq” can log an error already.
Thus omit a redundant message for the exception handling in the
calling function.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Michael S. Tsirkin <[email protected]>
  • Loading branch information
elfring authored and mstsirkin committed Jun 2, 2020
1 parent e7c8cc3 commit 0c35c67
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions drivers/virtio/virtio_mmio.c
Original file line number Diff line number Diff line change
Expand Up @@ -466,10 +466,8 @@ static int vm_find_vqs(struct virtio_device *vdev, unsigned nvqs,
int irq = platform_get_irq(vm_dev->pdev, 0);
int i, err, queue_idx = 0;

if (irq < 0) {
dev_err(&vdev->dev, "Cannot get IRQ resource\n");
if (irq < 0)
return irq;
}

err = request_irq(irq, vm_interrupt, IRQF_SHARED,
dev_name(&vdev->dev), vm_dev);
Expand Down

0 comments on commit 0c35c67

Please sign in to comment.