Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp2718855rwb; Mon, 19 Sep 2022 09:00:48 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6X++kEWMOa2NP5s5rdVUO9WZsCf6fm0cjMXZg8sCfKfVLnAodv9EUn6C4YOWz1cM38L55H X-Received: by 2002:a17:90b:1c88:b0:203:8400:13a9 with SMTP id oo8-20020a17090b1c8800b00203840013a9mr8977481pjb.46.1663603248163; Mon, 19 Sep 2022 09:00:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1663603248; cv=none; d=google.com; s=arc-20160816; b=xcalsL19XhBulnNAGP6ZmKyGC3UnVQMiOv86rJ+WDQPl42o8HOQEvxiFexKfRAWYQ+ ogJ5Gjz8MEJJzcpR+rDz63OagDgdRBkTp6Q5ShDYk1tagT9Ao0cBP55HSeDaBqc/0hkJ 2iZpeMEOR0WU4Q0/h4SBw2+fpxoiZcd3RJ+SrKqpilUkqFeDHMUaE5rNoIlPRwpX488q rVn4qCvRuLol3fKCkeLAI/Aw9qGhzbkEYpgDIEX5TC22Wh2G/gmbUoNqPpgDRFYAE6Fp JgpsDNS/B+Hul6HqQvlbrfwvWMwBo2Dk/8+vAbPJIAFAYMER/e0AsAAn9ytZVQCrZ49Q oM/A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date:dkim-signature; bh=I4z0wAfhWmBzoy4sUboCNYs+LN4FIyNd2HWuXMFVd9g=; b=ADK9amIn4QA4hZnLWo90c4RuHyr8HzbEPo4RulJW5WUnSQYZNfz6oRxYZxppA7rDRh 8dMotugRn5IGqoecog0TndEmRqGJ35dHLK8c+OIonKDSR9bkzXPQl4xA6qqGDLNRjy4Q 4kC6om8C6S8D1QjCKv/NR5kDh8nq22+YNQHHar/H/PYIbL1q2BeP9zNdJZaS1n2gE9Af AGYOi4CPe4dJe0i7Idu1agzg1jXjM8bOf9TCLfCBdNw6LoHyfkqL6BzsaFGJha2FgN5u JBWuUPgYmMVaa4XOqSaSDD5gad5n2bKelMcN+Ty75NluEMPcqWC5M0Kou2TYBRGuuGfy PRsQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=gJd8bul7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k2-20020a170902ce0200b0016ee96226a9si32765997plg.391.2022.09.19.09.00.35; Mon, 19 Sep 2022 09:00:48 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=gJd8bul7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229861AbiISP3j (ORCPT + 99 others); Mon, 19 Sep 2022 11:29:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35400 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229947AbiISP3g (ORCPT ); Mon, 19 Sep 2022 11:29:36 -0400 Received: from relay6-d.mail.gandi.net (relay6-d.mail.gandi.net [217.70.183.198]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9A316298; Mon, 19 Sep 2022 08:29:33 -0700 (PDT) Received: (Authenticated sender: miquel.raynal@bootlin.com) by mail.gandi.net (Postfix) with ESMTPSA id 63EABC000F; Mon, 19 Sep 2022 15:29:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1663601372; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=I4z0wAfhWmBzoy4sUboCNYs+LN4FIyNd2HWuXMFVd9g=; b=gJd8bul7ZIQzyBFirA9lSz/50UmUcod3OU/y7+q91EGzV+8Wg/xDxxqhCKlemJKa8M9Zs1 7j9ncEw7AgQyGzQtrUTU1o55Dy+PG2hWXAvymqy3jMs1o9AtZ2ZQGb8NThOgjF/Dtx1SaZ vhkebnVVyRxyf/Be2NH3jsM+gvmYsmgzbzDyAYnh0lRpi+zdNG2sHWG8+C+zEcMtnymozs hseXuXkuRhSRXQlyeL7OKv8bECA7JM7YTYvYJKPNH71NgcxJojXRVV9k18EFXykWqqgsyR ANWAX6Ao//H8hBB//olHkgW7y5GxaT+tVlliQu5kVziFmK0Wu2AfMYpLt2LiVA== Date: Mon, 19 Sep 2022 17:29:28 +0200 From: Miquel Raynal To: Cc: , , , , , , , , , , Subject: Re: [PATCH] mtd: rawnand: atmel: Unmap streaming DMA mappings Message-ID: <20220919172928.6f918ab2@xps-13> In-Reply-To: <86158844-b314-bee8-c5b8-0b757c6b6ab0@microchip.com> References: <20220728074014.145406-1-tudor.ambarus@microchip.com> <86158844-b314-bee8-c5b8-0b757c6b6ab0@microchip.com> Organization: Bootlin X-Mailer: Claws Mail 4.0.0 (GTK+ 3.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello Tudor, Tudor.Ambarus@microchip.com wrote on Wed, 7 Sep 2022 09:06:39 +0000: > On 7/28/22 10:40, Tudor Ambarus wrote: > > Every dma_map_single() call should have its dma_unmap_single() counterp= art, > > because the DMA address space is a shared resource and one could render= the > > machine unusable by consuming all DMA addresses. > >=20 > > Cc: stable@vger.kernel.org > > Fixes: f88fc122cc34 ("mtd: nand: Cleanup/rework the atmel_nand driver") > > Signed-off-by: Tudor Ambarus > > --- > > drivers/mtd/nand/raw/atmel/nand-controller.c | 1 + > > 1 file changed, 1 insertion(+) > >=20 > > diff --git a/drivers/mtd/nand/raw/atmel/nand-controller.c b/drivers/mtd= /nand/raw/atmel/nand-controller.c > > index 6ef14442c71a..330d2dafdd2d 100644 > > --- a/drivers/mtd/nand/raw/atmel/nand-controller.c > > +++ b/drivers/mtd/nand/raw/atmel/nand-controller.c > > @@ -405,6 +405,7 @@ static int atmel_nand_dma_transfer(struct atmel_nan= d_controller *nc, > > =20 > > dma_async_issue_pending(nc->dmac); > > wait_for_completion(&finished); > > + dma_unmap_single(nc->dev, buf_dma, len, dir); > > =20 > > return 0; > > =20 >=20 > Hi, Richard, Miquel, >=20 > Would you please consider to include this patch in your queue? I'm catching up only now so as we're at -rc6 and I want things to lay a bit in -next I don't plan to send a Fixes PR, all the fixes exceptionally will go through the usual PR as anyway they won't be ready before the merge window opens. > If yes, please add the following tag, it solves a regression: >=20 > Link: https://lore.kernel.org/lkml/13c6c9a2-6db5-c3bf-349b-4c127ad3496a@a= xentia.se/ Ok. Thanks, Miqu=C3=A8l