From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 04C688801; Tue, 30 Apr 2024 11:19:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714475980; cv=none; b=VVB46Zm2mLEei2kzyC6K2Y3hPSiAeEj1CR852dbtLRlQWXSWtnDQ9QIrdBo/s7Dq0Wl3zMsChWwiQ+769KGXRK7uo2+hS1cDfAYSEa9b6hmc5bZNdKjc+yzydQcF7Rlpi+3IFx0R5a73f04ZFq+9DEYhmi+x/WtnDLsVpSIicmo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714475980; c=relaxed/simple; bh=zMXijcaXM8wbNPZqv/oVyvbN6WnpTPI6Mr1gOH+AEYk=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=uAzu0slEkaYgRSovRtXUc8qFeEuUg/9IzOydDWeM4iXds7VuwLnch0SRCFRwo6wL3csFoH4H0xxjbjItuJ1RXGpbyt9hy3PCSiV5uIxlMFVgqF0tJcPGjjNEuta67c8PCXDsMsloC1qiM5Zr5O2uMEimXIOWZZFXXs6353tmFcc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=Pi527fok; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="Pi527fok" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 84B4DC2BBFC; Tue, 30 Apr 2024 11:19:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1714475979; bh=zMXijcaXM8wbNPZqv/oVyvbN6WnpTPI6Mr1gOH+AEYk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Pi527fokkWPYZN8TMXVOFc1fRq1SWn8qpv+gaZlxpCKTqZ2NpDUQpOir5dCHKdP/H r0qjhgObhrhCg7DPJv3lIwehEjjqs21EwmY4u4JVr4e97US5PS601MqUGkogmaxID3 RlzASza7hS7ZYCEjT0KDcU6k7/cDtF9sRUXWn70c= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Heiner Kallweit , Andy Shevchenko , Vinod Koul , Sasha Levin Subject: [PATCH 5.15 70/80] idma64: Dont try to serve interrupts when device is powered off Date: Tue, 30 Apr 2024 12:40:42 +0200 Message-ID: <20240430103045.482345345@linuxfoundation.org> X-Mailer: git-send-email 2.44.0 In-Reply-To: <20240430103043.397234724@linuxfoundation.org> References: <20240430103043.397234724@linuxfoundation.org> User-Agent: quilt/0.67 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 5.15-stable review patch. If anyone has any objections, please let me know. ------------------ From: Andy Shevchenko [ Upstream commit 9140ce47872bfd89fca888c2f992faa51d20c2bc ] When iDMA 64-bit device is powered off, the IRQ status register is all 1:s. This is never happen in real case and signalling that the device is simply powered off. Don't try to serve interrupts that are not ours. Fixes: 667dfed98615 ("dmaengine: add a driver for Intel integrated DMA 64-bit") Reported-by: Heiner Kallweit Closes: https://lore.kernel.org/r/700bbb84-90e1-4505-8ff0-3f17ea8bc631@gmail.com Tested-by: Heiner Kallweit Signed-off-by: Andy Shevchenko Link: https://lore.kernel.org/r/20240321120453.1360138-1-andriy.shevchenko@linux.intel.com Signed-off-by: Vinod Koul Signed-off-by: Sasha Levin --- drivers/dma/idma64.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/dma/idma64.c b/drivers/dma/idma64.c index f4c07ad3be15b..af8777a1ec2e3 100644 --- a/drivers/dma/idma64.c +++ b/drivers/dma/idma64.c @@ -167,6 +167,10 @@ static irqreturn_t idma64_irq(int irq, void *dev) u32 status_err; unsigned short i; + /* Since IRQ may be shared, check if DMA controller is powered on */ + if (status == GENMASK(31, 0)) + return IRQ_NONE; + dev_vdbg(idma64->dma.dev, "%s: status=%#x\n", __func__, status); /* Check if we have any interrupt from the DMA controller */ -- 2.43.0