linux/arch/xtensa
Max Filippov c9c63f3c7a xtensa: fix type conversion in __get_user_[no]check
__get_user_[no]check uses temporary buffer of type long to store result
of __get_user_size and do sign extension on it when necessary. This
doesn't work correctly for 64-bit data. Fix it by moving temporary
buffer/sign extension logic to __get_user_asm.

Don't do assignment of __get_user_bad result to (x) as it may not always
be integer-compatible now and issue warning even when it's going to be
optimized. Instead do (x) = 0; and call __get_user_bad separately.

Zero initialize __x in __get_user_asm and use '+' constraint for its
assembly argument, so that its value is preserved in error cases. This
may add at most 1 cycle to the fast path, but saves an instruction and
two padding bytes in the fixup section for each use of this macro and
works for both misaligned store and store exception.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
2019-10-14 14:14:21 -07:00
..
boot xtensa: virt: move PCI root complex to KIO range 2019-09-02 00:09:30 -07:00
configs xtensa: virt: add defconfig and DTS 2019-07-08 14:32:06 -07:00
include xtensa: fix type conversion in __get_user_[no]check 2019-10-14 14:14:21 -07:00
kernel dma-mapping updates for 5.4: 2019-09-19 13:27:23 -07:00
lib xtensa: abstract 'entry' and 'retw' in assembly code 2019-07-08 10:04:48 -07:00
mm xtensa: remove free_initrd_mem 2019-08-26 18:19:04 -07:00
oprofile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
platforms treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
variants xtensa: add test_kc705_be variant 2018-08-20 12:34:45 -07:00
Kconfig dma-mapping updates for 5.4: 2019-09-19 13:27:23 -07:00
Kconfig.debug Kconfig: consolidate the "Kernel hacking" menu 2018-08-02 08:06:48 +09:00
Makefile xtensa: generate uapi header and syscall table header files 2018-12-02 23:45:41 -08:00