mtd: nand: kill the ecc->layout field
authorBoris Brezillon <boris.brezillon@free-electrons.com>
Wed, 3 Feb 2016 18:24:10 +0000 (19:24 +0100)
committerBoris Brezillon <boris.brezillon@free-electrons.com>
Thu, 5 May 2016 21:51:50 +0000 (23:51 +0200)
Now that all NAND drivers have switched to mtd_ooblayout_ops, we can kill
the ecc->layout field.

Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
drivers/mtd/nand/nand_base.c
drivers/mtd/nand/nand_bch.c
include/linux/mtd/nand.h

index 6c84a40dbddb7dfc6264291d59906a57eec4fc9f..0001be19b90cd9f4c56456add1b9be4d3fa0dd9f 100644 (file)
@@ -4151,13 +4151,6 @@ int nand_scan_tail(struct mtd_info *mtd)
        /* Set the internal oob buffer location, just after the page data */
        chip->oob_poi = chip->buffers->databuf + mtd->writesize;
 
-       /*
-        * Set the provided ECC layout. If ecc->layout is NULL, the MTD core
-        * will just leave mtd->ooblayout to NULL, if it's not NULL, it will
-        * set ->ooblayout to the default ecclayout wrapper.
-        */
-       mtd_set_ecclayout(mtd, ecc->layout);
-
        /*
         * If no default placement scheme is given, select an appropriate one.
         */
index 1dbc418baac413a9b8513f51e8d7ab2a3c84ae33..28ef7b178eac74c02efed9720283e2d640ea0777 100644 (file)
@@ -158,14 +158,6 @@ struct nand_bch_control *nand_bch_init(struct mtd_info *mtd)
 
        eccsteps = mtd->writesize/eccsize;
 
-       /*
-        * Rely on the default ecclayout to ooblayout wrapper provided by MTD
-        * core if ecc.layout is not NULL.
-        * FIXME: this should be removed when all callers have moved to the
-        * mtd_ooblayout_ops approach.
-        */
-       mtd_set_ecclayout(mtd, nand->ecc.layout);
-
        /* Check that we have an oob layout description. */
        if (!mtd->ooblayout) {
                pr_warn("missing oob scheme");
index f2ded7b1b3b8b04a7f943db3300a79b987b2a4e2..e851839daf0937fe9ab3458102e80e4a2af273e2 100644 (file)
@@ -473,7 +473,6 @@ struct nand_hw_control {
  * @prepad:    padding information for syndrome based ECC generators
  * @postpad:   padding information for syndrome based ECC generators
  * @options:   ECC specific options (see NAND_ECC_XXX flags defined above)
- * @layout:    ECC layout control struct pointer
  * @priv:      pointer to private ECC control data
  * @hwctl:     function to control hardware ECC generator. Must only
  *             be provided if an hardware ECC is available
@@ -524,7 +523,6 @@ struct nand_ecc_ctrl {
        int prepad;
        int postpad;
        unsigned int options;
-       struct nand_ecclayout   *layout;
        void *priv;
        void (*hwctl)(struct mtd_info *mtd, int mode);
        int (*calculate)(struct mtd_info *mtd, const uint8_t *dat,
This page took 0.048936 seconds and 5 git commands to generate.