]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
ocfs2: allocate btree internal block groups from the global bitmap
authorMark Fasheh <mfasheh@suse.com>
Wed, 24 Feb 2010 21:34:09 +0000 (13:34 -0800)
committerJoel Becker <joel.becker@oracle.com>
Thu, 6 May 2010 01:17:31 +0000 (18:17 -0700)
Otherwise, the need for a very large contiguous allocation tends to
wreak havoc on many inode allocation reservations on the local alloc, thus
ruining any chances for contiguousness.

Signed-off-by: Mark Fasheh <mfasheh@suse.com>
fs/ocfs2/suballoc.c

index f20bcbf64ce007e3dce7d25022e6552bb82c3111..df95707c8b106550c93f35923a20f22d0552c19c 100644 (file)
@@ -755,7 +755,7 @@ int ocfs2_reserve_new_metadata_blocks(struct ocfs2_super *osb,
        status = ocfs2_reserve_suballoc_bits(osb, (*ac),
                                             EXTENT_ALLOC_SYSTEM_INODE,
                                             (u32)osb->slot_num, NULL,
-                                            ALLOC_NEW_GROUP);
+                                            ALLOC_GROUPS_FROM_GLOBAL|ALLOC_NEW_GROUP);
 
 
        if (status >= 0) {
@@ -1871,6 +1871,8 @@ int __ocfs2_claim_clusters(struct ocfs2_super *osb,
               && ac->ac_which != OCFS2_AC_USE_MAIN);
 
        if (ac->ac_which == OCFS2_AC_USE_LOCAL) {
+               WARN_ON(min_clusters > 1);
+
                status = ocfs2_claim_local_alloc_bits(osb,
                                                      handle,
                                                      ac,