mirror of
https://github.com/hardkernel/linux.git
synced 2026-03-24 19:40:21 +09:00
get_user_pages_fast() can return zero in certain error paths. We should handle that or else it means we accidentally return ERR_PTR(0) which is NULL instead of an error pointer. The callers are not expecting that and will crash with a NULL dereference. Change-Id: I5622affddeb1fc5e80ba6ccdbfdc77e129a2ca84 Fixes:033ddf12bc("tee: add register user memory") Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> (cherry picked from commit2490cdf643) Signed-off-by: Victor Chong <victor.chong@linaro.org>