lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 17 Feb 2016 22:53:29 +0530
From:	Amitoj Kaur Chawla <amitoj1606@...il.com>
To:	linux-kernel@...r.kernel.org
Cc:	julia.lawall@...6.fr
Subject: [PATCH] goldfish: Return proper error code

This change has been made with the goal that kernel functions should
return something more descriptive than -1 on failure.

Change the return value on valid_batchbuffer_addr() failure from -1 
to -EINVAL.

Signed-off-by: Amitoj Kaur Chawla <amitoj1606@...il.com>
---
 drivers/platform/goldfish/goldfish_pipe.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/platform/goldfish/goldfish_pipe.c b/drivers/platform/goldfish/goldfish_pipe.c
index 9f6734c..6de6fd2 100644
--- a/drivers/platform/goldfish/goldfish_pipe.c
+++ b/drivers/platform/goldfish/goldfish_pipe.c
@@ -233,7 +233,7 @@ static int setup_access_params_addr(struct platform_device *pdev,
 		dev->aps = aps;
 		return 0;
 	} else
-		return -1;
+		return -EINVAL;
 }
 
 /* A value that will not be set by qemu emulator */
-- 
1.9.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ