Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0457661b authored by Linux Build Service Account's avatar Linux Build Service Account
Browse files

Merge 27e8e9bf on remote branch

Change-Id: I8101b43f160023c599aa522fb3a106946031d061
parents bbf23ebd 27e8e9bf
Loading
Loading
Loading
Loading
+9 −3
Original line number Diff line number Diff line
// SPDX-License-Identifier: GPL-2.0-only
/*
 * Copyright (c) 2015-2020, The Linux Foundation. All rights reserved.
 * Copyright (c) 2015-2021, The Linux Foundation. All rights reserved.
 */

#include <linux/irq.h>
@@ -1755,10 +1755,12 @@ static void swrm_enable_slave_irq(struct swr_mstr_ctrl *swrm)
	dev_dbg(swrm->dev, "%s: slave status: 0x%x\n", __func__, status);
	for (i = 0; i < (swrm->master.num_dev + 1); i++) {
		if (status & SWRM_MCP_SLV_STATUS_MASK) {
			if (!swrm->clk_stop_wakeup) {
				swrm_cmd_fifo_rd_cmd(swrm, &temp, i, 0x0,
					SWRS_SCP_INT_STATUS_CLEAR_1, 1);
				swrm_cmd_fifo_wr_cmd(swrm, 0xFF, i, 0x0,
					SWRS_SCP_INT_STATUS_CLEAR_1);
			}
			swrm_cmd_fifo_wr_cmd(swrm, 0x4, i, 0x0,
					SWRS_SCP_INT_STATUS_MASK_1);
		}
@@ -2170,7 +2172,9 @@ static irqreturn_t swr_mstr_interrupt_v2(int irq, void *dev)
				 * re-enable Host IRQ and process slave pending
				 * interrupts, if any.
				 */
				swrm->clk_stop_wakeup = true;
				swrm_enable_slave_irq(swrm);
				swrm->clk_stop_wakeup = false;
			}
			break;
		default:
@@ -2741,6 +2745,8 @@ static int swrm_probe(struct platform_device *pdev)
	swrm->dev_up = true;
	swrm->state = SWR_MSTR_UP;
	swrm->ipc_wakeup = false;
	swrm->enable_slave_irq = false;
	swrm->clk_stop_wakeup = false;
	swrm->ipc_wakeup_triggered = false;
	swrm->disable_div2_clk_switch = FALSE;
	init_completion(&swrm->reset);
+2 −1
Original line number Diff line number Diff line
/* SPDX-License-Identifier: GPL-2.0-only */
/*
 * Copyright (c) 2015-2020, The Linux Foundation. All rights reserved.
 * Copyright (c) 2015-2021, The Linux Foundation. All rights reserved.
 */

#ifndef _SWR_WCD_CTRL_H
@@ -186,6 +186,7 @@ struct swr_mstr_ctrl {
	u32 rd_fifo_depth;
	u32 wr_fifo_depth;
	bool enable_slave_irq;
	bool clk_stop_wakeup;
#ifdef CONFIG_DEBUG_FS
	struct dentry *debugfs_swrm_dent;
	struct dentry *debugfs_peek;