Commit df0a9b52 authored by Arnd Bergmann's avatar Arnd Bergmann

Merge tag 'amdtee-fix-for-v5.16' of...

Merge tag 'amdtee-fix-for-v5.16' of git://git.linaro.org/people/jens.wiklander/linux-tee into arm/fixes

AMD-TEE fix IS_ERR() bug

* tag 'amdtee-fix-for-v5.16' of git://git.linaro.org/people/jens.wiklander/linux-tee:
  tee: amdtee: fix an IS_ERR() vs NULL bug

Link: https://lore.kernel.org/r/20211130070351.GA2308099@jadeSigned-off-by: default avatarArnd Bergmann <arnd@arndb.de>
parents 708038dc 9d748277
......@@ -203,9 +203,8 @@ static int copy_ta_binary(struct tee_context *ctx, void *ptr, void **ta,
*ta_size = roundup(fw->size, PAGE_SIZE);
*ta = (void *)__get_free_pages(GFP_KERNEL, get_order(*ta_size));
if (IS_ERR(*ta)) {
pr_err("%s: get_free_pages failed 0x%llx\n", __func__,
(u64)*ta);
if (!*ta) {
pr_err("%s: get_free_pages failed\n", __func__);
rc = -ENOMEM;
goto rel_fw;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment