From patchwork Thu Apr 11 14:56:20 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Theodore Ts'o X-Patchwork-Id: 235784 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 7CC532C00C0 for ; Fri, 12 Apr 2013 00:56:28 +1000 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S935531Ab3DKO4Z (ORCPT ); Thu, 11 Apr 2013 10:56:25 -0400 Received: from li9-11.members.linode.com ([67.18.176.11]:33551 "EHLO imap.thunk.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932200Ab3DKO4Y (ORCPT ); Thu, 11 Apr 2013 10:56:24 -0400 Received: from root (helo=closure.thunk.org) by imap.thunk.org with local-esmtp (Exim 4.80) (envelope-from ) id 1UQIrW-0003ad-IX; Thu, 11 Apr 2013 14:52:30 +0000 Received: by closure.thunk.org (Postfix, from userid 15806) id 06DB72465DD; Thu, 11 Apr 2013 10:56:21 -0400 (EDT) Date: Thu, 11 Apr 2013 10:56:20 -0400 From: Theodore Ts'o To: =?utf-8?B?THVrw6HFoQ==?= Czerner Cc: linux-ext4@vger.kernel.org, gnehzuil.liu@gmail.com Subject: Re: [PATCH 1/2 v2] ext4: move ext4_ind_migrate() into migrate.c Message-ID: <20130411145620.GC8609@thunk.org> References: <1365506687-9216-1-git-send-email-lczerner@redhat.com> <20130411035826.GA18878@thunk.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: tytso@thunk.org X-SA-Exim-Scanned: No (on imap.thunk.org); SAEximRunCond expanded to false Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Thu, Apr 11, 2013 at 10:18:16AM +0200, Lukáš Czerner wrote: > Thanks, but Dmitry is right, the check should be before the > journal_start() call. Whoops! I'm not sure how I screwed that up. Thanks for catching that, Dmitry! > I am not sure how much work will it be for you, but would it be > possible to resend patch to the list when you change it ? Just to > make sure we do not get unnecessary problems. Yes, I'll try to do that in the future. Here's the revised patch.... - Ted commit 3b296c66fe6f9a6ed44b0b83f4f2ae87d8874af6 Author: Lukas Czerner Date: Thu Apr 11 10:54:46 2013 -0400 ext4: do not convert to indirect with bigalloc enabled With bigalloc feature enabled we do not support indirect addressing at all so we have to prevent extent addressing to indirect addressing conversion in this case. The problem has been introduced with the commit "ext4: support simple conversion of extent-mapped inodes to use i_blocks" Signed-off-by: Lukas Czerner Signed-off-by: "Theodore Ts'o" --- To unsubscribe from this list: send the line "unsubscribe linux-ext4" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/fs/ext4/migrate.c b/fs/ext4/migrate.c index d129a4d..49e8bdf 100644 --- a/fs/ext4/migrate.c +++ b/fs/ext4/migrate.c @@ -625,6 +625,10 @@ int ext4_ind_migrate(struct inode *inode) (!ext4_test_inode_flag(inode, EXT4_INODE_EXTENTS))) return -EINVAL; + if (EXT4_HAS_RO_COMPAT_FEATURE(inode->i_sb, + EXT4_FEATURE_RO_COMPAT_BIGALLOC)) + return -EOPNOTSUPP; + handle = ext4_journal_start(inode, EXT4_HT_MIGRATE, 1); if (IS_ERR(handle)) return PTR_ERR(handle);