Message ID | 20191202203128.14348-3-peter.ujfalusi@ti.com |
---|---|
State | New |
Headers | show
Delivered-To: patch@linaro.org Received: by 2002:a92:3001:0:0:0:0:0 with SMTP id x1csp504726ile; Mon, 2 Dec 2019 12:31:51 -0800 (PST) X-Google-Smtp-Source: APXvYqx/DpHEk8jvA7lzVgZSDoNRlB68QSyT7e2ek1vVEfVOqJmkpTMpOTBmTL7wYcfckQXkcjRb X-Received: by 2002:a50:f78d:: with SMTP id h13mr1071713edn.302.1575318711056; Mon, 02 Dec 2019 12:31:51 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1575318711; cv=none; d=google.com; s=arc-20160816; b=MQ4IWGaw6LAagKoISJdOkQsvNM+I2WkLFEy3I/PcAOSLrNjX67scJpj7s9SDcH3kXr 2Li/neoC6yUa9BV/xOwiwzzHI6UuaORv4n+Hu3bWtbO1d8wUwyA5CJAi7/EXfGOesDEW iz+oCNxWimkoqrjDP2XIEOO0I7gIpUJgLVH8/zqtiPU5UQjS2j8F1a5pWblX/LYLlKpE lOnK6BNNl/VklAWmy6PNb5BKoW17KB1SeBWGQmD0hvgQb1UgRiCpMNISlytmnSWj7t6w dNtIE1BhLD6WTzXd9jyQbcqmdwwc+Rac4QnJFVqhXPBpzW1ObzDs0Xj3FPCDeMKiDADn j3Dg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=I4zArTwz2+uyo5cLd8GOGGyuu7Ob1n/MUYmaFykEDf0=; b=NROhJzeaRttz5/Ae95PPjpSYr4SHMZGtttKgjDFu/L21iEbbz8Po6YXA1J/nusHwTr mUQ+abj8Isba1k1STTaLEbveZ+rPiporvCKcjI4XtaT/iTRFDEumH84YzC7IrTnblNJ2 dyHDBRMNxsok9cAnkXZO+S0HAqvhZU3HVOmmcghT2yjXErF2qkyBeVCMCh9uKn7tfHpO Pu7tc2axA92YGulGPc+6/PsIxC1MN5oORLMLCCkgppHq0CxtMvqSMnjnKfbhUat0onix rX9KTpYZpSiUZM0VCis+Jj6Ey0rjih6cyS4Wc1jMGe+Zk9r4JyNpbyLjh6ZgS8PC0VQP teEw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=MOrDhfh9; spf=pass (google.com: best guess record for domain of dmaengine-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=dmaengine-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: <dmaengine-owner@vger.kernel.org> Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o18si455954ejj.427.2019.12.02.12.31.50; Mon, 02 Dec 2019 12:31:51 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of dmaengine-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=MOrDhfh9; spf=pass (google.com: best guess record for domain of dmaengine-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=dmaengine-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727545AbfLBUbu (ORCPT <rfc822;patch@linaro.org> + 3 others); Mon, 2 Dec 2019 15:31:50 -0500 Received: from lelv0143.ext.ti.com ([198.47.23.248]:48646 "EHLO lelv0143.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727522AbfLBUbs (ORCPT <rfc822;dmaengine@vger.kernel.org>); Mon, 2 Dec 2019 15:31:48 -0500 Received: from lelv0265.itg.ti.com ([10.180.67.224]) by lelv0143.ext.ti.com (8.15.2/8.15.2) with ESMTP id xB2KVY1S116144; Mon, 2 Dec 2019 14:31:34 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1575318694; bh=I4zArTwz2+uyo5cLd8GOGGyuu7Ob1n/MUYmaFykEDf0=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=MOrDhfh9Qab1FfK0q8D3QSJmCj8WSAEX4pWScE4+rTh0ADTkMuBdWERv1hbkfI2NN LVuwk5sQyE3eO3ffhdzP95BisKvguwfMq3lvOmrEtM/qFPFdCe14294GQwgU4oIglk 0GZArIFKa0b56G2vwJVniDgOk7zOjGxqu8jazy5U= Received: from DFLE109.ent.ti.com (dfle109.ent.ti.com [10.64.6.30]) by lelv0265.itg.ti.com (8.15.2/8.15.2) with ESMTPS id xB2KVYZZ116964 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 2 Dec 2019 14:31:34 -0600 Received: from DFLE107.ent.ti.com (10.64.6.28) by DFLE109.ent.ti.com (10.64.6.30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1847.3; Mon, 2 Dec 2019 14:31:33 -0600 Received: from fllv0040.itg.ti.com (10.64.41.20) by DFLE107.ent.ti.com (10.64.6.28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1847.3 via Frontend Transport; Mon, 2 Dec 2019 14:31:32 -0600 Received: from feketebors.ti.com (ileax41-snat.itg.ti.com [10.172.224.153]) by fllv0040.itg.ti.com (8.15.2/8.15.2) with ESMTP id xB2KVOPn106889; Mon, 2 Dec 2019 14:31:30 -0600 From: Peter Ujfalusi <peter.ujfalusi@ti.com> To: <vkoul@kernel.org> CC: <dan.j.williams@intel.com>, <dmaengine@vger.kernel.org>, <linux-arm-kernel@lists.infradead.org>, <linux-kernel@vger.kernel.org>, <grygorii.strashko@ti.com>, <t-kristo@ti.com>, <tony@atomide.com>, <vigneshr@ti.com> Subject: [PATCH 2/3] dmaengine: ti: k3-udma: Workaround for stale transfers Date: Mon, 2 Dec 2019 22:31:27 +0200 Message-ID: <20191202203128.14348-3-peter.ujfalusi@ti.com> X-Mailer: git-send-email 2.24.0 In-Reply-To: <20191202203128.14348-1-peter.ujfalusi@ti.com> References: <0191128105945.13071-1-peter.ujfalusi@ti.com> <20191202203128.14348-1-peter.ujfalusi@ti.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: <dmaengine.vger.kernel.org> X-Mailing-List: dmaengine@vger.kernel.org |
Series |
dmaengine: ti: k3-udma: Fixes against v6 series
|
expand
|
diff --git a/drivers/dma/ti/k3-udma.c b/drivers/dma/ti/k3-udma.c index 1b929f7a84d4..3aede5db9604 100644 --- a/drivers/dma/ti/k3-udma.c +++ b/drivers/dma/ti/k3-udma.c @@ -2842,6 +2842,10 @@ static void udma_free_chan_resources(struct dma_chan *chan) struct udma_dev *ud = to_udma_dev(chan->device); udma_terminate_all(chan); + if (uc->terminated_desc) { + udma_reset_chan(uc, false); + udma_reset_rings(uc); + } if (uc->irq_num_ring > 0) { free_irq(uc->irq_num_ring, uc);
If the client does issue_pending between terminte_all+synchronize and free_chan_resources, we need to make sure that it has been handled and cleared up. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> --- drivers/dma/ti/k3-udma.c | 4 ++++ 1 file changed, 4 insertions(+) -- Peter Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki