From patchwork Fri Aug 9 00:22:22 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Brian Norris X-Patchwork-Id: 265867 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from casper.infradead.org (unknown [IPv6:2001:770:15f::2]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id A244F2C0097 for ; Fri, 9 Aug 2013 10:23:26 +1000 (EST) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1V7aU6-0003Vh-7Z; Fri, 09 Aug 2013 00:23:14 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1V7aU4-0006uN-Fm; Fri, 09 Aug 2013 00:23:12 +0000 Received: from mail-ob0-x230.google.com ([2607:f8b0:4003:c01::230]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1V7aU2-0006ty-4O for linux-mtd@lists.infradead.org; Fri, 09 Aug 2013 00:23:10 +0000 Received: by mail-ob0-f176.google.com with SMTP id uz19so5695496obc.7 for ; Thu, 08 Aug 2013 17:22:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=L4M0l3Tl0dt2NRHC18pox+j0ZlJYAVZh/dfhZQQb+Es=; b=zYTyZDHu0lH2IDnrFwTUvHcn0zA9Vj9W5IxPVHUcwmzIueBzpfjnG7m0oYpHwy0DYs wjg5ab+lQehim7b52nYViSd+r8S5yiY9m7Iml1squ8YTUGg1e2EJjQcWzwhvWoZd6zz9 jC/OHu6ZFsFHe+SvsADJeBPf0gZBAa1UQuNMKY8z9Fu4f7Ka21UOhOsUhPNdEApzifQS syLn+Hxhi8ZETIsXswqjWfWxI2wPyk/bhZukC0a72Li8g789AmqhsD8Z9GdSOWT9ae4f TEBqTwQ5u7NCIKYZNfKffWC35q2IdTTu4Xh2JtORTEmNuZRM68UYbavH6cnO5TwifT7j Mjbw== X-Received: by 10.182.230.135 with SMTP id sy7mr1231035obc.24.1376007768866; Thu, 08 Aug 2013 17:22:48 -0700 (PDT) Received: from localhost.localdomain (5.sub-70-197-84.myvzw.com. [70.197.84.5]) by mx.google.com with ESMTPSA id ps5sm16576490oeb.8.2013.08.08.17.22.46 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 08 Aug 2013 17:22:48 -0700 (PDT) From: Brian Norris To: Subject: [PATCH] mtd: nand: fixup kerneldoc, rename parameter Date: Thu, 8 Aug 2013 17:22:22 -0700 Message-Id: <1376007742-19392-1-git-send-email-computersforpeace@gmail.com> X-Mailer: git-send-email 1.8.1.2 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130808_202310_269226_54E3D23D X-CRM114-Status: UNSURE ( 9.58 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.0 (--) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-2.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (computersforpeace[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature Cc: Brian Norris , "Gupta, Pekon" , Artem Bityutskiy X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-mtd" Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org First, the function argument is 'offset' not 'column'. Second, the 'data_buf' name is inconsistent with the rest of this file. Just use 'buf'. Signed-off-by: Brian Norris Cc: Gupta, Pekon --- drivers/mtd/nand/nand_base.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/drivers/mtd/nand/nand_base.c b/drivers/mtd/nand/nand_base.c index 8f04fb0..49ca737 100644 --- a/drivers/mtd/nand/nand_base.c +++ b/drivers/mtd/nand/nand_base.c @@ -1980,13 +1980,14 @@ static int nand_write_page_hwecc(struct mtd_info *mtd, struct nand_chip *chip, * nand_write_subpage_hwecc - [REPLACABLE] hardware ECC based subpage write * @mtd: mtd info structure * @chip: nand chip info structure - * @column: column address of subpage within the page + * @offset: column address of subpage within the page * @data_len: data length + * @buf: data buffer * @oob_required: must write chip->oob_poi to OOB */ static int nand_write_subpage_hwecc(struct mtd_info *mtd, struct nand_chip *chip, uint32_t offset, - uint32_t data_len, const uint8_t *data_buf, + uint32_t data_len, const uint8_t *buf, int oob_required) { uint8_t *oob_buf = chip->oob_poi; @@ -2005,20 +2006,20 @@ static int nand_write_subpage_hwecc(struct mtd_info *mtd, chip->ecc.hwctl(mtd, NAND_ECC_WRITE); /* write data (untouched subpages already masked by 0xFF) */ - chip->write_buf(mtd, data_buf, ecc_size); + chip->write_buf(mtd, buf, ecc_size); /* mask ECC of un-touched subpages by padding 0xFF */ if ((step < start_step) || (step > end_step)) memset(ecc_calc, 0xff, ecc_bytes); else - chip->ecc.calculate(mtd, data_buf, ecc_calc); + chip->ecc.calculate(mtd, buf, ecc_calc); /* mask OOB of un-touched subpages by padding 0xFF */ /* if oob_required, preserve OOB metadata of written subpage */ if (!oob_required || (step < start_step) || (step > end_step)) memset(oob_buf, 0xff, oob_bytes); - data_buf += ecc_size; + buf += ecc_size; ecc_calc += ecc_bytes; oob_buf += oob_bytes; }