tag | line | file | source code |
sb | 46 | fs/ext/freelists.c | void ext_free_block(struct super_block * sb, int block) |
sb | 51 | fs/ext/freelists.c | if (!sb) { |
sb | 55 | fs/ext/freelists.c | lock_super (sb); |
sb | 56 | fs/ext/freelists.c | if (block < sb->u.ext_sb.s_firstdatazone || |
sb | 57 | fs/ext/freelists.c | block >= sb->u.ext_sb.s_nzones) { |
sb | 61 | fs/ext/freelists.c | bh = get_hash_table(sb->s_dev, block, sb->s_blocksize); |
sb | 65 | fs/ext/freelists.c | if (sb->u.ext_sb.s_firstfreeblock) |
sb | 66 | fs/ext/freelists.c | efb = (struct ext_free_block *) sb->u.ext_sb.s_firstfreeblock->b_data; |
sb | 67 | fs/ext/freelists.c | if (!sb->u.ext_sb.s_firstfreeblock || efb->count == 254) { |
sb | 71 | fs/ext/freelists.c | if (sb->u.ext_sb.s_firstfreeblock) |
sb | 72 | fs/ext/freelists.c | brelse (sb->u.ext_sb.s_firstfreeblock); |
sb | 73 | fs/ext/freelists.c | if (!(sb->u.ext_sb.s_firstfreeblock = bread (sb->s_dev, |
sb | 74 | fs/ext/freelists.c | block, sb->s_blocksize))) |
sb | 76 | fs/ext/freelists.c | efb = (struct ext_free_block *) sb->u.ext_sb.s_firstfreeblock->b_data; |
sb | 77 | fs/ext/freelists.c | efb->next = sb->u.ext_sb.s_firstfreeblocknumber; |
sb | 79 | fs/ext/freelists.c | sb->u.ext_sb.s_firstfreeblocknumber = block; |
sb | 83 | fs/ext/freelists.c | sb->u.ext_sb.s_freeblockscount ++; |
sb | 84 | fs/ext/freelists.c | sb->s_dirt = 1; |
sb | 85 | fs/ext/freelists.c | sb->u.ext_sb.s_firstfreeblock->b_dirt = 1; |
sb | 86 | fs/ext/freelists.c | unlock_super (sb); |
sb | 90 | fs/ext/freelists.c | int ext_new_block(struct super_block * sb) |
sb | 96 | fs/ext/freelists.c | if (!sb) { |
sb | 100 | fs/ext/freelists.c | if (!sb->u.ext_sb.s_firstfreeblock) |
sb | 102 | fs/ext/freelists.c | lock_super (sb); |
sb | 103 | fs/ext/freelists.c | efb = (struct ext_free_block *) sb->u.ext_sb.s_firstfreeblock->b_data; |
sb | 106 | fs/ext/freelists.c | sb->u.ext_sb.s_firstfreeblock->b_dirt = 1; |
sb | 111 | fs/ext/freelists.c | j = sb->u.ext_sb.s_firstfreeblocknumber; |
sb | 112 | fs/ext/freelists.c | sb->u.ext_sb.s_firstfreeblocknumber = efb->next; |
sb | 113 | fs/ext/freelists.c | brelse (sb->u.ext_sb.s_firstfreeblock); |
sb | 114 | fs/ext/freelists.c | if (!sb->u.ext_sb.s_firstfreeblocknumber) { |
sb | 115 | fs/ext/freelists.c | sb->u.ext_sb.s_firstfreeblock = NULL; |
sb | 117 | fs/ext/freelists.c | if (!(sb->u.ext_sb.s_firstfreeblock = bread (sb->s_dev, |
sb | 118 | fs/ext/freelists.c | sb->u.ext_sb.s_firstfreeblocknumber, |
sb | 119 | fs/ext/freelists.c | sb->s_blocksize))) |
sb | 123 | fs/ext/freelists.c | if (j < sb->u.ext_sb.s_firstdatazone || j > sb->u.ext_sb.s_nzones) { |
sb | 128 | fs/ext/freelists.c | sb->u.ext_sb.s_freeblockscount --; |
sb | 129 | fs/ext/freelists.c | sb->s_dirt = 1; |
sb | 131 | fs/ext/freelists.c | if (!(bh=getblk(sb->s_dev, j, sb->s_blocksize))) { |
sb | 142 | fs/ext/freelists.c | unlock_super (sb); |
sb | 146 | fs/ext/freelists.c | unsigned long ext_count_free_blocks(struct super_block *sb) |
sb | 153 | fs/ext/freelists.c | lock_super (sb); |
sb | 154 | fs/ext/freelists.c | if (!sb->u.ext_sb.s_firstfreeblock) |
sb | 157 | fs/ext/freelists.c | efb = (struct ext_free_block *) sb->u.ext_sb.s_firstfreeblock->b_data; |
sb | 161 | fs/ext/freelists.c | if (!(bh = bread (sb->s_dev, block, sb->s_blocksize))) { |
sb | 173 | fs/ext/freelists.c | sb->u.ext_sb.s_freeblockscount, count); |
sb | 174 | fs/ext/freelists.c | unlock_super (sb); |
sb | 177 | fs/ext/freelists.c | return sb->u.ext_sb.s_freeblockscount; |
sb | 241 | fs/ext/freelists.c | struct super_block * sb; |
sb | 249 | fs/ext/freelists.c | sb = dir->i_sb; |
sb | 250 | fs/ext/freelists.c | inode->i_sb = sb; |
sb | 251 | fs/ext/freelists.c | inode->i_flags = sb->s_flags; |
sb | 252 | fs/ext/freelists.c | if (!sb->u.ext_sb.s_firstfreeinodeblock) |
sb | 254 | fs/ext/freelists.c | lock_super (sb); |
sb | 255 | fs/ext/freelists.c | efi = ((struct ext_free_inode *) sb->u.ext_sb.s_firstfreeinodeblock->b_data) + |
sb | 256 | fs/ext/freelists.c | (sb->u.ext_sb.s_firstfreeinodenumber-1)%EXT_INODES_PER_BLOCK; |
sb | 259 | fs/ext/freelists.c | sb->u.ext_sb.s_firstfreeinodeblock->b_dirt = 1; |
sb | 264 | fs/ext/freelists.c | j = sb->u.ext_sb.s_firstfreeinodenumber; |
sb | 265 | fs/ext/freelists.c | if (efi->next > sb->u.ext_sb.s_ninodes) { |
sb | 269 | fs/ext/freelists.c | sb->u.ext_sb.s_firstfreeinodenumber = efi->next; |
sb | 271 | fs/ext/freelists.c | brelse (sb->u.ext_sb.s_firstfreeinodeblock); |
sb | 272 | fs/ext/freelists.c | if (!sb->u.ext_sb.s_firstfreeinodenumber) { |
sb | 273 | fs/ext/freelists.c | sb->u.ext_sb.s_firstfreeinodeblock = NULL; |
sb | 275 | fs/ext/freelists.c | if (!(sb->u.ext_sb.s_firstfreeinodeblock = |
sb | 276 | fs/ext/freelists.c | bread(sb->s_dev, block, sb->s_blocksize))) |
sb | 280 | fs/ext/freelists.c | sb->u.ext_sb.s_freeinodescount --; |
sb | 281 | fs/ext/freelists.c | sb->s_dirt = 1; |
sb | 284 | fs/ext/freelists.c | inode->i_dev = sb->s_dev; |
sb | 295 | fs/ext/freelists.c | unlock_super (sb); |
sb | 299 | fs/ext/freelists.c | unsigned long ext_count_free_inodes(struct super_block *sb) |
sb | 306 | fs/ext/freelists.c | lock_super (sb); |
sb | 307 | fs/ext/freelists.c | if (!sb->u.ext_sb.s_firstfreeinodeblock) |
sb | 310 | fs/ext/freelists.c | efi = ((struct ext_free_inode *) sb->u.ext_sb.s_firstfreeinodeblock->b_data) + |
sb | 311 | fs/ext/freelists.c | ((sb->u.ext_sb.s_firstfreeinodenumber-1)%EXT_INODES_PER_BLOCK); |
sb | 315 | fs/ext/freelists.c | if (ino < 1 || ino > sb->u.ext_sb.s_ninodes) { |
sb | 317 | fs/ext/freelists.c | (int) sb->u.ext_sb.s_firstfreeinodenumber,ino); |
sb | 321 | fs/ext/freelists.c | if (!(bh = bread (sb->s_dev, block, sb->s_blocksize))) { |
sb | 334 | fs/ext/freelists.c | sb->u.ext_sb.s_freeinodescount, count); |
sb | 335 | fs/ext/freelists.c | unlock_super (sb); |
sb | 338 | fs/ext/freelists.c | return sb->u.ext_sb.s_freeinodescount; |
sb | 33 | fs/ext/inode.c | void ext_put_super(struct super_block *sb) |
sb | 36 | fs/ext/inode.c | lock_super(sb); |
sb | 37 | fs/ext/inode.c | sb->s_dev = 0; |
sb | 38 | fs/ext/inode.c | if (sb->u.ext_sb.s_firstfreeinodeblock) |
sb | 39 | fs/ext/inode.c | brelse (sb->u.ext_sb.s_firstfreeinodeblock); |
sb | 40 | fs/ext/inode.c | if (sb->u.ext_sb.s_firstfreeblock) |
sb | 41 | fs/ext/inode.c | brelse (sb->u.ext_sb.s_firstfreeblock); |
sb | 42 | fs/ext/inode.c | unlock_super(sb); |
sb | 122 | fs/ext/inode.c | void ext_write_super (struct super_block *sb) |
sb | 127 | fs/ext/inode.c | if (!(bh = bread(sb->s_dev, 1, BLOCK_SIZE))) { |
sb | 132 | fs/ext/inode.c | es->s_firstfreeblock = sb->u.ext_sb.s_firstfreeblocknumber; |
sb | 133 | fs/ext/inode.c | es->s_freeblockscount = sb->u.ext_sb.s_freeblockscount; |
sb | 134 | fs/ext/inode.c | es->s_firstfreeinode = sb->u.ext_sb.s_firstfreeinodenumber; |
sb | 135 | fs/ext/inode.c | es->s_freeinodescount = sb->u.ext_sb.s_freeinodescount; |
sb | 138 | fs/ext/inode.c | sb->s_dirt = 0; |
sb | 141 | fs/ext/inode.c | void ext_statfs (struct super_block *sb, struct statfs *buf) |
sb | 147 | fs/ext/inode.c | put_fs_long(sb->u.ext_sb.s_nzones << sb->u.ext_sb.s_log_zone_size, |
sb | 149 | fs/ext/inode.c | tmp = ext_count_free_blocks(sb); |
sb | 152 | fs/ext/inode.c | put_fs_long(sb->u.ext_sb.s_ninodes, &buf->f_files); |
sb | 153 | fs/ext/inode.c | put_fs_long(ext_count_free_inodes(sb), &buf->f_ffree); |
sb | 77 | fs/ext2/balloc.c | static void read_block_bitmap (struct super_block * sb, |
sb | 86 | fs/ext2/balloc.c | group_desc = block_group / EXT2_DESC_PER_BLOCK(sb); |
sb | 87 | fs/ext2/balloc.c | desc = block_group % EXT2_DESC_PER_BLOCK(sb); |
sb | 88 | fs/ext2/balloc.c | if (!sb->u.ext2_sb.s_group_desc[group_desc]) { |
sb | 93 | fs/ext2/balloc.c | gdp = (struct ext2_group_desc *) sb->u.ext2_sb.s_group_desc[group_desc]->b_data; |
sb | 94 | fs/ext2/balloc.c | bh = bread (sb->s_dev, gdp[desc].bg_block_bitmap, sb->s_blocksize); |
sb | 100 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap_number[bitmap_nr] = block_group; |
sb | 101 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap[bitmap_nr] = bh; |
sb | 115 | fs/ext2/balloc.c | static int load_block_bitmap (struct super_block * sb, |
sb | 122 | fs/ext2/balloc.c | if (block_group >= sb->u.ext2_sb.s_groups_count) { |
sb | 124 | fs/ext2/balloc.c | block_group, sb->u.ext2_sb.s_groups_count); |
sb | 127 | fs/ext2/balloc.c | if (sb->u.ext2_sb.s_loaded_block_bitmaps > 0 && |
sb | 128 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap_number[0] == block_group) |
sb | 131 | fs/ext2/balloc.c | if (sb->u.ext2_sb.s_groups_count <= EXT2_MAX_GROUP_LOADED) { |
sb | 132 | fs/ext2/balloc.c | if (sb->u.ext2_sb.s_block_bitmap[block_group]) { |
sb | 133 | fs/ext2/balloc.c | if (sb->u.ext2_sb.s_block_bitmap_number[block_group] != block_group) |
sb | 138 | fs/ext2/balloc.c | read_block_bitmap (sb, block_group, block_group); |
sb | 143 | fs/ext2/balloc.c | for (i = 0; i < sb->u.ext2_sb.s_loaded_block_bitmaps && |
sb | 144 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap_number[i] != block_group; i++) |
sb | 146 | fs/ext2/balloc.c | if (i < sb->u.ext2_sb.s_loaded_block_bitmaps && |
sb | 147 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap_number[i] == block_group) { |
sb | 148 | fs/ext2/balloc.c | block_bitmap_number = sb->u.ext2_sb.s_block_bitmap_number[i]; |
sb | 149 | fs/ext2/balloc.c | block_bitmap = sb->u.ext2_sb.s_block_bitmap[i]; |
sb | 151 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap_number[j] = |
sb | 152 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap_number[j - 1]; |
sb | 153 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap[j] = |
sb | 154 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap[j - 1]; |
sb | 156 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap_number[0] = block_bitmap_number; |
sb | 157 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap[0] = block_bitmap; |
sb | 159 | fs/ext2/balloc.c | if (sb->u.ext2_sb.s_loaded_block_bitmaps < EXT2_MAX_GROUP_LOADED) |
sb | 160 | fs/ext2/balloc.c | sb->u.ext2_sb.s_loaded_block_bitmaps++; |
sb | 162 | fs/ext2/balloc.c | brelse (sb->u.ext2_sb.s_block_bitmap[EXT2_MAX_GROUP_LOADED - 1]); |
sb | 163 | fs/ext2/balloc.c | for (j = sb->u.ext2_sb.s_loaded_block_bitmaps - 1; j > 0; j--) { |
sb | 164 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap_number[j] = |
sb | 165 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap_number[j - 1]; |
sb | 166 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap[j] = |
sb | 167 | fs/ext2/balloc.c | sb->u.ext2_sb.s_block_bitmap[j - 1]; |
sb | 169 | fs/ext2/balloc.c | read_block_bitmap (sb, block_group, 0); |
sb | 174 | fs/ext2/balloc.c | void ext2_free_block (struct super_block * sb, unsigned long block) |
sb | 186 | fs/ext2/balloc.c | if (!sb) { |
sb | 190 | fs/ext2/balloc.c | lock_super (sb); |
sb | 191 | fs/ext2/balloc.c | if (block < sb->u.ext2_sb.s_first_data_block || |
sb | 192 | fs/ext2/balloc.c | block >= sb->u.ext2_sb.s_blocks_count) { |
sb | 194 | fs/ext2/balloc.c | unlock_super (sb); |
sb | 197 | fs/ext2/balloc.c | es = (struct ext2_super_block *) sb->u.ext2_sb.s_sbh->b_data; |
sb | 201 | fs/ext2/balloc.c | bh = get_hash_table (sb->s_dev, block, sb->s_blocksize); |
sb | 205 | fs/ext2/balloc.c | block_group = (block - sb->u.ext2_sb.s_first_data_block) / |
sb | 206 | fs/ext2/balloc.c | EXT2_BLOCKS_PER_GROUP(sb); |
sb | 207 | fs/ext2/balloc.c | bit = (block - sb->u.ext2_sb.s_first_data_block) % |
sb | 208 | fs/ext2/balloc.c | EXT2_BLOCKS_PER_GROUP(sb); |
sb | 209 | fs/ext2/balloc.c | bitmap_nr = load_block_bitmap (sb, block_group); |
sb | 210 | fs/ext2/balloc.c | bh = sb->u.ext2_sb.s_block_bitmap[bitmap_nr]; |
sb | 217 | fs/ext2/balloc.c | sb->s_dev, block); |
sb | 219 | fs/ext2/balloc.c | group_desc = block_group / EXT2_DESC_PER_BLOCK(sb); |
sb | 220 | fs/ext2/balloc.c | desc = block_group % EXT2_DESC_PER_BLOCK(sb); |
sb | 221 | fs/ext2/balloc.c | bh2 = sb->u.ext2_sb.s_group_desc[group_desc]; |
sb | 232 | fs/ext2/balloc.c | sb->u.ext2_sb.s_sbh->b_dirt = 1; |
sb | 233 | fs/ext2/balloc.c | sb->s_dirt = 1; |
sb | 234 | fs/ext2/balloc.c | unlock_super (sb); |
sb | 243 | fs/ext2/balloc.c | int ext2_new_block (struct super_block * sb, unsigned long block_group) |
sb | 253 | fs/ext2/balloc.c | if (!sb) { |
sb | 257 | fs/ext2/balloc.c | lock_super (sb); |
sb | 258 | fs/ext2/balloc.c | es = (struct ext2_super_block *) sb->u.ext2_sb.s_sbh->b_data; |
sb | 260 | fs/ext2/balloc.c | unlock_super (sb); |
sb | 268 | fs/ext2/balloc.c | for (i = 0; i < sb->u.ext2_sb.s_groups_count; i++) { |
sb | 270 | fs/ext2/balloc.c | if (!sb->u.ext2_sb.s_group_desc[group_desc]) |
sb | 272 | fs/ext2/balloc.c | gdp = (struct ext2_group_desc *) sb->u.ext2_sb.s_group_desc[group_desc]->b_data; |
sb | 277 | fs/ext2/balloc.c | if (desc == EXT2_DESC_PER_BLOCK(sb)) { |
sb | 283 | fs/ext2/balloc.c | if (i >= sb->u.ext2_sb.s_groups_count) { |
sb | 284 | fs/ext2/balloc.c | unlock_super (sb); |
sb | 291 | fs/ext2/balloc.c | bitmap_nr = load_block_bitmap (sb, i); |
sb | 292 | fs/ext2/balloc.c | bh = sb->u.ext2_sb.s_block_bitmap[bitmap_nr]; |
sb | 297 | fs/ext2/balloc.c | if ((j = find_first_zero (bh->b_data, EXT2_BLOCKS_PER_GROUP(sb))) < |
sb | 298 | fs/ext2/balloc.c | EXT2_BLOCKS_PER_GROUP(sb)) { |
sb | 309 | fs/ext2/balloc.c | j += i * EXT2_BLOCKS_PER_GROUP(sb) + |
sb | 310 | fs/ext2/balloc.c | sb->u.ext2_sb.s_first_data_block; |
sb | 311 | fs/ext2/balloc.c | if (j >= sb->u.ext2_sb.s_blocks_count) { |
sb | 316 | fs/ext2/balloc.c | if (!(bh = getblk (sb->s_dev, j, sb->s_blocksize))) { |
sb | 318 | fs/ext2/balloc.c | unlock_super (sb); |
sb | 321 | fs/ext2/balloc.c | clear_block (bh->b_data, sb->s_blocksize); |
sb | 329 | fs/ext2/balloc.c | sb->u.ext2_sb.s_group_desc[group_desc]->b_dirt = 1; |
sb | 331 | fs/ext2/balloc.c | sb->u.ext2_sb.s_sbh->b_dirt = 1; |
sb | 332 | fs/ext2/balloc.c | sb->s_dirt = 1; |
sb | 333 | fs/ext2/balloc.c | unlock_super (sb); |
sb | 337 | fs/ext2/balloc.c | unsigned long ext2_count_free_blocks (struct super_block *sb) |
sb | 348 | fs/ext2/balloc.c | lock_super (sb); |
sb | 349 | fs/ext2/balloc.c | es = (struct ext2_super_block *) sb->u.ext2_sb.s_sbh->b_data; |
sb | 355 | fs/ext2/balloc.c | for (i = 0; i < sb->u.ext2_sb.s_groups_count; i++) { |
sb | 357 | fs/ext2/balloc.c | if (!sb->u.ext2_sb.s_group_desc[group_desc]) { |
sb | 361 | fs/ext2/balloc.c | gdp = (struct ext2_group_desc *) sb->u.ext2_sb.s_group_desc[group_desc]->b_data; |
sb | 364 | fs/ext2/balloc.c | bitmap_nr = load_block_bitmap (sb, i); |
sb | 365 | fs/ext2/balloc.c | if (sb->u.ext2_sb.s_block_bitmap[bitmap_nr]) |
sb | 366 | fs/ext2/balloc.c | x = ext2_count_free (sb->u.ext2_sb.s_block_bitmap[bitmap_nr], |
sb | 367 | fs/ext2/balloc.c | sb->s_blocksize); |
sb | 376 | fs/ext2/balloc.c | if (desc == EXT2_DESC_PER_BLOCK(sb)) { |
sb | 384 | fs/ext2/balloc.c | unlock_super (sb); |
sb | 387 | fs/ext2/balloc.c | es = (struct ext2_super_block *) sb->u.ext2_sb.s_sbh->b_data; |
sb | 74 | fs/ext2/dir.c | struct super_block * sb; |
sb | 78 | fs/ext2/dir.c | sb = inode->i_sb; |
sb | 80 | fs/ext2/dir.c | offset = filp->f_pos & (sb->s_blocksize - 1); |
sb | 81 | fs/ext2/dir.c | bh = ext2_bread (inode, (filp->f_pos) >> EXT2_BLOCK_SIZE_BITS(sb), 0); |
sb | 83 | fs/ext2/dir.c | filp->f_pos += sb->s_blocksize - offset; |
sb | 87 | fs/ext2/dir.c | while (offset < sb->s_blocksize && filp->f_pos < inode->i_size) { |
sb | 81 | fs/ext2/file.c | struct super_block * sb; |
sb | 88 | fs/ext2/file.c | sb = inode->i_sb; |
sb | 104 | fs/ext2/file.c | block = offset >> EXT2_BLOCK_SIZE_BITS(sb); |
sb | 105 | fs/ext2/file.c | offset &= (sb->s_blocksize - 1); |
sb | 106 | fs/ext2/file.c | size = (size + sb->s_blocksize - 1) >> EXT2_BLOCK_SIZE_BITS(sb); |
sb | 107 | fs/ext2/file.c | blocks = (left + offset + sb->s_blocksize - 1) >> EXT2_BLOCK_SIZE_BITS(sb); |
sb | 160 | fs/ext2/file.c | if (left < sb->s_blocksize - offset) |
sb | 163 | fs/ext2/file.c | chars = sb->s_blocksize - offset; |
sb | 205 | fs/ext2/file.c | struct super_block * sb; |
sb | 211 | fs/ext2/file.c | sb = inode->i_sb; |
sb | 226 | fs/ext2/file.c | bh = ext2_getblk (inode, pos / sb->s_blocksize, 1); |
sb | 235 | fs/ext2/file.c | c = sb->s_blocksize - (pos % sb->s_blocksize); |
sb | 238 | fs/ext2/file.c | if (c != sb->s_blocksize && !bh->b_uptodate) { |
sb | 248 | fs/ext2/file.c | p = (pos % sb->s_blocksize) + bh->b_data; |
sb | 70 | fs/ext2/ialloc.c | static void read_inode_bitmap (struct super_block * sb, |
sb | 79 | fs/ext2/ialloc.c | group_desc = block_group / EXT2_DESC_PER_BLOCK(sb); |
sb | 80 | fs/ext2/ialloc.c | desc = block_group % EXT2_DESC_PER_BLOCK(sb); |
sb | 81 | fs/ext2/ialloc.c | if (!sb->u.ext2_sb.s_group_desc[group_desc]) { |
sb | 86 | fs/ext2/ialloc.c | gdp = (struct ext2_group_desc *) sb->u.ext2_sb.s_group_desc[group_desc]->b_data; |
sb | 87 | fs/ext2/ialloc.c | bh = bread (sb->s_dev, gdp[desc].bg_inode_bitmap, sb->s_blocksize); |
sb | 93 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap_number[bitmap_nr] = block_group; |
sb | 94 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap[bitmap_nr] = bh; |
sb | 108 | fs/ext2/ialloc.c | static int load_inode_bitmap (struct super_block * sb, |
sb | 115 | fs/ext2/ialloc.c | if (block_group >= sb->u.ext2_sb.s_groups_count) { |
sb | 117 | fs/ext2/ialloc.c | block_group, sb->u.ext2_sb.s_groups_count); |
sb | 120 | fs/ext2/ialloc.c | if (sb->u.ext2_sb.s_loaded_inode_bitmaps > 0 && |
sb | 121 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap_number[0] == block_group) |
sb | 123 | fs/ext2/ialloc.c | if (sb->u.ext2_sb.s_groups_count <= EXT2_MAX_GROUP_LOADED) { |
sb | 124 | fs/ext2/ialloc.c | if (sb->u.ext2_sb.s_inode_bitmap[block_group]) { |
sb | 125 | fs/ext2/ialloc.c | if (sb->u.ext2_sb.s_inode_bitmap_number[block_group] != block_group) |
sb | 130 | fs/ext2/ialloc.c | read_inode_bitmap (sb, block_group, block_group); |
sb | 135 | fs/ext2/ialloc.c | for (i = 0; i < sb->u.ext2_sb.s_loaded_inode_bitmaps && |
sb | 136 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap_number[i] != block_group; |
sb | 139 | fs/ext2/ialloc.c | if (i < sb->u.ext2_sb.s_loaded_inode_bitmaps && |
sb | 140 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap_number[i] == block_group) { |
sb | 141 | fs/ext2/ialloc.c | inode_bitmap_number = sb->u.ext2_sb.s_inode_bitmap_number[i]; |
sb | 142 | fs/ext2/ialloc.c | inode_bitmap = sb->u.ext2_sb.s_inode_bitmap[i]; |
sb | 144 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap_number[j] = |
sb | 145 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap_number[j - 1]; |
sb | 146 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap[j] = |
sb | 147 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap[j - 1]; |
sb | 149 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap_number[0] = inode_bitmap_number; |
sb | 150 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap[0] = inode_bitmap; |
sb | 152 | fs/ext2/ialloc.c | if (sb->u.ext2_sb.s_loaded_inode_bitmaps < EXT2_MAX_GROUP_LOADED) |
sb | 153 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_loaded_inode_bitmaps++; |
sb | 155 | fs/ext2/ialloc.c | brelse (sb->u.ext2_sb.s_inode_bitmap[EXT2_MAX_GROUP_LOADED - 1]); |
sb | 156 | fs/ext2/ialloc.c | for (j = sb->u.ext2_sb.s_loaded_inode_bitmaps - 1; j > 0; j--) { |
sb | 157 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap_number[j] = |
sb | 158 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap_number[j - 1]; |
sb | 159 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap[j] = |
sb | 160 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_inode_bitmap[j - 1]; |
sb | 162 | fs/ext2/ialloc.c | read_inode_bitmap (sb, block_group, 0); |
sb | 198 | fs/ext2/ialloc.c | struct super_block * sb; |
sb | 232 | fs/ext2/ialloc.c | sb = inode->i_sb; |
sb | 233 | fs/ext2/ialloc.c | lock_super (sb); |
sb | 234 | fs/ext2/ialloc.c | if (inode->i_ino < 1 || inode->i_ino > sb->u.ext2_sb.s_inodes_count) { |
sb | 236 | fs/ext2/ialloc.c | unlock_super (sb); |
sb | 239 | fs/ext2/ialloc.c | es = (struct ext2_super_block *) sb->u.ext2_sb.s_sbh->b_data; |
sb | 240 | fs/ext2/ialloc.c | block_group = (inode->i_ino - 1) / EXT2_INODES_PER_GROUP(sb); |
sb | 241 | fs/ext2/ialloc.c | bit = (inode->i_ino - 1) % EXT2_INODES_PER_GROUP(sb); |
sb | 242 | fs/ext2/ialloc.c | bitmap_nr = load_inode_bitmap (sb, block_group); |
sb | 243 | fs/ext2/ialloc.c | bh = sb->u.ext2_sb.s_inode_bitmap[bitmap_nr]; |
sb | 250 | fs/ext2/ialloc.c | sb->s_dev, inode->i_ino); |
sb | 252 | fs/ext2/ialloc.c | group_desc = block_group / EXT2_DESC_PER_BLOCK(sb); |
sb | 253 | fs/ext2/ialloc.c | desc = block_group % EXT2_DESC_PER_BLOCK(sb); |
sb | 254 | fs/ext2/ialloc.c | bh2 = sb->u.ext2_sb.s_group_desc[group_desc]; |
sb | 268 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_sbh->b_dirt = 1; |
sb | 269 | fs/ext2/ialloc.c | sb->s_dirt = 1; |
sb | 270 | fs/ext2/ialloc.c | unlock_super (sb); |
sb | 315 | fs/ext2/ialloc.c | struct super_block * sb; |
sb | 327 | fs/ext2/ialloc.c | sb = dir->i_sb; |
sb | 328 | fs/ext2/ialloc.c | inode->i_sb = sb; |
sb | 329 | fs/ext2/ialloc.c | inode->i_flags = sb->s_flags; |
sb | 330 | fs/ext2/ialloc.c | lock_super (sb); |
sb | 331 | fs/ext2/ialloc.c | es = (struct ext2_super_block *) sb->u.ext2_sb.s_sbh->b_data; |
sb | 336 | fs/ext2/ialloc.c | for (i = 0; i < sb->u.ext2_sb.s_groups_count; i++) { |
sb | 338 | fs/ext2/ialloc.c | if (!sb->u.ext2_sb.s_group_desc[group_desc]) |
sb | 340 | fs/ext2/ialloc.c | gdp = (struct ext2_group_desc *) sb->u.ext2_sb.s_group_desc[group_desc]->b_data; |
sb | 345 | fs/ext2/ialloc.c | if (desc == EXT2_DESC_PER_BLOCK(sb)) { |
sb | 351 | fs/ext2/ialloc.c | if (i >= sb->u.ext2_sb.s_groups_count) { |
sb | 352 | fs/ext2/ialloc.c | unlock_super (sb); |
sb | 355 | fs/ext2/ialloc.c | bitmap_nr = load_inode_bitmap (sb, i); |
sb | 356 | fs/ext2/ialloc.c | bh = sb->u.ext2_sb.s_inode_bitmap[bitmap_nr]; |
sb | 361 | fs/ext2/ialloc.c | if ((j = find_first_zero (bh->b_data, EXT2_INODES_PER_GROUP(sb))) < |
sb | 362 | fs/ext2/ialloc.c | EXT2_INODES_PER_GROUP(sb)) { |
sb | 370 | fs/ext2/ialloc.c | j += i * EXT2_INODES_PER_GROUP(sb) + 1; |
sb | 371 | fs/ext2/ialloc.c | if (j > sb->u.ext2_sb.s_inodes_count) { |
sb | 379 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_group_desc[group_desc]->b_dirt = 1; |
sb | 381 | fs/ext2/ialloc.c | sb->u.ext2_sb.s_sbh->b_dirt = 1; |
sb | 382 | fs/ext2/ialloc.c | sb->s_dirt = 1; |
sb | 383 | fs/ext2/ialloc.c | inode->i_sb = sb; |
sb | 386 | fs/ext2/ialloc.c | inode->i_dev = sb->s_dev; |
sb | 391 | fs/ext2/ialloc.c | inode->i_blksize = sb->s_blocksize; |
sb | 407 | fs/ext2/ialloc.c | unlock_super (sb); |
sb | 411 | fs/ext2/ialloc.c | unsigned long ext2_count_free_inodes (struct super_block *sb) |
sb | 422 | fs/ext2/ialloc.c | lock_super (sb); |
sb | 423 | fs/ext2/ialloc.c | es = (struct ext2_super_block *) sb->u.ext2_sb.s_sbh->b_data; |
sb | 429 | fs/ext2/ialloc.c | for (i = 0; i < sb->u.ext2_sb.s_groups_count; i++) { |
sb | 431 | fs/ext2/ialloc.c | if (!sb->u.ext2_sb.s_group_desc[group_desc]) { |
sb | 435 | fs/ext2/ialloc.c | gdp = (struct ext2_group_desc *) sb->u.ext2_sb.s_group_desc[group_desc]->b_data; |
sb | 438 | fs/ext2/ialloc.c | bitmap_nr = load_inode_bitmap (sb, i); |
sb | 439 | fs/ext2/ialloc.c | if (sb->u.ext2_sb.s_inode_bitmap[bitmap_nr]) |
sb | 440 | fs/ext2/ialloc.c | x = ext2_count_free (sb->u.ext2_sb.s_inode_bitmap[bitmap_nr], |
sb | 441 | fs/ext2/ialloc.c | EXT2_INODES_PER_GROUP(sb) / 8); |
sb | 451 | fs/ext2/ialloc.c | if (desc == EXT2_DESC_PER_BLOCK(sb)) { |
sb | 459 | fs/ext2/ialloc.c | unlock_super (sb); |
sb | 462 | fs/ext2/ialloc.c | es = (struct ext2_super_block *) sb->u.ext2_sb.s_sbh->b_data; |
sb | 34 | fs/ext2/inode.c | void ext2_put_super (struct super_block * sb) |
sb | 39 | fs/ext2/inode.c | lock_super (sb); |
sb | 40 | fs/ext2/inode.c | es = (struct ext2_super_block *) sb->u.ext2_sb.s_sbh->b_data; |
sb | 42 | fs/ext2/inode.c | sb->u.ext2_sb.s_sbh->b_dirt = 1; |
sb | 44 | fs/ext2/inode.c | ext2_dcache_invalidate (sb->s_dev); |
sb | 46 | fs/ext2/inode.c | sb->s_dev = 0; |
sb | 48 | fs/ext2/inode.c | if (sb->u.ext2_sb.s_group_desc[i]) |
sb | 49 | fs/ext2/inode.c | brelse (sb->u.ext2_sb.s_group_desc[i]); |
sb | 51 | fs/ext2/inode.c | if (sb->u.ext2_sb.s_inode_bitmap[i]) |
sb | 52 | fs/ext2/inode.c | brelse (sb->u.ext2_sb.s_inode_bitmap[i]); |
sb | 54 | fs/ext2/inode.c | if (sb->u.ext2_sb.s_block_bitmap[i]) |
sb | 55 | fs/ext2/inode.c | brelse (sb->u.ext2_sb.s_block_bitmap[i]); |
sb | 56 | fs/ext2/inode.c | unlock_super (sb); |
sb | 70 | fs/ext2/inode.c | static int convert_pre_02b_fs (struct super_block * sb, |
sb | 81 | fs/ext2/inode.c | bh2 = bread (sb->s_dev, 2, BLOCK_SIZE); |
sb | 87 | fs/ext2/inode.c | groups_count = (sb->u.ext2_sb.s_blocks_count - |
sb | 88 | fs/ext2/inode.c | sb->u.ext2_sb.s_first_data_block + |
sb | 89 | fs/ext2/inode.c | (EXT2_BLOCK_SIZE(sb) * 8) - 1) / |
sb | 90 | fs/ext2/inode.c | (EXT2_BLOCK_SIZE(sb) * 8); |
sb | 104 | fs/ext2/inode.c | sb->s_magic = EXT2_SUPER_MAGIC; |
sb | 265 | fs/ext2/inode.c | void ext2_write_super (struct super_block * sb) |
sb | 273 | fs/ext2/inode.c | if ((sb->s_flags & MS_RDONLY) == 0) { |
sb | 274 | fs/ext2/inode.c | es = (struct ext2_super_block *) sb->u.ext2_sb.s_sbh->b_data; |
sb | 280 | fs/ext2/inode.c | sb->u.ext2_sb.s_sbh->b_dirt = 1; |
sb | 281 | fs/ext2/inode.c | bh_count = (sb->u.ext2_sb.s_groups_count + |
sb | 282 | fs/ext2/inode.c | EXT2_DESC_PER_BLOCK(sb) - 1) / |
sb | 283 | fs/ext2/inode.c | EXT2_DESC_PER_BLOCK(sb); |
sb | 284 | fs/ext2/inode.c | for (i = 0; i < sb->u.ext2_sb.s_groups_count; i++) { |
sb | 285 | fs/ext2/inode.c | block = sb->u.ext2_sb.s_first_data_block + |
sb | 286 | fs/ext2/inode.c | i * sb->u.ext2_sb.s_blocks_per_group; |
sb | 287 | fs/ext2/inode.c | if (!(bh = bread (sb->s_dev, block, BLOCK_SIZE))) |
sb | 302 | fs/ext2/inode.c | if (!(bh = bread (sb->s_dev, block, sb->s_blocksize))) |
sb | 305 | fs/ext2/inode.c | memcpy (bh->b_data, sb->u.ext2_sb.s_group_desc[j]->b_data, sb->s_blocksize); |
sb | 312 | fs/ext2/inode.c | sb->s_dirt = 0; |
sb | 315 | fs/ext2/inode.c | void ext2_statfs (struct super_block * sb, struct statfs * buf) |
sb | 320 | fs/ext2/inode.c | put_fs_long (sb->s_blocksize, &buf->f_bsize); |
sb | 321 | fs/ext2/inode.c | put_fs_long (sb->u.ext2_sb.s_blocks_count << sb->u.ext2_sb.s_log_block_size, |
sb | 323 | fs/ext2/inode.c | tmp = ext2_count_free_blocks (sb); |
sb | 325 | fs/ext2/inode.c | put_fs_long (tmp - sb->u.ext2_sb.s_r_blocks_count, &buf->f_bavail); |
sb | 326 | fs/ext2/inode.c | put_fs_long (sb->u.ext2_sb.s_inodes_count, &buf->f_files); |
sb | 327 | fs/ext2/inode.c | put_fs_long (ext2_count_free_inodes(sb), &buf->f_ffree); |
sb | 77 | fs/ext2/namei.c | struct super_block * sb; |
sb | 82 | fs/ext2/namei.c | sb = dir->i_sb; |
sb | 98 | fs/ext2/namei.c | if ((char *)de >= sb->s_blocksize + bh->b_data) { |
sb | 101 | fs/ext2/namei.c | bh = ext2_bread (dir, offset >> EXT2_BLOCK_SIZE_BITS(sb), 0); |
sb | 188 | fs/ext2/namei.c | struct super_block * sb; |
sb | 193 | fs/ext2/namei.c | sb = dir->i_sb; |
sb | 210 | fs/ext2/namei.c | if ((char *)de >= sb->s_blocksize + bh->b_data) { |
sb | 213 | fs/ext2/namei.c | bh = ext2_bread (dir, offset >> EXT2_BLOCK_SIZE_BITS(sb), 0); |
sb | 218 | fs/ext2/namei.c | bh = ext2_bread (dir, offset >> EXT2_BLOCK_SIZE_BITS(sb), 1); |
sb | 223 | fs/ext2/namei.c | de->rec_len = sb->s_blocksize; |
sb | 224 | fs/ext2/namei.c | dir->i_size += sb->s_blocksize; |
sb | 451 | fs/ext2/namei.c | struct super_block * sb; |
sb | 453 | fs/ext2/namei.c | sb = inode->i_sb; |
sb | 471 | fs/ext2/namei.c | if ((void *) de >= (void *) (bh->b_data + sb->s_blocksize)) { |
sb | 473 | fs/ext2/namei.c | bh = ext2_bread (inode, offset >> EXT2_BLOCK_SIZE_BITS(sb), 1); |
sb | 475 | fs/ext2/namei.c | offset += sb->s_blocksize; |
sb | 290 | fs/inode.c | struct inode * iget(struct super_block * sb,int nr) |
sb | 294 | fs/inode.c | if (!sb) |
sb | 299 | fs/inode.c | if (inode->i_dev != sb->s_dev || inode->i_ino != nr) { |
sb | 304 | fs/inode.c | if (inode->i_dev != sb->s_dev || inode->i_ino != nr) { |
sb | 349 | fs/inode.c | inode->i_sb = sb; |
sb | 350 | fs/inode.c | inode->i_dev = sb->s_dev; |
sb | 352 | fs/inode.c | inode->i_flags = sb->s_flags; |
sb | 28 | fs/isofs/inode.c | void isofs_put_super(struct super_block *sb) |
sb | 30 | fs/isofs/inode.c | lock_super(sb); |
sb | 36 | fs/isofs/inode.c | sb->s_dev = 0; |
sb | 37 | fs/isofs/inode.c | unlock_super(sb); |
sb | 241 | fs/isofs/inode.c | void isofs_statfs (struct super_block *sb, struct statfs *buf) |
sb | 245 | fs/isofs/inode.c | put_fs_long(sb->u.isofs_sb.s_nzones, &buf->f_blocks); |
sb | 248 | fs/isofs/inode.c | put_fs_long(sb->u.isofs_sb.s_ninodes, &buf->f_files); |
sb | 67 | fs/minix/bitmap.c | void minix_free_block(struct super_block * sb, int block) |
sb | 72 | fs/minix/bitmap.c | if (!sb) { |
sb | 76 | fs/minix/bitmap.c | if (block < sb->u.minix_sb.s_firstdatazone || |
sb | 77 | fs/minix/bitmap.c | block >= sb->u.minix_sb.s_nzones) { |
sb | 81 | fs/minix/bitmap.c | bh = get_hash_table(sb->s_dev,block,BLOCK_SIZE); |
sb | 85 | fs/minix/bitmap.c | zone = block - sb->u.minix_sb.s_firstdatazone + 1; |
sb | 88 | fs/minix/bitmap.c | bh = sb->u.minix_sb.s_zmap[zone]; |
sb | 94 | fs/minix/bitmap.c | printk("free_block (%04x:%d): bit already cleared\n",sb->s_dev,block); |
sb | 99 | fs/minix/bitmap.c | int minix_new_block(struct super_block * sb) |
sb | 104 | fs/minix/bitmap.c | if (!sb) { |
sb | 111 | fs/minix/bitmap.c | if ((bh=sb->u.minix_sb.s_zmap[i]) != NULL) |
sb | 121 | fs/minix/bitmap.c | j += i*8192 + sb->u.minix_sb.s_firstdatazone-1; |
sb | 122 | fs/minix/bitmap.c | if (j < sb->u.minix_sb.s_firstdatazone || |
sb | 123 | fs/minix/bitmap.c | j >= sb->u.minix_sb.s_nzones) |
sb | 125 | fs/minix/bitmap.c | if (!(bh = getblk(sb->s_dev,j,BLOCK_SIZE))) { |
sb | 136 | fs/minix/bitmap.c | unsigned long minix_count_free_blocks(struct super_block *sb) |
sb | 138 | fs/minix/bitmap.c | return (sb->u.minix_sb.s_nzones - count_used(sb->u.minix_sb.s_zmap,sb->u.minix_sb.s_zmap_blocks,sb->u.minix_sb.s_nzones)) |
sb | 139 | fs/minix/bitmap.c | << sb->u.minix_sb.s_log_zone_size; |
sb | 180 | fs/minix/bitmap.c | struct super_block * sb; |
sb | 187 | fs/minix/bitmap.c | sb = dir->i_sb; |
sb | 188 | fs/minix/bitmap.c | inode->i_sb = sb; |
sb | 212 | fs/minix/bitmap.c | inode->i_dev = sb->s_dev; |
sb | 223 | fs/minix/bitmap.c | unsigned long minix_count_free_inodes(struct super_block *sb) |
sb | 225 | fs/minix/bitmap.c | return sb->u.minix_sb.s_ninodes - count_used(sb->u.minix_sb.s_imap,sb->u.minix_sb.s_imap_blocks,sb->u.minix_sb.s_ninodes); |
sb | 27 | fs/minix/inode.c | void minix_put_super(struct super_block *sb) |
sb | 31 | fs/minix/inode.c | lock_super(sb); |
sb | 32 | fs/minix/inode.c | sb->s_dev = 0; |
sb | 34 | fs/minix/inode.c | brelse(sb->u.minix_sb.s_imap[i]); |
sb | 36 | fs/minix/inode.c | brelse(sb->u.minix_sb.s_zmap[i]); |
sb | 37 | fs/minix/inode.c | unlock_super(sb); |
sb | 129 | fs/minix/inode.c | void minix_statfs(struct super_block *sb, struct statfs *buf) |
sb | 135 | fs/minix/inode.c | put_fs_long(sb->u.minix_sb.s_nzones << sb->u.minix_sb.s_log_zone_size, &buf->f_blocks); |
sb | 136 | fs/minix/inode.c | tmp = minix_count_free_blocks(sb); |
sb | 139 | fs/minix/inode.c | put_fs_long(sb->u.minix_sb.s_ninodes, &buf->f_files); |
sb | 140 | fs/minix/inode.c | put_fs_long(minix_count_free_inodes(sb), &buf->f_ffree); |
sb | 18 | fs/msdos/fat.c | int fat_access(struct super_block *sb,int this,int new_value) |
sb | 25 | fs/msdos/fat.c | if (MSDOS_SB(sb)->fat_bits == 16) first = last = this*2; |
sb | 30 | fs/msdos/fat.c | if (!(bh = msdos_sread(sb->s_dev,MSDOS_SB(sb)->fat_start+(first >> |
sb | 40 | fs/msdos/fat.c | if (!(bh2 = msdos_sread(sb->s_dev,MSDOS_SB(sb)->fat_start+(last |
sb | 47 | fs/msdos/fat.c | if (MSDOS_SB(sb)->fat_bits == 16) { |
sb | 62 | fs/msdos/fat.c | if (MSDOS_SB(sb)->fat_bits == 16) |
sb | 77 | fs/msdos/fat.c | for (copy = 1; copy < MSDOS_SB(sb)->fats; copy++) { |
sb | 78 | fs/msdos/fat.c | if (!(c_bh = msdos_sread(sb->s_dev,MSDOS_SB(sb)-> |
sb | 79 | fs/msdos/fat.c | fat_start+(first >> SECTOR_BITS)+MSDOS_SB(sb)-> |
sb | 84 | fs/msdos/fat.c | if (!(c_bh2 = msdos_sread(sb->s_dev, |
sb | 85 | fs/msdos/fat.c | MSDOS_SB(sb)->fat_start+(first >> |
sb | 86 | fs/msdos/fat.c | SECTOR_BITS)+MSDOS_SB(sb)->fat_length*copy |
sb | 239 | fs/msdos/fat.c | struct msdos_sb_info *sb; |
sb | 242 | fs/msdos/fat.c | sb = MSDOS_SB(inode->i_sb); |
sb | 245 | fs/msdos/fat.c | if (sector >= sb->dir_entries >> MSDOS_DPS_BITS) return 0; |
sb | 246 | fs/msdos/fat.c | return sector+sb->dir_start; |
sb | 248 | fs/msdos/fat.c | cluster = sector/sb->cluster_size; |
sb | 249 | fs/msdos/fat.c | offset = sector % sb->cluster_size; |
sb | 251 | fs/msdos/fat.c | return (cluster-2)*sb->cluster_size+sb->data_start+offset; |
sb | 41 | fs/msdos/inode.c | void msdos_put_super(struct super_block *sb) |
sb | 43 | fs/msdos/inode.c | cache_inval_dev(sb->s_dev); |
sb | 44 | fs/msdos/inode.c | lock_super(sb); |
sb | 45 | fs/msdos/inode.c | sb->s_dev = 0; |
sb | 46 | fs/msdos/inode.c | unlock_super(sb); |
sb | 192 | fs/msdos/inode.c | void msdos_statfs(struct super_block *sb,struct statfs *buf) |
sb | 196 | fs/msdos/inode.c | put_fs_long(sb->s_magic,&buf->f_type); |
sb | 197 | fs/msdos/inode.c | put_fs_long(MSDOS_SB(sb)->cluster_size*SECTOR_SIZE,&buf->f_bsize); |
sb | 198 | fs/msdos/inode.c | put_fs_long(MSDOS_SB(sb)->clusters,&buf->f_blocks); |
sb | 199 | fs/msdos/inode.c | lock_fat(sb); |
sb | 200 | fs/msdos/inode.c | if (MSDOS_SB(sb)->free_clusters != -1) |
sb | 201 | fs/msdos/inode.c | free = MSDOS_SB(sb)->free_clusters; |
sb | 204 | fs/msdos/inode.c | for (this = 2; this < MSDOS_SB(sb)->clusters+2; this++) |
sb | 205 | fs/msdos/inode.c | if (!fat_access(sb,this,-1)) free++; |
sb | 206 | fs/msdos/inode.c | MSDOS_SB(sb)->free_clusters = free; |
sb | 208 | fs/msdos/inode.c | unlock_fat(sb); |
sb | 218 | fs/msdos/inode.c | struct msdos_sb_info *sb; |
sb | 221 | fs/msdos/inode.c | sb = MSDOS_SB(inode->i_sb); |
sb | 222 | fs/msdos/inode.c | if ((sb->cluster_size & 1) || (sb->data_start & 1)) return 0; |
sb | 224 | fs/msdos/inode.c | if (sb->dir_start & 1) return 0; |
sb | 225 | fs/msdos/inode.c | return (sb->dir_start >> 1)+block; |
sb | 227 | fs/msdos/inode.c | cluster = (block*2)/sb->cluster_size; |
sb | 228 | fs/msdos/inode.c | offset = (block*2) % sb->cluster_size; |
sb | 230 | fs/msdos/inode.c | return ((cluster-2)*sb->cluster_size+sb->data_start+offset) >> 1; |
sb | 65 | fs/msdos/misc.c | void lock_fat(struct super_block *sb) |
sb | 67 | fs/msdos/misc.c | while (MSDOS_SB(sb)->fat_lock) sleep_on(&MSDOS_SB(sb)->fat_wait); |
sb | 68 | fs/msdos/misc.c | MSDOS_SB(sb)->fat_lock = 1; |
sb | 72 | fs/msdos/misc.c | void unlock_fat(struct super_block *sb) |
sb | 74 | fs/msdos/misc.c | MSDOS_SB(sb)->fat_lock = 0; |
sb | 75 | fs/msdos/misc.c | wake_up(&MSDOS_SB(sb)->fat_wait); |
sb | 312 | fs/msdos/misc.c | static int raw_found(struct super_block *sb,int sector,char *name,int *number, |
sb | 319 | fs/msdos/misc.c | if (!(bh = msdos_sread(sb->s_dev,sector,(void **) &data))) return -EIO; |
sb | 346 | fs/msdos/misc.c | static int raw_scan_root(struct super_block *sb,char *name,int *number,int *ino) |
sb | 350 | fs/msdos/misc.c | for (count = 0; count < MSDOS_SB(sb)->dir_entries/MSDOS_DPS; count++) { |
sb | 351 | fs/msdos/misc.c | if ((cluster = raw_found(sb,MSDOS_SB(sb)->dir_start+count,name, |
sb | 358 | fs/msdos/misc.c | static int raw_scan_nonroot(struct super_block *sb,int start,char *name, |
sb | 367 | fs/msdos/misc.c | for (count = 0; count < MSDOS_SB(sb)->cluster_size; count++) { |
sb | 368 | fs/msdos/misc.c | if ((cluster = raw_found(sb,(start-2)*MSDOS_SB(sb)-> |
sb | 369 | fs/msdos/misc.c | cluster_size+MSDOS_SB(sb)->data_start+count,name, |
sb | 372 | fs/msdos/misc.c | if (!(start = fat_access(sb,start,-1))) panic("FAT error"); |
sb | 382 | fs/msdos/misc.c | static int raw_scan(struct super_block *sb,int start,char *name,int number, |
sb | 385 | fs/msdos/misc.c | if (start) return raw_scan_nonroot(sb,start,name,&number,ino); |
sb | 386 | fs/msdos/misc.c | else return raw_scan_root(sb,name,&number,ino); |
sb | 224 | fs/msdos/namei.c | static void dump_fat(struct super_block *sb,int start) |
sb | 229 | fs/msdos/namei.c | start = fat_access(sb,start,-1); |
sb | 107 | fs/namei.c | struct super_block * sb; |
sb | 114 | fs/namei.c | } else if ((sb = dir->i_sb) && (dir == sb->s_mounted)) { |
sb | 115 | fs/namei.c | sb = dir->i_sb; |
sb | 117 | fs/namei.c | dir = sb->s_covered; |
sb | 37 | fs/nfs/inode.c | void nfs_put_super(struct super_block *sb) |
sb | 39 | fs/nfs/inode.c | close_fp(sb->u.nfs_sb.s_server.file); |
sb | 40 | fs/nfs/inode.c | lock_super(sb); |
sb | 41 | fs/nfs/inode.c | sb->s_dev = 0; |
sb | 42 | fs/nfs/inode.c | unlock_super(sb); |
sb | 53 | fs/nfs/inode.c | struct super_block *nfs_read_super(struct super_block *sb, void *raw_data) |
sb | 59 | fs/nfs/inode.c | dev_t dev = sb->s_dev; |
sb | 63 | fs/nfs/inode.c | sb->s_dev = 0; |
sb | 73 | fs/nfs/inode.c | sb->s_dev = 0; |
sb | 78 | fs/nfs/inode.c | sb->s_dev = 0; |
sb | 82 | fs/nfs/inode.c | lock_super(sb); |
sb | 83 | fs/nfs/inode.c | sb->s_blocksize = 1024; /* XXX */ |
sb | 84 | fs/nfs/inode.c | sb->s_magic = NFS_SUPER_MAGIC; |
sb | 85 | fs/nfs/inode.c | sb->s_dev = dev; |
sb | 86 | fs/nfs/inode.c | sb->s_op = &nfs_sops; |
sb | 87 | fs/nfs/inode.c | server = &sb->u.nfs_sb.s_server; |
sb | 109 | fs/nfs/inode.c | sb->u.nfs_sb.s_root = data->root; |
sb | 110 | fs/nfs/inode.c | unlock_super(sb); |
sb | 111 | fs/nfs/inode.c | if (!(sb->s_mounted = nfs_fhget(sb, &data->root, NULL))) { |
sb | 112 | fs/nfs/inode.c | sb->s_dev = 0; |
sb | 116 | fs/nfs/inode.c | return sb; |
sb | 119 | fs/nfs/inode.c | void nfs_statfs(struct super_block *sb, struct statfs *buf) |
sb | 125 | fs/nfs/inode.c | error = nfs_proc_statfs(&sb->u.nfs_sb.s_server, &sb->u.nfs_sb.s_root, |
sb | 148 | fs/nfs/inode.c | struct inode *nfs_fhget(struct super_block *sb, struct nfs_fh *fhandle, |
sb | 155 | fs/nfs/inode.c | if (!sb) { |
sb | 160 | fs/nfs/inode.c | error = nfs_proc_getattr(&sb->u.nfs_sb.s_server, fhandle, |
sb | 168 | fs/nfs/inode.c | if (!(inode = iget(sb, fattr->fileid))) { |
sb | 172 | fs/nfs/inode.c | if (inode->i_dev == sb->s_dev) { |
sb | 58 | fs/proc/fd.c | struct super_block * sb; |
sb | 68 | fs/proc/fd.c | sb = dir->i_sb; |
sb | 79 | fs/proc/fd.c | if (!(*result = iget(sb,(pid << 16)+2))) { |
sb | 116 | fs/proc/fd.c | if (!(*result = iget(sb,ino))) |
sb | 26 | fs/proc/inode.c | void proc_put_super(struct super_block *sb) |
sb | 28 | fs/proc/inode.c | lock_super(sb); |
sb | 29 | fs/proc/inode.c | sb->s_dev = 0; |
sb | 30 | fs/proc/inode.c | unlock_super(sb); |
sb | 58 | fs/proc/inode.c | void proc_statfs(struct super_block *sb, struct statfs *buf) |
sb | 49 | fs/super.c | void __wait_on_super(struct super_block * sb) |
sb | 53 | fs/super.c | add_wait_queue(&sb->s_wait, &wait); |
sb | 56 | fs/super.c | if (sb->s_lock) { |
sb | 60 | fs/super.c | remove_wait_queue(&sb->s_wait, &wait); |
sb | 66 | fs/super.c | struct super_block * sb; |
sb | 68 | fs/super.c | for (sb = super_block + 0 ; sb < super_block + NR_SUPER ; sb++) { |
sb | 69 | fs/super.c | if (!sb->s_dev) |
sb | 71 | fs/super.c | if (dev && sb->s_dev != dev) |
sb | 73 | fs/super.c | wait_on_super(sb); |
sb | 74 | fs/super.c | if (!sb->s_dev || !sb->s_dirt) |
sb | 76 | fs/super.c | if (dev && (dev != sb->s_dev)) |
sb | 78 | fs/super.c | if (sb->s_op && sb->s_op->write_super) |
sb | 79 | fs/super.c | sb->s_op->write_super(sb); |
sb | 103 | fs/super.c | struct super_block * sb; |
sb | 110 | fs/super.c | if (!(sb = get_super(dev))) |
sb | 112 | fs/super.c | if (sb->s_covered) { |
sb | 117 | fs/super.c | if (sb->s_op && sb->s_op->put_super) |
sb | 118 | fs/super.c | sb->s_op->put_super(sb); |
sb | 196 | fs/super.c | struct super_block * sb; |
sb | 200 | fs/super.c | if (!(sb=get_super(dev)) || !(sb->s_covered)) |
sb | 202 | fs/super.c | if (!sb->s_covered->i_mount) |
sb | 205 | fs/super.c | if (!fs_may_umount(dev, sb->s_mounted)) |
sb | 207 | fs/super.c | sb->s_covered->i_mount=0; |
sb | 208 | fs/super.c | iput(sb->s_covered); |
sb | 209 | fs/super.c | sb->s_covered = NULL; |
sb | 210 | fs/super.c | iput(sb->s_mounted); |
sb | 211 | fs/super.c | sb->s_mounted = NULL; |
sb | 212 | fs/super.c | if (sb->s_op && sb->s_op->write_super && sb->s_dirt) |
sb | 213 | fs/super.c | sb->s_op->write_super(sb); |
sb | 293 | fs/super.c | struct super_block * sb; |
sb | 311 | fs/super.c | sb = read_super(dev,type,flags,data); |
sb | 312 | fs/super.c | if (!sb || sb->s_covered) { |
sb | 316 | fs/super.c | sb->s_covered = dir_i; |
sb | 442 | fs/super.c | struct super_block * sb; |
sb | 455 | fs/super.c | sb = read_super(ROOT_DEV,fs_type->name,0,NULL); |
sb | 456 | fs/super.c | if (sb) { |
sb | 457 | fs/super.c | inode = sb->s_mounted; |
sb | 459 | fs/super.c | sb->s_covered = inode; |
sb | 460 | fs/super.c | sb->s_flags = 0; |
sb | 98 | fs/xiafs/bitmap.c | #define get_imap_zone(sb, bit_nr, not_que) \ |
sb | 99 | fs/xiafs/bitmap.c | get__map_zone((sb), (sb)->u.xiafs_sb.s_imap_buf, \ |
sb | 100 | fs/xiafs/bitmap.c | (sb)->u.xiafs_sb.s_imap_iznr, \ |
sb | 101 | fs/xiafs/bitmap.c | (sb)->u.xiafs_sb.s_imap_cached, 1, \ |
sb | 102 | fs/xiafs/bitmap.c | (sb)->u.xiafs_sb.s_imap_zones, _XIAFS_IMAP_SLOTS, \ |
sb | 105 | fs/xiafs/bitmap.c | #define get_zmap_zone(sb, bit_nr, not_que) \ |
sb | 106 | fs/xiafs/bitmap.c | get__map_zone((sb), (sb)->u.xiafs_sb.s_zmap_buf, \ |
sb | 107 | fs/xiafs/bitmap.c | (sb)->u.xiafs_sb.s_zmap_zznr, \ |
sb | 108 | fs/xiafs/bitmap.c | (sb)->u.xiafs_sb.s_zmap_cached, \ |
sb | 109 | fs/xiafs/bitmap.c | 1+(sb)->u.xiafs_sb.s_imap_zones, \ |
sb | 110 | fs/xiafs/bitmap.c | (sb)->u.xiafs_sb.s_zmap_zones, _XIAFS_ZMAP_SLOTS, \ |
sb | 114 | fs/xiafs/bitmap.c | get__map_zone(struct super_block *sb, struct buffer_head * bmap_buf[], |
sb | 121 | fs/xiafs/bitmap.c | z_nr = bit_nr >> XIAFS_BITS_PER_Z_BITS(sb); |
sb | 128 | fs/xiafs/bitmap.c | lock_super(sb); |
sb | 141 | fs/xiafs/bitmap.c | tmp_bh=bread(sb->s_dev, z_nr+first_zone, XIAFS_ZSIZE(sb)); /* cache not hit */ |
sb | 144 | fs/xiafs/bitmap.c | unlock_super(sb); |
sb | 157 | fs/xiafs/bitmap.c | #define xiafs_unlock_super(sb, cache) if (cache) unlock_super(sb); |
sb | 159 | fs/xiafs/bitmap.c | #define get_free_ibit(sb, prev_bit) \ |
sb | 160 | fs/xiafs/bitmap.c | get_free__bit(sb, sb->u.xiafs_sb.s_imap_buf, \ |
sb | 161 | fs/xiafs/bitmap.c | sb->u.xiafs_sb.s_imap_iznr, \ |
sb | 162 | fs/xiafs/bitmap.c | sb->u.xiafs_sb.s_imap_cached, \ |
sb | 163 | fs/xiafs/bitmap.c | 1, sb->u.xiafs_sb.s_imap_zones, \ |
sb | 166 | fs/xiafs/bitmap.c | #define get_free_zbit(sb, prev_bit) \ |
sb | 167 | fs/xiafs/bitmap.c | get_free__bit(sb, sb->u.xiafs_sb.s_zmap_buf, \ |
sb | 168 | fs/xiafs/bitmap.c | sb->u.xiafs_sb.s_zmap_zznr, \ |
sb | 169 | fs/xiafs/bitmap.c | sb->u.xiafs_sb.s_zmap_cached, \ |
sb | 170 | fs/xiafs/bitmap.c | 1 + sb->u.xiafs_sb.s_imap_zones, \ |
sb | 171 | fs/xiafs/bitmap.c | sb->u.xiafs_sb.s_zmap_zones, \ |
sb | 175 | fs/xiafs/bitmap.c | get_free__bit(struct super_block *sb, struct buffer_head * bmap_buf[], |
sb | 184 | fs/xiafs/bitmap.c | total_bits=bmap_zones << XIAFS_BITS_PER_Z_BITS(sb); |
sb | 188 | fs/xiafs/bitmap.c | end_bit=XIAFS_BITS_PER_Z(sb); |
sb | 202 | fs/xiafs/bitmap.c | bh = get__map_zone(sb, bmap_buf, bznr, cache, first_zone, |
sb | 209 | fs/xiafs/bitmap.c | xiafs_unlock_super(sb, sb->u.xiafs_sb.s_zmap_cached); |
sb | 217 | fs/xiafs/bitmap.c | xiafs_unlock_super(sb, cache); |
sb | 218 | fs/xiafs/bitmap.c | return (pos & ~(XIAFS_BITS_PER_Z(sb)-1))+tmp; |
sb | 221 | fs/xiafs/bitmap.c | void xiafs_free_zone(struct super_block * sb, int d_addr) |
sb | 226 | fs/xiafs/bitmap.c | if (!sb) { |
sb | 230 | fs/xiafs/bitmap.c | if (d_addr < sb->u.xiafs_sb.s_firstdatazone || |
sb | 231 | fs/xiafs/bitmap.c | d_addr >= sb->u.xiafs_sb.s_nzones) { |
sb | 235 | fs/xiafs/bitmap.c | bh = get_hash_table(sb->s_dev, d_addr, XIAFS_ZSIZE(sb)); |
sb | 239 | fs/xiafs/bitmap.c | bit=d_addr - sb->u.xiafs_sb.s_firstdatazone + 1; |
sb | 240 | fs/xiafs/bitmap.c | bh = get_zmap_zone(sb, bit, NULL); |
sb | 243 | fs/xiafs/bitmap.c | offset = bit & (XIAFS_BITS_PER_Z(sb) -1); |
sb | 247 | fs/xiafs/bitmap.c | xiafs_unlock_super(sb, sb->u.xiafs_sb.s_zmap_cached); |
sb | 250 | fs/xiafs/bitmap.c | int xiafs_new_zone(struct super_block * sb, u_long prev_addr) |
sb | 255 | fs/xiafs/bitmap.c | if (!sb) { |
sb | 259 | fs/xiafs/bitmap.c | if (prev_addr < sb->u.xiafs_sb.s_firstdatazone || |
sb | 260 | fs/xiafs/bitmap.c | prev_addr >= sb->u.xiafs_sb.s_nzones) { |
sb | 261 | fs/xiafs/bitmap.c | prev_addr=sb->u.xiafs_sb.s_firstdatazone; |
sb | 263 | fs/xiafs/bitmap.c | prev_znr=prev_addr-sb->u.xiafs_sb.s_firstdatazone+1; |
sb | 264 | fs/xiafs/bitmap.c | tmp=get_free_zbit(sb, prev_znr); |
sb | 267 | fs/xiafs/bitmap.c | tmp += sb->u.xiafs_sb.s_firstdatazone -1; |
sb | 268 | fs/xiafs/bitmap.c | if (!(bh = getblk(sb->s_dev, tmp, XIAFS_ZSIZE(sb)))) { |
sb | 309 | fs/xiafs/bitmap.c | struct super_block * sb; |
sb | 313 | fs/xiafs/bitmap.c | sb = dir->i_sb; |
sb | 316 | fs/xiafs/bitmap.c | inode->i_sb = sb; |
sb | 319 | fs/xiafs/bitmap.c | tmp=get_free_ibit(sb, dir->i_ino); |
sb | 326 | fs/xiafs/bitmap.c | inode->i_dev = sb->s_dev; |
sb | 352 | fs/xiafs/bitmap.c | unsigned long xiafs_count_free_inodes(struct super_block *sb) |
sb | 359 | fs/xiafs/bitmap.c | izones=sb->u.xiafs_sb.s_imap_zones; |
sb | 361 | fs/xiafs/bitmap.c | bh=get_imap_zone(sb, i << XIAFS_BITS_PER_Z_BITS(sb), ¬_que); |
sb | 364 | fs/xiafs/bitmap.c | xiafs_unlock_super(sb, sb->u.xiafs_sb.s_imap_cached); |
sb | 367 | fs/xiafs/bitmap.c | i=izones << XIAFS_BITS_PER_Z_BITS(sb); |
sb | 371 | fs/xiafs/bitmap.c | unsigned long xiafs_count_free_zones(struct super_block *sb) |
sb | 378 | fs/xiafs/bitmap.c | zzones=sb->u.xiafs_sb.s_zmap_zones; |
sb | 380 | fs/xiafs/bitmap.c | bh=get_zmap_zone(sb, i << XIAFS_BITS_PER_Z_BITS(sb), ¬_que); |
sb | 383 | fs/xiafs/bitmap.c | xiafs_unlock_super(sb, sb->u.xiafs_sb.s_zmap_cached); |
sb | 386 | fs/xiafs/bitmap.c | i=zzones << XIAFS_BITS_PER_Z_BITS(sb); |
sb | 35 | fs/xiafs/inode.c | void xiafs_put_super(struct super_block *sb) |
sb | 39 | fs/xiafs/inode.c | lock_super(sb); |
sb | 40 | fs/xiafs/inode.c | sb->s_dev = 0; |
sb | 42 | fs/xiafs/inode.c | brelse(sb->u.xiafs_sb.s_imap_buf[i]); |
sb | 44 | fs/xiafs/inode.c | brelse(sb->u.xiafs_sb.s_zmap_buf[i]); |
sb | 45 | fs/xiafs/inode.c | unlock_super(sb); |
sb | 141 | fs/xiafs/inode.c | void xiafs_statfs(struct super_block *sb, struct statfs *buf) |
sb | 146 | fs/xiafs/inode.c | put_fs_long(XIAFS_ZSIZE(sb), &buf->f_bsize); |
sb | 147 | fs/xiafs/inode.c | put_fs_long(sb->u.xiafs_sb.s_ndatazones, &buf->f_blocks); |
sb | 148 | fs/xiafs/inode.c | tmp = xiafs_count_free_zones(sb); |
sb | 151 | fs/xiafs/inode.c | put_fs_long(sb->u.xiafs_sb.s_ninodes, &buf->f_files); |
sb | 152 | fs/xiafs/inode.c | put_fs_long(xiafs_count_free_inodes(sb), &buf->f_ffree); |
sb | 79 | include/linux/ext_fs.h | extern unsigned long ext_count_free_inodes(struct super_block *sb); |
sb | 80 | include/linux/ext_fs.h | extern int ext_new_block(struct super_block * sb); |
sb | 81 | include/linux/ext_fs.h | extern void ext_free_block(struct super_block * sb, int block); |
sb | 82 | include/linux/ext_fs.h | extern unsigned long ext_count_free_blocks(struct super_block *sb); |
sb | 357 | include/linux/fs.h | extern struct inode * iget(struct super_block * sb,int nr); |
sb | 160 | include/linux/iso_fs.h | extern unsigned long isofs_count_free_inodes(struct super_block *sb); |
sb | 36 | include/linux/locks.h | extern inline void wait_on_super(struct super_block * sb) |
sb | 38 | include/linux/locks.h | if (sb->s_lock) |
sb | 39 | include/linux/locks.h | __wait_on_super(sb); |
sb | 42 | include/linux/locks.h | extern inline void lock_super(struct super_block * sb) |
sb | 44 | include/linux/locks.h | if (sb->s_lock) |
sb | 45 | include/linux/locks.h | __wait_on_super(sb); |
sb | 46 | include/linux/locks.h | sb->s_lock = 1; |
sb | 49 | include/linux/locks.h | extern inline void unlock_super(struct super_block * sb) |
sb | 51 | include/linux/locks.h | sb->s_lock = 0; |
sb | 52 | include/linux/locks.h | wake_up(&sb->s_wait); |
sb | 90 | include/linux/minix_fs.h | extern unsigned long minix_count_free_inodes(struct super_block *sb); |
sb | 91 | include/linux/minix_fs.h | extern int minix_new_block(struct super_block * sb); |
sb | 92 | include/linux/minix_fs.h | extern void minix_free_block(struct super_block * sb, int block); |
sb | 93 | include/linux/minix_fs.h | extern unsigned long minix_count_free_blocks(struct super_block *sb); |
sb | 106 | include/linux/msdos_fs.h | extern void lock_fat(struct super_block *sb); |
sb | 107 | include/linux/msdos_fs.h | extern void unlock_fat(struct super_block *sb); |
sb | 121 | include/linux/msdos_fs.h | extern int fat_access(struct super_block *sb,int this,int new_value); |
sb | 146 | include/linux/msdos_fs.h | extern void msdos_put_super(struct super_block *sb); |
sb | 148 | include/linux/msdos_fs.h | extern void msdos_statfs(struct super_block *sb,struct statfs *buf); |
sb | 101 | include/linux/nfs_fs.h | extern struct super_block *nfs_read_super(struct super_block *sb, void *data); |
sb | 102 | include/linux/nfs_fs.h | extern struct inode *nfs_fhget(struct super_block *sb, struct nfs_fh *fhandle, |
sb | 83 | include/linux/xia_fs.h | extern unsigned long xiafs_count_free_inodes(struct super_block *sb); |
sb | 84 | include/linux/xia_fs.h | extern int xiafs_new_zone(struct super_block * sb, u_long prev_addr); |
sb | 85 | include/linux/xia_fs.h | extern void xiafs_free_zone(struct super_block * sb, int block); |
sb | 86 | include/linux/xia_fs.h | extern unsigned long xiafs_count_free_zones(struct super_block *sb); |
sb | 92 | tools/build.c | struct stat sb; |
sb | 98 | tools/build.c | if (stat(argv[4], &sb)) { |
sb | 102 | tools/build.c | major_root = major(sb.st_rdev); |
sb | 103 | tools/build.c | minor_root = minor(sb.st_rdev); |
sb | 54 | zBoot/xtract.c | struct stat sb; |