disp: msm: sde: update atomic check for VM_REQ_ACQUIRE state
Following is the sequence during which issue is observed: 1) HAL sends a commit with VM_REQ_RELEASE property set indicating transition from primary vm to trusted vm. 2) Before the transition commit ends, there is atomic check for next commit from HAL with VM_REQ_ACQUIRE property indicating transition from trusted vm to primary vm. 3) Since the HW is currently owned by the primary vm, it performs a early return during check phase. After this, transition has occurred from primary to trusted and when the next commit is scheduled on primary, it results in crash since it is currently not the owner. This change adds necessary to check avoid commit with VM_REQ_ACQUIRE state before the transition. Change-Id: I4650305a95ef6bc495375a21a799522e67a61883 Signed-off-by: Yashwanth <quic_yvulapu@quicinc.com>
This commit is contained in:

committed by
Gerrit - the friendly Code Review server

parent
7b00783abe
commit
c5ed579309
@@ -1,5 +1,6 @@
|
||||
// SPDX-License-Identifier: GPL-2.0-only
|
||||
/*
|
||||
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
* Copyright (c) 2020-2021, The Linux Foundation. All rights reserved.
|
||||
*/
|
||||
|
||||
@@ -318,7 +319,7 @@ int sde_vm_request_valid(struct sde_kms *sde_kms,
|
||||
rc = -EINVAL;
|
||||
break;
|
||||
case VM_REQ_ACQUIRE:
|
||||
if (old_state != VM_REQ_RELEASE)
|
||||
if ((old_state != VM_REQ_RELEASE) || vm_owns_hw)
|
||||
rc = -EINVAL;
|
||||
break;
|
||||
default:
|
||||
|
Reference in New Issue
Block a user