mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-11 07:03:09 -04:00
Merge 68373c0331 on remote branch
Change-Id: I85ad05a7a99c540d7f9c8d6ffe27553f0850d3d2
This commit is contained in:
commit
ff5ca45c7d
2 changed files with 21 additions and 27 deletions
|
|
@ -1,7 +1,7 @@
|
|||
/* SPDX-License-Identifier: GPL-2.0-only */
|
||||
/*
|
||||
* Copyright (c) 2017-2020, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
* Copyright (c) 2022-2023 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
*/
|
||||
|
||||
#ifndef _CAM_CDM_H_
|
||||
|
|
@ -24,7 +24,7 @@
|
|||
|
||||
#define CAM_MAX_SW_CDM_VERSION_SUPPORTED 1
|
||||
#define CAM_SW_CDM_INDEX 0
|
||||
#define CAM_CDM_INFLIGHT_WORKS 5
|
||||
#define CAM_CDM_INFLIGHT_WORKS 1
|
||||
#define CAM_CDM_HW_RESET_TIMEOUT 300
|
||||
|
||||
/*
|
||||
|
|
@ -69,8 +69,6 @@
|
|||
#define CAM_CDM_BL_FIFO_LENGTH_MAX_DEFAULT 0x40
|
||||
#define CAM_CDM_BL_FIFO_LENGTH_CFG_SHIFT 0x10
|
||||
#define CAM_CDM_BL_FIFO_FLUSH_SHIFT 0x3
|
||||
#define CAM_CDM_BL_FIFO_BOUNDARY_CHECK \
|
||||
(CAM_CDM_BL_FIFO_LENGTH_MAX_DEFAULT / 2)
|
||||
|
||||
#define CAM_CDM_BL_FIFO_REQ_SIZE_MAX 0x00
|
||||
#define CAM_CDM_BL_FIFO_REQ_SIZE_MAX_DIV2 0x01
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
// SPDX-License-Identifier: GPL-2.0-only
|
||||
/*
|
||||
* Copyright (c) 2017-2021, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
* Copyright (c) 2022-2023 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
*/
|
||||
|
||||
#include <linux/delay.h>
|
||||
|
|
@ -1264,30 +1264,26 @@ static void cam_hw_cdm_work(struct work_struct *work)
|
|||
list_for_each_entry_safe(node, tnode,
|
||||
&core->bl_fifo[fifo_idx].bl_request_list,
|
||||
entry) {
|
||||
if ((node->bl_tag <= payload->irq_data) ||
|
||||
((node->bl_tag - payload->irq_data) >
|
||||
CAM_CDM_BL_FIFO_BOUNDARY_CHECK)) {
|
||||
if (node->request_type ==
|
||||
CAM_HW_CDM_BL_CB_CLIENT) {
|
||||
cam_cdm_notify_clients(cdm_hw,
|
||||
CAM_CDM_CB_STATUS_BL_SUCCESS,
|
||||
(void *)node);
|
||||
} else if (node->request_type ==
|
||||
CAM_HW_CDM_BL_CB_INTERNAL) {
|
||||
CAM_ERR(CAM_CDM,
|
||||
"Invalid node=%pK %d",
|
||||
node,
|
||||
node->request_type);
|
||||
}
|
||||
list_del_init(&node->entry);
|
||||
if (node->bl_tag == payload->irq_data) {
|
||||
kfree(node);
|
||||
node = NULL;
|
||||
break;
|
||||
}
|
||||
if (node->request_type ==
|
||||
CAM_HW_CDM_BL_CB_CLIENT) {
|
||||
cam_cdm_notify_clients(cdm_hw,
|
||||
CAM_CDM_CB_STATUS_BL_SUCCESS,
|
||||
(void *)node);
|
||||
} else if (node->request_type ==
|
||||
CAM_HW_CDM_BL_CB_INTERNAL) {
|
||||
CAM_ERR(CAM_CDM,
|
||||
"Invalid node=%pK %d",
|
||||
node,
|
||||
node->request_type);
|
||||
}
|
||||
list_del_init(&node->entry);
|
||||
if (node->bl_tag == payload->irq_data) {
|
||||
kfree(node);
|
||||
node = NULL;
|
||||
break;
|
||||
}
|
||||
kfree(node);
|
||||
node = NULL;
|
||||
}
|
||||
} else {
|
||||
CAM_INFO(CAM_CDM,
|
||||
|
|
@ -2232,7 +2228,7 @@ static int cam_hw_cdm_component_bind(struct device *dev,
|
|||
sizeof(cdm_core->name));
|
||||
snprintf(work_q_name + len, sizeof(work_q_name) - len, "%d", i);
|
||||
cdm_core->bl_fifo[i].work_queue = alloc_workqueue(work_q_name,
|
||||
WQ_UNBOUND | WQ_MEM_RECLAIM | WQ_SYSFS,
|
||||
WQ_UNBOUND | WQ_MEM_RECLAIM | WQ_SYSFS | WQ_HIGHPRI,
|
||||
CAM_CDM_INFLIGHT_WORKS);
|
||||
if (!cdm_core->bl_fifo[i].work_queue) {
|
||||
CAM_ERR(CAM_CDM,
|
||||
|
|
|
|||
Loading…
Reference in a new issue