Commit 56731c68 authored by Colin Ian King's avatar Colin Ian King Committed by Greg Kroah-Hartman
Browse files

drivers: uio: remove redundant assignment to variable retval



The variable retval is being initialized with a value that is
never read and it is being updated later with a new value. The
initialization is redundant and can be removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
Link: https://lore.kernel.org/r/20200425124448.139532-1-colin.king@canonical.com


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 724142f8
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -398,7 +398,7 @@ static void uio_dev_del_attributes(struct uio_device *idev)

static int uio_get_minor(struct uio_device *idev)
{
	int retval = -ENOMEM;
	int retval;

	mutex_lock(&minor_lock);
	retval = idr_alloc(&uio_idr, idev, 0, UIO_MAX_DEVICES, GFP_KERNEL);