Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1f2d29e6 authored by Boris Brezillon's avatar Boris Brezillon Committed by Miquel Raynal
Browse files

mtd: rawnand: Move nand_exec_op() to internal.h



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: default avatarBoris Brezillon <boris.brezillon@bootlin.com>
Tested-by: default avatarJanusz Krzysztofik <jmkrzyszt@gmail.com>
Signed-off-by: default avatarMiquel Raynal <miquel.raynal@bootlin.com>
parent 996852a9
Loading
Loading
Loading
Loading
+9 −0
Original line number Original line Diff line number Diff line
@@ -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 panic_nand_wait(struct nand_chip *chip, unsigned long timeo);
void sanitize_string(uint8_t *s, size_t len);
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 */
/* BBT functions */
int nand_markbad_bbt(struct nand_chip *chip, loff_t offs);
int nand_markbad_bbt(struct nand_chip *chip, loff_t offs);
int nand_isreserved_bbt(struct nand_chip *chip, loff_t offs);
int nand_isreserved_bbt(struct nand_chip *chip, loff_t offs);
+0 −9
Original line number Original line Diff line number Diff line
@@ -1098,15 +1098,6 @@ struct nand_chip {
	} manufacturer;
	} 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_sp_ops;
extern const struct mtd_ooblayout_ops nand_ooblayout_lp_ops;
extern const struct mtd_ooblayout_ops nand_ooblayout_lp_ops;