]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
mtd: rawnand: Move nand_exec_op() to internal.h
authorBoris Brezillon <boris.brezillon@bootlin.com>
Sun, 11 Nov 2018 07:55:06 +0000 (08:55 +0100)
committerMiquel Raynal <miquel.raynal@bootlin.com>
Fri, 7 Dec 2018 09:38:24 +0000 (10:38 +0100)
nand_exec_op() is only used by core code (nand_xxx.c files). Let's
move this inline function in drivers/mtd/nand/raw/internals.h.

Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>
Tested-by: Janusz Krzysztofik <jmkrzyszt@gmail.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
drivers/mtd/nand/raw/internals.h
include/linux/mtd/rawnand.h

index 04c2cf74eff3e397779874d82d4155d456b5009b..6e2f61fbc5f0c4c31abf5a7240440aab3a4a5ce7 100644 (file)
@@ -95,6 +95,15 @@ void nand_decode_ext_id(struct nand_chip *chip);
 void panic_nand_wait(struct nand_chip *chip, unsigned long timeo);
 void sanitize_string(uint8_t *s, size_t len);
 
+static inline int nand_exec_op(struct nand_chip *chip,
+                              const struct nand_operation *op)
+{
+       if (!chip->exec_op)
+               return -ENOTSUPP;
+
+       return chip->exec_op(chip, op, false);
+}
+
 /* BBT functions */
 int nand_markbad_bbt(struct nand_chip *chip, loff_t offs);
 int nand_isreserved_bbt(struct nand_chip *chip, loff_t offs);
index 4e91a70ede10aa68d1e405963161f38aaf8ddd8d..85dd89abcd2201b0a0efb564ebb794072ae4fd07 100644 (file)
@@ -1098,15 +1098,6 @@ struct nand_chip {
        } manufacturer;
 };
 
-static inline int nand_exec_op(struct nand_chip *chip,
-                              const struct nand_operation *op)
-{
-       if (!chip->exec_op)
-               return -ENOTSUPP;
-
-       return chip->exec_op(chip, op, false);
-}
-
 extern const struct mtd_ooblayout_ops nand_ooblayout_sp_ops;
 extern const struct mtd_ooblayout_ops nand_ooblayout_lp_ops;