VSOCK: fix returnvar.cocci warnings

Author: Julia Lawall <julia.lawall@lip6.fr>

Remove unneeded variable used to store return value.

Generated by: scripts/coccinelle/misc/returnvar.cocci

CC: Asias He 
Signed-off-by: Fengguang Wu 
Signed-off-by: Julia Lawall 
Reviewed-by: Stefan Hajnoczi 
Signed-off-by: David S. Miller 
---
 drivers/vhost/vsock.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
 
diff --git a/drivers/vhost/vsock.c b/drivers/vhost/vsock.c
index 65b1cf8..64bcb10 100644
--- a/drivers/vhost/vsock.c
+++ b/drivers/vhost/vsock.c
@@ -56,8 +56,7 @@ struct vhost_vsock {
 
 static u32 vhost_transport_get_local_cid(void)
 {
-	u32 cid = VHOST_VSOCK_DEFAULT_HOST_CID;
-	return cid;
+	return VHOST_VSOCK_DEFAULT_HOST_CID;
 }
 
 static struct vhost_vsock *vhost_vsock_get(u32 guest_cid)
BtrLinux
Privacy Overview

This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.