From: Yongqiang Yang <xiaoqiangnk@gmail.com>
To: linux-ext4@vger.kernel.org
Cc: tytso@mit.edu, Yongqiang Yang <xiaoqiangnk@gmail.com>
Subject: [PATCH] resize2fs: support online-resizing for meta_bg and 64bits features
Date: Sun, 2 Sep 2012 17:52:29 +0800 [thread overview]
Message-ID: <1346579549-25122-1-git-send-email-xiaoqiangnk@gmail.com> (raw)
This patch supports online-resizing for meata_bg and 64bits features.
Signed-off-by: Yongqiang Yang <xiaoqiangnk@gmail.com>
---
resize/main.c | 5 +++--
resize/online.c | 6 +++---
2 files changed, 6 insertions(+), 5 deletions(-)
diff --git a/resize/main.c b/resize/main.c
index ffefe01..b3a7840 100644
--- a/resize/main.c
+++ b/resize/main.c
@@ -324,9 +324,10 @@ int main (int argc, char ** argv)
* This is something we should fix eventually, though.
*/
if ((fs->super->s_feature_incompat & EXT4_FEATURE_INCOMPAT_FLEX_BG) &&
- !(fs->super->s_feature_compat & EXT2_FEATURE_COMPAT_RESIZE_INODE)) {
+ !(fs->super->s_feature_compat & EXT2_FEATURE_COMPAT_RESIZE_INODE) &&
+ !(fs->super->s_feature_incompat & EXT2_FEATURE_INCOMPAT_META_BG)) {
com_err(program_name, 0, _("%s: The combination of flex_bg "
- "and\n\t!resize_inode features "
+ "and\n\t!resize_inode and !meta_bg features "
"is not supported by resize2fs.\n"),
device_name);
exit(1);
diff --git a/resize/online.c b/resize/online.c
index 966ea1e..e7891bd 100644
--- a/resize/online.c
+++ b/resize/online.c
@@ -56,9 +56,9 @@ errcode_t online_resize_fs(ext2_filsys fs, const char *mtpt,
EXT2_DESC_PER_BLOCK(fs->super));
printf("old_desc_blocks = %lu, new_desc_blocks = %lu\n",
fs->desc_blocks, new_desc_blocks);
- if (!(fs->super->s_feature_compat &
- EXT2_FEATURE_COMPAT_RESIZE_INODE) &&
- new_desc_blocks != fs->desc_blocks) {
+ if (!(fs->super->s_feature_compat & EXT2_FEATURE_COMPAT_RESIZE_INODE) &&
+ new_desc_blocks != fs->desc_blocks &&
+ !(fs->super->s_feature_incompat & EXT2_FEATURE_INCOMPAT_META_BG)) {
com_err(program_name, 0,
_("Filesystem does not support online resizing"));
exit(1);
--
1.7.5.1
next reply other threads:[~2012-09-02 10:27 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-02 9:52 Yongqiang Yang [this message]
2012-09-02 10:31 ` [PATCH] resize2fs: support online-resizing for meta_bg and 64bits features Yongqiang Yang
2012-09-03 0:50 ` Theodore Ts'o
2012-09-03 16:45 ` Theodore Ts'o
2012-09-03 16:45 ` [PATCH 1/2] resize2fs: allow meta_bg/64-bit file systems to be online resized Theodore Ts'o
2012-09-03 16:45 ` [PATCH 2/2] resize2fs: fix overhead calculation for meta_bg file systems Theodore Ts'o
2012-09-04 1:59 ` Yongqiang Yang
2012-09-04 2:14 ` Kevin Liao
2012-09-04 2:14 ` Theodore Ts'o
2012-09-04 17:05 ` Anssi Hannula
2012-09-05 2:10 ` Yongqiang Yang
2012-09-05 4:55 ` Theodore Ts'o
2012-09-05 5:16 ` Yongqiang Yang
2012-09-05 5:38 ` Theodore Ts'o
2012-09-06 14:22 ` Anssi Hannula
2012-09-06 16:19 ` Yongqiang Yang
2012-09-05 6:32 ` Kevin Liao
2012-09-05 6:44 ` Yongqiang Yang
2012-09-05 6:50 ` Kevin Liao
2012-09-13 23:21 ` Theodore Ts'o
2012-09-14 3:24 ` Kevin Liao
2012-09-04 2:02 ` Yongqiang Yang
2012-09-03 21:02 ` [PATCH] resize2fs: support online-resizing for meta_bg and 64bits features Kai Grosshaus
2012-09-03 23:00 ` Theodore Ts'o
2012-09-03 23:33 ` Kai Großhaus
2012-09-04 2:01 ` Yongqiang Yang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1346579549-25122-1-git-send-email-xiaoqiangnk@gmail.com \
--to=xiaoqiangnk@gmail.com \
--cc=linux-ext4@vger.kernel.org \
--cc=tytso@mit.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).