ialloc.c (088fecfbb2c8a3890918fc614a7e1e1ccdd16c83) | ialloc.c (1751e8a6cb935e555fcdbcb9ab4f0446e322ca3e) |
---|---|
1// SPDX-License-Identifier: GPL-2.0 2/* 3 * linux/fs/ext2/ialloc.c 4 * 5 * Copyright (C) 1992, 1993, 1994, 1995 6 * Remy Card (card@masi.ibp.fr) 7 * Laboratoire MASI - Institut Blaise Pascal 8 * Universite Pierre et Marie Curie (Paris VI) --- 131 unchanged lines hidden (view full) --- 140 /* Ok, now we can actually update the inode bitmaps.. */ 141 if (!ext2_clear_bit_atomic(sb_bgl_lock(EXT2_SB(sb), block_group), 142 bit, (void *) bitmap_bh->b_data)) 143 ext2_error (sb, "ext2_free_inode", 144 "bit already cleared for inode %lu", ino); 145 else 146 ext2_release_inode(sb, block_group, is_directory); 147 mark_buffer_dirty(bitmap_bh); | 1// SPDX-License-Identifier: GPL-2.0 2/* 3 * linux/fs/ext2/ialloc.c 4 * 5 * Copyright (C) 1992, 1993, 1994, 1995 6 * Remy Card (card@masi.ibp.fr) 7 * Laboratoire MASI - Institut Blaise Pascal 8 * Universite Pierre et Marie Curie (Paris VI) --- 131 unchanged lines hidden (view full) --- 140 /* Ok, now we can actually update the inode bitmaps.. */ 141 if (!ext2_clear_bit_atomic(sb_bgl_lock(EXT2_SB(sb), block_group), 142 bit, (void *) bitmap_bh->b_data)) 143 ext2_error (sb, "ext2_free_inode", 144 "bit already cleared for inode %lu", ino); 145 else 146 ext2_release_inode(sb, block_group, is_directory); 147 mark_buffer_dirty(bitmap_bh); |
148 if (sb->s_flags & MS_SYNCHRONOUS) | 148 if (sb->s_flags & SB_SYNCHRONOUS) |
149 sync_dirty_buffer(bitmap_bh); 150 151 brelse(bitmap_bh); 152} 153 154/* 155 * We perform asynchronous prereading of the new inode's inode block when 156 * we create the inode, in the expectation that the inode will be written --- 355 unchanged lines hidden (view full) --- 512 513 /* 514 * Scanned all blockgroups. 515 */ 516 err = -ENOSPC; 517 goto fail; 518got: 519 mark_buffer_dirty(bitmap_bh); | 149 sync_dirty_buffer(bitmap_bh); 150 151 brelse(bitmap_bh); 152} 153 154/* 155 * We perform asynchronous prereading of the new inode's inode block when 156 * we create the inode, in the expectation that the inode will be written --- 355 unchanged lines hidden (view full) --- 512 513 /* 514 * Scanned all blockgroups. 515 */ 516 err = -ENOSPC; 517 goto fail; 518got: 519 mark_buffer_dirty(bitmap_bh); |
520 if (sb->s_flags & MS_SYNCHRONOUS) | 520 if (sb->s_flags & SB_SYNCHRONOUS) |
521 sync_dirty_buffer(bitmap_bh); 522 brelse(bitmap_bh); 523 524 ino += group * EXT2_INODES_PER_GROUP(sb) + 1; 525 if (ino < EXT2_FIRST_INO(sb) || ino > le32_to_cpu(es->s_inodes_count)) { 526 ext2_error (sb, "ext2_new_inode", 527 "reserved inode or inode > inodes count - " 528 "block_group = %d,inode=%lu", group, --- 156 unchanged lines hidden --- | 521 sync_dirty_buffer(bitmap_bh); 522 brelse(bitmap_bh); 523 524 ino += group * EXT2_INODES_PER_GROUP(sb) + 1; 525 if (ino < EXT2_FIRST_INO(sb) || ino > le32_to_cpu(es->s_inodes_count)) { 526 ext2_error (sb, "ext2_new_inode", 527 "reserved inode or inode > inodes count - " 528 "block_group = %d,inode=%lu", group, --- 156 unchanged lines hidden --- |