From: sa <saproj@gmail.com>
To: linux-mtd@lists.infradead.org
Cc: Sergei Antonov <saproj@gmail.com>,
Liang Yang <liang.yang@amlogic.com>,
Yixun Lan <yixun.lan@amlogic.com>,
Jianxin Pan <jianxin.pan@amlogic.com>,
Miquel Raynal <miquel.raynal@bootlin.com>
Subject: [PATCH] mtd: meson: fix meson_nfc_dma_buffer_release() arguments
Date: Wed, 28 Oct 2020 01:20:15 +0300 [thread overview]
Message-ID: <20201027222015.17508-1-sa@sas-MacBook-Pro.lan> (raw)
From: Sergei Antonov <saproj@gmail.com>
Arguments 'infolen' and 'datalen' to meson_nfc_dma_buffer_release() were mixed up.
Also extra spaces removed.
Signed-off-by: Sergei Antonov <saproj@gmail.com>
Cc: Miquel Raynal <miquel.raynal@bootlin.com>
Cc: Liang Yang <liang.yang@amlogic.com>
Cc: Yixun Lan <yixun.lan@amlogic.com>
Cc: Jianxin Pan <jianxin.pan@amlogic.com>
---
drivers/mtd/nand/raw/meson_nand.c | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/drivers/mtd/nand/raw/meson_nand.c b/drivers/mtd/nand/raw/meson_nand.c
index 48e6dac96be6..578373a3d213 100644
--- a/drivers/mtd/nand/raw/meson_nand.c
+++ b/drivers/mtd/nand/raw/meson_nand.c
@@ -246,7 +246,7 @@ static void meson_nfc_select_chip(struct nand_chip *nand, int chip)
value = (NFC_CLK_CYCLE - 1) | (meson_chip->bus_timing << 5);
writel(value, nfc->reg_base + NFC_REG_CFG);
writel((1 << 31), nfc->reg_base + NFC_REG_CMD);
- nfc->bus_timing = meson_chip->bus_timing;
+ nfc->bus_timing = meson_chip->bus_timing;
}
}
@@ -510,7 +510,7 @@ static int meson_nfc_dma_buffer_setup(struct nand_chip *nand, void *databuf,
}
static void meson_nfc_dma_buffer_release(struct nand_chip *nand,
- int infolen, int datalen,
+ int datalen, int infolen,
enum dma_data_direction dir)
{
struct meson_nfc *nfc = nand_get_controller_data(nand);
@@ -637,7 +637,7 @@ static int meson_nfc_write_page_sub(struct nand_chip *nand,
meson_nfc_select_chip(nand, nand->cur_cs);
- data_len = mtd->writesize + mtd->oobsize;
+ data_len = mtd->writesize + mtd->oobsize;
info_len = nand->ecc.steps * PER_INFO_BYTE;
ret = meson_nfc_rw_cmd_prepare_and_execute(nand, page, DIRWRITE);
@@ -721,7 +721,7 @@ static int meson_nfc_read_page_sub(struct nand_chip *nand,
meson_nfc_select_chip(nand, nand->cur_cs);
- data_len = mtd->writesize + mtd->oobsize;
+ data_len = mtd->writesize + mtd->oobsize;
info_len = nand->ecc.steps * PER_INFO_BYTE;
ret = meson_nfc_rw_cmd_prepare_and_execute(nand, page, DIRREAD);
@@ -792,7 +792,7 @@ static int meson_nfc_read_page_hwecc(struct nand_chip *nand, u8 *buf,
mtd->ecc_stats.failed++;
return bitflips;
}
- ret = meson_nfc_read_page_raw(nand, buf, 0, page);
+ ret = meson_nfc_read_page_raw(nand, buf, 0, page);
if (ret)
return ret;
@@ -810,7 +810,7 @@ static int meson_nfc_read_page_hwecc(struct nand_chip *nand, u8 *buf,
mtd->ecc_stats.failed++;
} else {
mtd->ecc_stats.corrected += ret;
- bitflips = max_t(u32, bitflips, ret);
+ bitflips = max_t(u32, bitflips, ret);
}
}
} else if (buf && buf != meson_chip->data_buf) {
@@ -960,7 +960,7 @@ static int meson_ooblayout_ecc(struct mtd_info *mtd, int section,
if (section >= nand->ecc.steps)
return -ERANGE;
- oobregion->offset = 2 + (section * (2 + nand->ecc.bytes));
+ oobregion->offset = 2 + (section * (2 + nand->ecc.bytes));
oobregion->length = nand->ecc.bytes;
return 0;
@@ -1080,7 +1080,7 @@ static int meson_chip_buffer_init(struct nand_chip *nand)
nsectors = mtd->writesize / nand->ecc.size;
- page_bytes = mtd->writesize + mtd->oobsize;
+ page_bytes = mtd->writesize + mtd->oobsize;
info_bytes = nsectors * PER_INFO_BYTE;
meson_chip->data_buf = kmalloc(page_bytes, GFP_KERNEL);
@@ -1459,7 +1459,7 @@ static struct platform_driver meson_nfc_driver = {
.probe = meson_nfc_probe,
.remove = meson_nfc_remove,
.driver = {
- .name = "meson-nand",
+ .name = "meson-nand",
.of_match_table = meson_nfc_id_table,
},
};
--
2.17.1
______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
next reply other threads:[~2020-10-27 22:21 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-27 22:20 sa [this message]
2020-10-28 8:12 ` [PATCH] mtd: meson: fix meson_nfc_dma_buffer_release() arguments Miquel Raynal
-- strict thread matches above, loose matches on Subject: below --
2020-10-28 9:49 Sergei Antonov
2020-10-28 9:49 ` Sergei Antonov
2020-10-28 10:03 ` Miquel Raynal
2020-10-28 10:03 ` Miquel Raynal
2020-10-30 2:22 ` Liang Yang
2020-10-30 2:22 ` Liang Yang
2020-10-30 17:27 ` Miquel Raynal
2020-10-30 17:27 ` Miquel Raynal
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201027222015.17508-1-sa@sas-MacBook-Pro.lan \
--to=saproj@gmail.com \
--cc=jianxin.pan@amlogic.com \
--cc=liang.yang@amlogic.com \
--cc=linux-mtd@lists.infradead.org \
--cc=miquel.raynal@bootlin.com \
--cc=yixun.lan@amlogic.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.