Received: by 2002:a17:90a:88:0:0:0:0 with SMTP id a8csp4560125pja; Thu, 21 Nov 2019 21:52:39 -0800 (PST) X-Google-Smtp-Source: APXvYqwuk68Q+KUsySjPWAfVd25tZaswFJ1GmknKsQA95w7AoDFTh11ND+JV27eGNVVNHEEvy4Py X-Received: by 2002:a17:906:2518:: with SMTP id i24mr19838652ejb.4.1574401959269; Thu, 21 Nov 2019 21:52:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574401959; cv=none; d=google.com; s=arc-20160816; b=OWi6b9BmGqrwkgyJLHUBGx0Wsd6qU5aC4fdd5fdbIhj2hFl9k6pUSNrTiUdNfQP8GG +HCDLvqKU4mbpYBDCQTqJa2N4MRzHWlaLskJp0xSAsUSP89+FLxy8K1rgKrObNhDrRtZ T5foFWkDg091lPGK1mWPVElueUysSZ7r2SwzSEhJx7sP3FHN1b2LE71iGy4wseaEi+UZ 5km4D53M+z8y46bsXqxWRxVdu/1u1H3+Qefh1AEJPcXLrEo6C8NyAgW1w4UHnrPT/5qG crCePrcCqnJPXxji+PnoJG4tsy3uSVOBvJsSBFY+AMTS//4Bo+0xHjWHPqGkn3KxuIsY 63Bw== 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=46CpC8rMu21HJBZHXmuxFV0PJNNFF+zCCpPw6ZQl5Oc=; b=BynWVKy0KTx28Wyxqt4cPXMl1XAW9fG7EVDCuoiAepyrAPjiCXy+xqehnVzPQOrruJ GwB5iMTMCRiel9/EpfHu4H8kl4GbzdQ8GPViuHJRmabfO0ibBfhwOSXIp7WSRKzY5zl+ LtoTgfWiXAv4cpiUGG7OdQQuZop3/PqMXWBKST2OyA5lDq4MMmaG8VWskUumGO0w3O2A pO35StyZoy5H7t4xJIClljpMV0O0BPJDYiIfnSJLMsiN0ol4QjNk14hdcWaFSxv7xOIr FiEDf2RlSUALZ4jdRxQ5YzKcgHykCvvgdmf7Y1MDEbzerypZr5iz8eIIb0CYMs460EZS Lc4Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=t6ElRlx0; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id fy15si3546592ejb.432.2019.11.21.21.52.15; Thu, 21 Nov 2019 21:52:39 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-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=@kernel.org header.s=default header.b=t6ElRlx0; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727735AbfKVFu3 (ORCPT + 99 others); Fri, 22 Nov 2019 00:50:29 -0500 Received: from mail.kernel.org ([198.145.29.99]:54996 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726836AbfKVFu1 (ORCPT ); Fri, 22 Nov 2019 00:50:27 -0500 Received: from sasha-vm.mshome.net (c-73-47-72-35.hsd1.nh.comcast.net [73.47.72.35]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 1F4A120717; Fri, 22 Nov 2019 05:50:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1574401826; bh=ZhYdnqrQS3F5kpXHrKSeIvpgv9N6bcqn9/aggzXh2+0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=t6ElRlx0LRre2ou7+frSRVjLZ6l1L3ByvzJpPAJbORXLnfovfGcNiwsT4gfIETp2m ygkXSCIJv0gVHs+18iTMQfdObbVBSdRkuUCnu+RjxdnFgjs6nzh40GbmPm/mbKDeVp uO9+z0iSB37m/RJ/ZK5y57D/URwSJxZhqZBNi+sU= From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Boris Brezillon , Miquel Raynal , Sasha Levin , linux-mtd@lists.infradead.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH AUTOSEL 4.19 069/219] mtd: rawnand: sunxi: Write pageprog related opcodes to WCMD_SET Date: Fri, 22 Nov 2019 00:46:41 -0500 Message-Id: <20191122054911.1750-62-sashal@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20191122054911.1750-1-sashal@kernel.org> References: <20191122054911.1750-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Boris Brezillon [ Upstream commit 732774437ae01d9882e60314e303898e63c7f038 ] The opcodes used by the controller when doing batched page prog should be written in NFC_REG_WCMD_SET not FC_REG_RCMD_SET. Luckily, the default NFC_REG_WCMD_SET value matches the one we set in the driver which explains why we didn't notice the problem. Fixes: 614049a8d904 ("mtd: nand: sunxi: add support for DMA assisted operations") Signed-off-by: Boris Brezillon Signed-off-by: Miquel Raynal Signed-off-by: Sasha Levin --- drivers/mtd/nand/raw/sunxi_nand.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mtd/nand/raw/sunxi_nand.c b/drivers/mtd/nand/raw/sunxi_nand.c index 1f0b7ee38df56..5b5f4d25a3e12 100644 --- a/drivers/mtd/nand/raw/sunxi_nand.c +++ b/drivers/mtd/nand/raw/sunxi_nand.c @@ -1397,7 +1397,7 @@ static int sunxi_nfc_hw_ecc_write_page_dma(struct mtd_info *mtd, sunxi_nfc_randomizer_enable(mtd); writel((NAND_CMD_RNDIN << 8) | NAND_CMD_PAGEPROG, - nfc->regs + NFC_REG_RCMD_SET); + nfc->regs + NFC_REG_WCMD_SET); dma_async_issue_pending(nfc->dmac); -- 2.20.1