[PATCH 5.4 328/389] tee: add overflow check in register_shm_helper()