aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ocfs2/super.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/ocfs2/super.c')
-rw-r--r--fs/ocfs2/super.c20
1 files changed, 17 insertions, 3 deletions
diff --git a/fs/ocfs2/super.c b/fs/ocfs2/super.c
index 47415398d56a..350e8b5a9396 100644
--- a/fs/ocfs2/super.c
+++ b/fs/ocfs2/super.c
@@ -514,11 +514,11 @@ static void ocfs2_release_system_inodes(struct ocfs2_super *osb)
514 514
515 mlog_entry_void(); 515 mlog_entry_void();
516 516
517 for (i = 0; i < NUM_SYSTEM_INODES; i++) { 517 for (i = 0; i < NUM_GLOBAL_SYSTEM_INODES; i++) {
518 inode = osb->system_inodes[i]; 518 inode = osb->global_system_inodes[i];
519 if (inode) { 519 if (inode) {
520 iput(inode); 520 iput(inode);
521 osb->system_inodes[i] = NULL; 521 osb->global_system_inodes[i] = NULL;
522 } 522 }
523 } 523 }
524 524
@@ -534,6 +534,20 @@ static void ocfs2_release_system_inodes(struct ocfs2_super *osb)
534 osb->root_inode = NULL; 534 osb->root_inode = NULL;
535 } 535 }
536 536
537 if (!osb->local_system_inodes)
538 goto out;
539
540 for (i = 0; i < NUM_LOCAL_SYSTEM_INODES * osb->max_slots; i++) {
541 if (osb->local_system_inodes[i]) {
542 iput(osb->local_system_inodes[i]);
543 osb->local_system_inodes[i] = NULL;
544 }
545 }
546
547 kfree(osb->local_system_inodes);
548 osb->local_system_inodes = NULL;
549
550out:
537 mlog_exit(0); 551 mlog_exit(0);
538} 552}
539 553