linux-user: Fix types in uaccess.c
commit09f679b62dffd437446307884597273618004b2c
authorRichard Henderson <richard.henderson@linaro.org>
Fri, 12 Feb 2021 18:48:49 +0000 (12 10:48 -0800)
committerPeter Maydell <peter.maydell@linaro.org>
Tue, 16 Feb 2021 13:02:29 +0000 (16 13:02 +0000)
tree8eed2e8e0d96050bc42e8caae0c41800f978d2d1
parent687ca797893ca1e8538592f19ac61e9eafd0b899
linux-user: Fix types in uaccess.c

For copy_*_user, only 0 and -TARGET_EFAULT are returned; no need
to involve abi_long.  Use size_t for lengths.  Use bool for the
lock_user copy argument.  Use ssize_t for target_strlen, because
we can't overflow the host memory space.

Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-id: 20210212184902.1251044-19-richard.henderson@linaro.org
[PMM: moved fix for ifdef error to previous commit]
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
linux-user/qemu.h
linux-user/uaccess.c