aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSiyuan Zhou <siyuanzhou@google.com>2018-06-06 17:21:29 +0000
committerSiyuan Zhou <siyuanzhou@google.com>2018-06-06 17:29:42 +0000
commit5ec1df259c0fa8e1aaf3216a3df6b8d0a0a72bbd (patch)
tree839938ef82f52d988b7e15714e70032ecec5db89
parentecd2680bd513b85c19c925ebcdbfb0a4476d3280 (diff)
Revert "Add timeout and panic when __scm_call_armv8_64 takes too long."android-p-preview-4_r0.2
This reverts commit 5f318d40fab949ef5241f06254f10505b771f8ce. Reason for revert: the fix for b/74358862 was merged and this debug code is no longer needed. Bug:79777538 Change-Id: Iec5a91ba174c379d90bd504ecb9b48b6c06c40ff Signed-off-by: Siyuan Zhou <siyuanzhou@google.com>
-rw-r--r--drivers/soc/qcom/scm.c9
1 files changed, 0 insertions, 9 deletions
diff --git a/drivers/soc/qcom/scm.c b/drivers/soc/qcom/scm.c
index 1e4d9a403b21..6f5bd217d0c9 100644
--- a/drivers/soc/qcom/scm.c
+++ b/drivers/soc/qcom/scm.c
@@ -36,9 +36,6 @@
#define SCM_EBUSY -55
#define SCM_V2_EBUSY -12
-/* in ms */
-#define SCM_PANIC_TIMEOUT 600000
-
static DEFINE_MUTEX(scm_lock);
/*
@@ -386,7 +383,6 @@ int scm_call_noalloc(u32 svc_id, u32 cmd_id, const void *cmd_buf,
static int __scm_call_armv8_64(u64 x0, u64 x1, u64 x2, u64 x3, u64 x4, u64 x5,
u64 *ret1, u64 *ret2, u64 *ret3)
{
- unsigned long timeout;
register u64 r0 asm("x0") = x0;
register u64 r1 asm("x1") = x1;
register u64 r2 asm("x2") = x2;
@@ -395,8 +391,6 @@ static int __scm_call_armv8_64(u64 x0, u64 x1, u64 x2, u64 x3, u64 x4, u64 x5,
register u64 r5 asm("x5") = x5;
register u64 r6 asm("x6") = 0;
- timeout = jiffies + msecs_to_jiffies(SCM_PANIC_TIMEOUT);
-
do {
asm volatile(
__asmeq("%0", R0_STR)
@@ -420,9 +414,6 @@ static int __scm_call_armv8_64(u64 x0, u64 x1, u64 x2, u64 x3, u64 x4, u64 x5,
"r" (r5), "r" (r6)
: "x7", "x8", "x9", "x10", "x11", "x12", "x13",
"x14", "x15", "x16", "x17");
- if (!time_after(timeout, jiffies)) {
- panic("[DEBUG] SCM call took too long.\n");
- }
} while (r0 == SCM_INTERRUPTED);
if (ret1)