]> git.baikalelectronics.ru Git - kernel.git/commit
xtensa: fix error paths in __get_user_{check,size}
authorMax Filippov <jcmvbkbc@gmail.com>
Fri, 22 May 2020 22:52:03 +0000 (15:52 -0700)
committerMax Filippov <jcmvbkbc@gmail.com>
Fri, 22 May 2020 23:09:00 +0000 (16:09 -0700)
commit209abdfea91b6951e6de3720d5e89a4fa9234982
tree91908c6c4e6ca66310b8383d5001d82821848888
parentdc078a716644012e4b439f9dd98e6f38446e147a
xtensa: fix error paths in __get_user_{check,size}

Error paths in __get_user_check and __get_user_size directly assing 0 to
the result. It causes the following sparse warnings:

  sparse: warning: Using plain integer as NULL pointer

Convert 0 to the type pointed to by the user pointer before assigning it.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
arch/xtensa/include/asm/uaccess.h