smcinvoke: Handle suspend and resume issues in smcinvoke driver

This change makes changes to smcinvoke driver to handle suspend and resume
scenarios. If the accept thread gets interrupted, do not set the server state
as defunct if the thread is in freezing state, i.e. if the thread is going in
suspend. In such cases, increase timeout of that server so that invoke thread
waits indefinitely for response from userspace until the system resumes back.

Tests:
1. Stability testing has been done on kalama.
2. smcinvoke vendor client testing is done on pineapple.

Change-Id: Iaa7b91d6ed484305349c04468263919e26a3316d
Signed-off-by: Anmolpreet Kaur <quic_anmolpre@quicinc.com>
This commit is contained in:
Anmolpreet Kaur
2022-11-21 23:07:35 +05:30
parent a7350ce560
commit 1177b17bdb
2 changed files with 45 additions and 5 deletions

View File

@@ -1,6 +1,7 @@
/* SPDX-License-Identifier: GPL-2.0-only WITH Linux-syscall-note */
/*
* Copyright (c) 2017-2020, The Linux Foundation. All rights reserved.
* Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
*/
#ifndef _UAPI_SMCINVOKE_H_
#define _UAPI_SMCINVOKE_H_
@@ -9,6 +10,7 @@
#include <linux/ioctl.h>
#define SMCINVOKE_USERSPACE_OBJ_NULL -1
#define DEFAULT_CB_OBJ_THREAD_CNT 4
struct smcinvoke_buf {
__u64 addr;