All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net] ibmvnic: Fix returning uninitialized return code
@ 2020-09-16 22:12 Thomas Falcon
  2020-09-17  6:07 ` Saeed Mahameed
  0 siblings, 1 reply; 3+ messages in thread
From: Thomas Falcon @ 2020-09-16 22:12 UTC (permalink / raw)
  To: netdev; +Cc: Thomas Falcon

If successful, __ibmvnic_open and reset_sub_crq_queues,
if no device queues exist, will return an uninitialized
variable rc. Return zero on success instead.

Fixes: 57a49436f4e8 ("ibmvnic: Reset sub-crqs during driver reset")
Fixes: ed651a10875f ("ibmvnic: Updated reset handling")
Signed-off-by: Thomas Falcon <tlfalcon@linux.ibm.com>
---
 drivers/net/ethernet/ibm/ibmvnic.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/ethernet/ibm/ibmvnic.c b/drivers/net/ethernet/ibm/ibmvnic.c
index 1b702a4..1619311 100644
--- a/drivers/net/ethernet/ibm/ibmvnic.c
+++ b/drivers/net/ethernet/ibm/ibmvnic.c
@@ -1178,7 +1178,7 @@ static int __ibmvnic_open(struct net_device *netdev)
 	}
 
 	adapter->state = VNIC_OPEN;
-	return rc;
+	return 0;
 }
 
 static int ibmvnic_open(struct net_device *netdev)
@@ -2862,7 +2862,7 @@ static int reset_sub_crq_queues(struct ibmvnic_adapter *adapter)
 			return rc;
 	}
 
-	return rc;
+	return 0;
 }
 
 static void release_sub_crq_queue(struct ibmvnic_adapter *adapter,
-- 
1.8.3.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-09-17 21:26 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-16 22:12 [PATCH net] ibmvnic: Fix returning uninitialized return code Thomas Falcon
2020-09-17  6:07 ` Saeed Mahameed
2020-09-17 20:32   ` Thomas Falcon

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.