From: "Teresa Gámez" <t.gamez@phytec.de>
To: barebox@lists.infradead.org
Subject: [PATCH 1/2] mtd: nand_omap_gpmc: Remove unused code
Date: Mon, 30 Mar 2015 15:51:04 +0200 [thread overview]
Message-ID: <1427723465-9306-1-git-send-email-t.gamez@phytec.de> (raw)
The ecc layout structs are not used anywhere.
Signed-off-by: Teresa Gámez <t.gamez@phytec.de>
---
drivers/mtd/nand/nand_omap_gpmc.c | 68 ---------------------------------------
1 file changed, 68 deletions(-)
diff --git a/drivers/mtd/nand/nand_omap_gpmc.c b/drivers/mtd/nand/nand_omap_gpmc.c
index d254042..647605b 100644
--- a/drivers/mtd/nand/nand_omap_gpmc.c
+++ b/drivers/mtd/nand/nand_omap_gpmc.c
@@ -130,53 +130,6 @@ static struct nand_bbt_descr bb_descrip_flashbased = {
.pattern = scan_ff_pattern,
};
-/** Large Page x8 NAND device Layout */
-static struct nand_ecclayout ecc_lp_x8 = {
- .eccbytes = 12,
- .eccpos = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12},
- .oobfree = {
- {
- .offset = 60,
- .length = 2,
- }
- }
-};
-
-/** Large Page x16 NAND device Layout */
-static struct nand_ecclayout ecc_lp_x16 = {
- .eccbytes = 12,
- .eccpos = {2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13},
- .oobfree = {
- {
- .offset = 60,
- .length = 2,
- }
- }
-};
-
-/** Small Page x8 NAND device Layout */
-static struct nand_ecclayout ecc_sp_x8 = {
- .eccbytes = 3,
- .eccpos = {1, 2, 3},
- .oobfree = {
- {
- .offset = 14,
- .length = 2,
- }
- }
-};
-
-/** Small Page x16 NAND device Layout */
-static struct nand_ecclayout ecc_sp_x16 = {
- .eccbytes = 3,
- .eccpos = {2, 3, 4},
- .oobfree = {
- {
- .offset = 14,
- .length = 2 }
- }
-};
-
/**
* @brief calls the platform specific dev_ready functionds
*
@@ -891,7 +844,6 @@ static int gpmc_nand_probe(struct device_d *pdev)
struct mtd_info *minfo;
void __iomem *cs_base;
int err;
- struct nand_ecclayout *layout, *lsp, *llp;
pdata = (struct gpmc_nand_platform_data *)pdev->platform_data;
if (pdata == NULL) {
@@ -1012,26 +964,6 @@ static int gpmc_nand_probe(struct device_d *pdev)
gpmc_set_buswidth(nand, nand->options & NAND_BUSWIDTH_16);
- if (nand->options & NAND_BUSWIDTH_16) {
- lsp = &ecc_sp_x16;
- llp = &ecc_lp_x16;
- } else {
- lsp = &ecc_sp_x8;
- llp = &ecc_lp_x8;
- }
-
- switch (minfo->writesize) {
- case 512:
- layout = lsp;
- break;
- case 2048:
- layout = llp;
- break;
- default:
- err = -EINVAL;
- goto out_release_mem;
- }
-
nand->read_buf = omap_read_buf_pref;
if (IS_ENABLED(CONFIG_MTD_WRITE))
nand->write_buf = omap_write_buf_pref;
--
1.9.1
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next reply other threads:[~2015-03-30 13:54 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-30 13:51 Teresa Gámez [this message]
2015-03-30 13:51 ` [PATCH 2/2] mtd: nand_omap_gpmc: Fix ecc check for bch8 romcode Teresa Gámez
2015-03-30 17:27 ` [PATCH 1/2] mtd: nand_omap_gpmc: Remove unused code Sascha Hauer
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=1427723465-9306-1-git-send-email-t.gamez@phytec.de \
--to=t.gamez@phytec.de \
--cc=barebox@lists.infradead.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox