[PATCH 1/2] optee: fix tee out of memory failure seen during kexec reboot
Dhananjay Phadke
dphadke at linux.microsoft.com
Thu Feb 18 15:03:15 EST 2021
From: Allen Pais <allen.lkml at gmail.com>
On Wed, 17 Feb 2021 14:57:12 +0530, Allen Pais wrote:
> - /*
> - * Ask OP-TEE to free all cached shared memory objects to decrease
> - * reference counters and also avoid wild pointers in secure world
> - * into the old shared memory range.
> - */
> - optee_disable_shm_cache(optee);
> + if (shutdown) {
> + optee_disable_shm_cache(optee);
> + } else {
> + /*
> + * Ask OP-TEE to free all cached shared memory
> + * objects to decrease reference counters and
> + * also avoid wild pointers in secure world
> + * into the old shared memory range.
> + */
> + optee_disable_shm_cache(optee);
Calling optee_disable_shm_cache() in both if and else. It could be
put in front of if().
More information about the linux-arm-kernel
mailing list