[PATCH] drivers/net/usb: remove redundant status variable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Minghao Chi <chi.minghao@xxxxxxxxxx>

Return value from sierra_net_send_cmd() directly instead
of taking this in another redundant variable.

Reported-by: Zeal Robot <zealci@xxxxxxxxxx>
Signed-off-by: Minghao Chi <chi.minghao@xxxxxxxxxx>
Signed-off-by: CGEL ZTE <cgel.zte@xxxxxxxxx>
---
 drivers/net/usb/sierra_net.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/net/usb/sierra_net.c b/drivers/net/usb/sierra_net.c
index bb4cbe8fc846..818ff8a24098 100644
--- a/drivers/net/usb/sierra_net.c
+++ b/drivers/net/usb/sierra_net.c
@@ -334,15 +334,12 @@ static int sierra_net_send_cmd(struct usbnet *dev,
 
 static int sierra_net_send_sync(struct usbnet *dev)
 {
-	int  status;
 	struct sierra_net_data *priv = sierra_net_get_private(dev);
 
 	dev_dbg(&dev->udev->dev, "%s", __func__);
 
-	status = sierra_net_send_cmd(dev, priv->sync_msg,
+	return sierra_net_send_cmd(dev, priv->sync_msg,
 			sizeof(priv->sync_msg), "SYNC");
-
-	return status;
 }
 
 static void sierra_net_set_ctx_index(struct sierra_net_data *priv, u8 ctx_ix)
-- 
2.25.1




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux