Sven Schnelle 30de14b188 s390: current_stack_pointer shouldn't be a function
s390 defines current_stack_pointer as function while all other
architectures use 'register unsigned long asm("<stackptr reg>").

This make codes like the following from check_stack_object() fail:

	if (IS_ENABLED(CONFIG_STACK_GROWSUP)) {
		if ((void *)current_stack_pointer < obj + len)
			return BAD_STACK;
	} else {
		if (obj < (void *)current_stack_pointer)
			return BAD_STACK;
	}

because this would compare the address of current_stack_pointer() and
not the stackpointer value.

Reported-by: Karsten Graul <kgraul@linux.ibm.com>
Fixes: 2792d84e6da5 ("usercopy: Check valid lifetime via stack depth")
Cc: Kees Cook <keescook@chromium.org>
Cc: Vasily Gorbik <gor@linux.ibm.com>
Cc: Alexander Gordeev <agordeev@linux.ibm.com>
Signed-off-by: Sven Schnelle <svens@linux.ibm.com>
Reviewed-by: Heiko Carstens <hca@linux.ibm.com>
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
2022-04-12 11:56:08 +02:00
..
2021-07-27 09:39:15 +02:00
2022-03-27 22:18:39 +02:00
2020-08-26 18:47:21 +02:00
2021-09-08 15:32:35 -07:00
2021-07-27 09:39:15 +02:00
2021-01-19 12:29:26 +01:00
2021-10-11 20:55:58 +02:00
2020-12-16 14:55:49 +01:00
2021-05-07 00:26:34 -07:00
2022-03-08 00:33:01 +01:00
2019-02-05 14:29:23 +01:00
2021-06-18 16:41:19 +02:00
2021-07-30 17:09:02 +02:00
2021-08-03 14:31:40 +02:00
2020-02-27 16:02:21 +01:00
2022-03-25 10:01:34 -07:00
2019-02-07 18:06:18 -08:00
2020-09-14 11:38:35 +02:00
2022-03-25 10:01:34 -07:00
2021-10-26 15:21:31 +02:00
2020-09-26 15:51:21 +02:00
2021-10-26 15:21:30 +02:00
2021-06-18 16:41:21 +02:00
2019-07-23 10:45:53 +02:00
2022-01-30 21:17:00 -05:00
2021-07-08 15:37:28 +02:00
2021-01-19 12:29:26 +01:00