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]
Message-Id: <20170221220204.225288-1-arnd@arndb.de>
Date:   Tue, 21 Feb 2017 23:01:51 +0100
From:   Arnd Bergmann <arnd@...db.de>
To:     Kees Cook <keescook@...omium.org>, Hoeun Ryu <hoeun.ryu@...il.com>
Cc:     Arnd Bergmann <arnd@...db.de>, linux-kernel@...r.kernel.org
Subject: [PATCH] usercopy: ARM NOMMU has no 64-bit get_user

On a NOMMU ARM kernel, we get this link error:

ERROR: "__get_user_bad" [lib/test_user_copy.ko] undefined!

The problem is that the extended get_user/put_user definitions
were only added for the noral (MMU based) case.

We could add it for NOMMU as well, but it seems easier to just not
call it, since no other code needs it.

Fixes: 075c4ea5363d ("usercopy: Add tests for all get_user() sizes")
Signed-off-by: Arnd Bergmann <arnd@...db.de>
---
 lib/test_user_copy.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/test_user_copy.c b/lib/test_user_copy.c
index 4a79f2c1cd6e..361576b2cb3d 100644
--- a/lib/test_user_copy.c
+++ b/lib/test_user_copy.c
@@ -30,7 +30,8 @@
  * As there doesn't appear to be anything that can safely determine
  * their capability at compile-time, we just have to opt-out certain archs.
  */
-#if BITS_PER_LONG == 64 || (!defined(CONFIG_AVR32)  &&		\
+#if BITS_PER_LONG == 64 || (!(defined(CONFIG_ARM) && !defined(MMU)) && \
+			    !defined(CONFIG_AVR32)  &&		\
 			    !defined(CONFIG_BLACKFIN) &&	\
 			    !defined(CONFIG_M32R) &&		\
 			    !defined(CONFIG_M68K) &&		\
-- 
2.9.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ