Merge tag 'soc-drivers-6.5' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc
[sfrench/cifs-2.6.git] / drivers / tee / optee / smc_abi.c
index 54414d4def7eb6eaab1196cd9fb8f0786427af04..d5b28fd35d665378591674a8baaeffac5bcd77c0 100644 (file)
@@ -1004,8 +1004,10 @@ static u32 get_async_notif_value(optee_invoke_fn *invoke_fn, bool *value_valid,
 
        invoke_fn(OPTEE_SMC_GET_ASYNC_NOTIF_VALUE, 0, 0, 0, 0, 0, 0, 0, &res);
 
-       if (res.a0)
+       if (res.a0) {
+               *value_valid = false;
                return 0;
+       }
        *value_valid = (res.a2 & OPTEE_SMC_ASYNC_NOTIF_VALUE_VALID);
        *value_pending = (res.a2 & OPTEE_SMC_ASYNC_NOTIF_VALUE_PENDING);
        return res.a1;