FAILED: patch "[PATCH] tee: optee: fix error return code in probe function" failed to apply to 5.4-stable tree
Subsystems (3)
[email protected]
maintainerThe patch below does not apply to the 5.4-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.
thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
From 40eb0dcf4114cbfff4d207890fa5a19e82da9fdc Mon Sep 17 00:00:00 2001
From: Yang Yingliang <[email protected]>
Date: Thu, 10 Feb 2022 17:10:53 +0800
Subject: [PATCH] tee: optee: fix error return code in probe function
If teedev_open() fails, probe function need return error code.
Fixes aceeafefff73 ("optee: use driver internal tee_context for some rpc")
Reported-by Hulk Robot <[email protected]>
Signed-off-by Yang Yingliang <[email protected]>
Signed-off-by Jens Wiklander <[email protected]>
drivers/tee/optee/ffa_abi.c +3 -1
@@ -860,8 +860,10 @@ static int optee_ffa_probe(struct ffa_device *ffa_dev)optee_supp_init (&optee->supp);ffa_dev_set_drvdata (ffa_dev, optee); ctx =teedev_open (optee->teedev); -if (IS_ERR (ctx)) +if (IS_ERR (ctx)) { + rc =PTR_ERR (ctx); goto err_rhashtable_free; + } optee->ctx = ctx; rc =optee_notif_init (optee,OPTEE_DEFAULT_MAX_NOTIF_VALUE );if (rc)
drivers/tee/optee/smc_abi.c +3 -1
@@ -1427,8 +1427,10 @@ static int optee_probe(struct platform_device *pdev)platform_set_drvdata (pdev, optee); ctx =teedev_open (optee->teedev); -if (IS_ERR (ctx)) +if (IS_ERR (ctx)) { + rc =PTR_ERR (ctx); goto err_supp_uninit; + } optee->ctx = ctx; rc =optee_notif_init (optee, max_notif_value);if (rc)