From f483a09a0f7565914f0765de77fbdcac3349a456 Mon Sep 17 00:00:00 2001 From: Adrian Hunter Date: Mon, 21 Jul 2008 15:39:05 +0300 Subject: [PATCH] --- yaml --- r: 108536 b: refs/heads/master c: ff46d7b3e0870a70331b069372c36fbc43018c2d h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/fs/ubifs/io.c | 14 ++++++++++++++ trunk/fs/ubifs/misc.h | 14 -------------- trunk/fs/ubifs/ubifs.h | 1 + 4 files changed, 16 insertions(+), 15 deletions(-) diff --git a/[refs] b/[refs] index a8135830c5e1..6e571d7ed2ef 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 2fb42b11f61cbcef7dfc225c1d26c4511436583d +refs/heads/master: ff46d7b3e0870a70331b069372c36fbc43018c2d diff --git a/trunk/fs/ubifs/io.c b/trunk/fs/ubifs/io.c index 3374f91b6709..054363f2b207 100644 --- a/trunk/fs/ubifs/io.c +++ b/trunk/fs/ubifs/io.c @@ -53,6 +53,20 @@ #include #include "ubifs.h" +/** + * ubifs_ro_mode - switch UBIFS to read read-only mode. + * @c: UBIFS file-system description object + * @err: error code which is the reason of switching to R/O mode + */ +void ubifs_ro_mode(struct ubifs_info *c, int err) +{ + if (!c->ro_media) { + c->ro_media = 1; + ubifs_warn("switched to read-only mode, error %d", err); + dbg_dump_stack(); + } +} + /** * ubifs_check_node - check node. * @c: UBIFS file-system description object diff --git a/trunk/fs/ubifs/misc.h b/trunk/fs/ubifs/misc.h index 4beccfc256d2..cd83ffc8101c 100644 --- a/trunk/fs/ubifs/misc.h +++ b/trunk/fs/ubifs/misc.h @@ -79,20 +79,6 @@ static inline struct ubifs_inode *ubifs_inode(const struct inode *inode) return container_of(inode, struct ubifs_inode, vfs_inode); } -/** - * ubifs_ro_mode - switch UBIFS to read read-only mode. - * @c: UBIFS file-system description object - * @err: error code which is the reason of switching to R/O mode - */ -static inline void ubifs_ro_mode(struct ubifs_info *c, int err) -{ - if (!c->ro_media) { - c->ro_media = 1; - ubifs_warn("switched to read-only mode, error %d", err); - dbg_dump_stack(); - } -} - /** * ubifs_compr_present - check if compressor was compiled in. * @compr_type: compressor type to check diff --git a/trunk/fs/ubifs/ubifs.h b/trunk/fs/ubifs/ubifs.h index e4f89f271827..c488d43b6359 100644 --- a/trunk/fs/ubifs/ubifs.h +++ b/trunk/fs/ubifs/ubifs.h @@ -1346,6 +1346,7 @@ extern struct backing_dev_info ubifs_backing_dev_info; extern struct ubifs_compressor *ubifs_compressors[UBIFS_COMPR_TYPES_CNT]; /* io.c */ +void ubifs_ro_mode(struct ubifs_info *c, int err); int ubifs_wbuf_write_nolock(struct ubifs_wbuf *wbuf, void *buf, int len); int ubifs_wbuf_seek_nolock(struct ubifs_wbuf *wbuf, int lnum, int offs, int dtype);