aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/mtd
diff options
context:
space:
mode:
authorEzequiel Garcia <ezequiel@vanguardiasur.com.ar>2016-04-12 16:46:39 -0400
committerJacek Anaszewski <j.anaszewski@samsung.com>2016-04-13 04:23:14 -0400
commit0c034fe37718990e0ffdd9622bd6cc5b4f93111f (patch)
tree64dc76af5a7e7923387dd3706fab0ccdfb9be1cf /include/linux/mtd
parent916fe619951f41b55d4f2b9f26d64ad981bc0dfa (diff)
mtd: Uninline mtd_write_oob and move it to mtdcore.c
There's no reason for having mtd_write_oob inlined in mtd.h header. Move it to mtdcore.c where it belongs. Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com>
Diffstat (limited to 'include/linux/mtd')
-rw-r--r--include/linux/mtd/mtd.h12
1 files changed, 1 insertions, 11 deletions
diff --git a/include/linux/mtd/mtd.h b/include/linux/mtd/mtd.h
index 771272187316..ef9fea4fc400 100644
--- a/include/linux/mtd/mtd.h
+++ b/include/linux/mtd/mtd.h
@@ -283,17 +283,7 @@ int mtd_panic_write(struct mtd_info *mtd, loff_t to, size_t len, size_t *retlen,
283 const u_char *buf); 283 const u_char *buf);
284 284
285int mtd_read_oob(struct mtd_info *mtd, loff_t from, struct mtd_oob_ops *ops); 285int mtd_read_oob(struct mtd_info *mtd, loff_t from, struct mtd_oob_ops *ops);
286 286int mtd_write_oob(struct mtd_info *mtd, loff_t to, struct mtd_oob_ops *ops);
287static inline int mtd_write_oob(struct mtd_info *mtd, loff_t to,
288 struct mtd_oob_ops *ops)
289{
290 ops->retlen = ops->oobretlen = 0;
291 if (!mtd->_write_oob)
292 return -EOPNOTSUPP;
293 if (!(mtd->flags & MTD_WRITEABLE))
294 return -EROFS;
295 return mtd->_write_oob(mtd, to, ops);
296}
297 287
298int mtd_get_fact_prot_info(struct mtd_info *mtd, size_t len, size_t *retlen, 288int mtd_get_fact_prot_info(struct mtd_info *mtd, size_t len, size_t *retlen,
299 struct otp_info *buf); 289 struct otp_info *buf);