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 5B0BF1D88D0; Sun, 7 Sep 2025 20:27:00 +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=1757276820; cv=none; b=e9yWCv71Js2FxS48aHkRkWqsnKhZB2v3MpvCbE7e5ARbQV1gCbCGqVl+wC/yDuSSM/YUg58i5CIBDNRf0JGTjwBCUudxPWGPhsVYJMiOg/0hsrPma5NUWWsNOFNbGQYBHdgH06PC4Lsu/Lu2gPTPtwzMs1SMQAk3jBAANpKQFPc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1757276820; c=relaxed/simple; bh=lGaLkwOKpcV0gT4AowSW7pcBzNSGgZAjDHJD+0WBY7I=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=gVRk2BXikQixFyiPd9z+3bO1famq/W1MgLVB94uPAhm21VkzED+9oarKkMup+phFCHwH0A6oGbYdeSVVp3Gx+Xo/3sH7yXblwkXVEuY+aSKnM4YUSAKh35lV0JMv50xGhR6GE9qMa9U1Rt998261ODKTAaO1J/3G5mIIitNn0h4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=InoWe2H7; 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="InoWe2H7" Received: by smtp.kernel.org (Postfix) with ESMTPSA id D4D9FC4CEF0; Sun, 7 Sep 2025 20:26:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1757276820; bh=lGaLkwOKpcV0gT4AowSW7pcBzNSGgZAjDHJD+0WBY7I=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=InoWe2H770aqWrjdTbJzMk2hvrEIpn/aVDeed3yqSdrtOh2Pnrp5HWLycoNl9lFxo H2uPpqz/z8Rg5m3tef1jCF8pQ1JcbL7FCMSP32R+GswEhM2qXkeQ6mLe5+O8W6Ehu5 H6Q6gmV/wXaFEh7ITmAmTqriG+xF6ri7XCyZ9ty0= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, kernel test robot , Qiu-ji Chen , Eugen Hristev , AngeloGioacchino Del Regno , Vinod Koul , Sasha Levin Subject: [PATCH 6.6 120/121] dmaengine: mediatek: Fix a flag reuse error in mtk_cqdma_tx_status() Date: Sun, 7 Sep 2025 21:59:16 +0200 Message-ID: <20250907195612.928471086@linuxfoundation.org> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20250907195609.817339617@linuxfoundation.org> References: <20250907195609.817339617@linuxfoundation.org> User-Agent: quilt/0.68 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 6.6-stable review patch. If anyone has any objections, please let me know. ------------------ From: Qiu-ji Chen [ Upstream commit 8eba2187391e5ab49940cd02d6bd45a5617f4daf ] Fixed a flag reuse bug in the mtk_cqdma_tx_status() function. Fixes: 157ae5ffd76a ("dmaengine: mediatek: Fix a possible deadlock error in mtk_cqdma_tx_status()") Cc: stable@vger.kernel.org Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202505270641.MStzJUfU-lkp@intel.com/ Signed-off-by: Qiu-ji Chen Reviewed-by: Eugen Hristev Reviewed-by: AngeloGioacchino Del Regno Link: https://lore.kernel.org/r/20250606090017.5436-1-chenqiuji666@gmail.com Signed-off-by: Vinod Koul Signed-off-by: Sasha Levin --- drivers/dma/mediatek/mtk-cqdma.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/dma/mediatek/mtk-cqdma.c b/drivers/dma/mediatek/mtk-cqdma.c index 385eee4fd4e11..525bb92ced8f8 100644 --- a/drivers/dma/mediatek/mtk-cqdma.c +++ b/drivers/dma/mediatek/mtk-cqdma.c @@ -449,9 +449,9 @@ static enum dma_status mtk_cqdma_tx_status(struct dma_chan *c, return ret; spin_lock_irqsave(&cvc->pc->lock, flags); - spin_lock_irqsave(&cvc->vc.lock, flags); + spin_lock(&cvc->vc.lock); vd = mtk_cqdma_find_active_desc(c, cookie); - spin_unlock_irqrestore(&cvc->vc.lock, flags); + spin_unlock(&cvc->vc.lock); spin_unlock_irqrestore(&cvc->pc->lock, flags); if (vd) { -- 2.51.0