Home
last modified time | relevance | path

Searched refs:block (Results 1 – 25 of 203) sorted by relevance

123456789

/fs/lockd/
Dsvclock.c42 static void nlmsvc_release_block(struct nlm_block *block);
43 static void nlmsvc_insert_block(struct nlm_block *block, unsigned long);
44 static void nlmsvc_remove_block(struct nlm_block *block);
59 nlmsvc_insert_block(struct nlm_block *block, unsigned long when) in nlmsvc_insert_block() argument
64 dprintk("lockd: nlmsvc_insert_block(%p, %ld)\n", block, when); in nlmsvc_insert_block()
65 if (list_empty(&block->b_list)) { in nlmsvc_insert_block()
66 kref_get(&block->b_count); in nlmsvc_insert_block()
68 list_del_init(&block->b_list); in nlmsvc_insert_block()
85 list_add_tail(&block->b_list, pos); in nlmsvc_insert_block()
86 block->b_when = when; in nlmsvc_insert_block()
[all …]
Dclntlock.c91 struct nlm_wait *block; in nlmclnt_prepare_block() local
93 block = kmalloc(sizeof(*block), GFP_KERNEL); in nlmclnt_prepare_block()
94 if (block != NULL) { in nlmclnt_prepare_block()
95 block->b_host = host; in nlmclnt_prepare_block()
96 block->b_lock = fl; in nlmclnt_prepare_block()
97 init_waitqueue_head(&block->b_wait); in nlmclnt_prepare_block()
98 block->b_status = nlm_lck_blocked; in nlmclnt_prepare_block()
99 list_add(&block->b_list, &nlm_blocked); in nlmclnt_prepare_block()
101 return block; in nlmclnt_prepare_block()
104 void nlmclnt_finish_block(struct nlm_wait *block) in nlmclnt_finish_block() argument
[all …]
/fs/minix/
Ditree_v2.c23 static int block_to_path(struct inode * inode, long block, int offsets[DEPTH]) in block_to_path() argument
29 if (block < 0) { in block_to_path()
31 block, bdevname(sb->s_bdev, b)); in block_to_path()
32 } else if (block >= (minix_sb(inode->i_sb)->s_max_size/sb->s_blocksize)) { in block_to_path()
36 block, bdevname(sb->s_bdev, b)); in block_to_path()
37 } else if (block < 7) { in block_to_path()
38 offsets[n++] = block; in block_to_path()
39 } else if ((block -= 7) < 256) { in block_to_path()
41 offsets[n++] = block; in block_to_path()
42 } else if ((block -= 256) < 256*256) { in block_to_path()
[all …]
Ditree_v1.c23 static int block_to_path(struct inode * inode, long block, int offsets[DEPTH]) in block_to_path() argument
28 if (block < 0) { in block_to_path()
30 block, bdevname(inode->i_sb->s_bdev, b)); in block_to_path()
31 } else if (block >= (minix_sb(inode->i_sb)->s_max_size/BLOCK_SIZE)) { in block_to_path()
35 block, bdevname(inode->i_sb->s_bdev, b)); in block_to_path()
36 } else if (block < 7) { in block_to_path()
37 offsets[n++] = block; in block_to_path()
38 } else if ((block -= 7) < 512) { in block_to_path()
40 offsets[n++] = block; in block_to_path()
42 block -= 512; in block_to_path()
[all …]
/fs/xfs/
Dxfs_dir2_block.c72 xfs_dir2_block_t *block; /* directory block structure */ in xfs_dir2_block_addname() local
109 block = bp->data; in xfs_dir2_block_addname()
113 if (unlikely(be32_to_cpu(block->hdr.magic) != XFS_DIR2_BLOCK_MAGIC)) { in xfs_dir2_block_addname()
115 XFS_ERRLEVEL_LOW, mp, block); in xfs_dir2_block_addname()
123 bf = block->hdr.bestfree; in xfs_dir2_block_addname()
124 btp = xfs_dir2_block_tail_p(mp, block); in xfs_dir2_block_addname()
137 enddup = (xfs_dir2_data_unused_t *)((char *)block + be16_to_cpu(*tagp)); in xfs_dir2_block_addname()
150 ((char *)block + be16_to_cpu(bf[0].offset)); in xfs_dir2_block_addname()
163 ((char *)block + in xfs_dir2_block_addname()
186 ((char *)block + be16_to_cpu(bf[0].offset)); in xfs_dir2_block_addname()
[all …]
Dxfs_btree.c59 struct xfs_btree_block *block, /* btree long form block pointer */ in xfs_btree_check_lblock() argument
68 be32_to_cpu(block->bb_magic) == xfs_magics[cur->bc_btnum] && in xfs_btree_check_lblock()
69 be16_to_cpu(block->bb_level) == level && in xfs_btree_check_lblock()
70 be16_to_cpu(block->bb_numrecs) <= in xfs_btree_check_lblock()
72 block->bb_u.l.bb_leftsib && in xfs_btree_check_lblock()
73 (be64_to_cpu(block->bb_u.l.bb_leftsib) == NULLDFSBNO || in xfs_btree_check_lblock()
75 be64_to_cpu(block->bb_u.l.bb_leftsib))) && in xfs_btree_check_lblock()
76 block->bb_u.l.bb_rightsib && in xfs_btree_check_lblock()
77 (be64_to_cpu(block->bb_u.l.bb_rightsib) == NULLDFSBNO || in xfs_btree_check_lblock()
79 be64_to_cpu(block->bb_u.l.bb_rightsib))); in xfs_btree_check_lblock()
[all …]
Dxfs_bmap_btree.h152 #define XFS_BMBT_REC_ADDR(mp, block, index) \ argument
154 ((char *)(block) + \
158 #define XFS_BMBT_KEY_ADDR(mp, block, index) \ argument
160 ((char *)(block) + \
164 #define XFS_BMBT_PTR_ADDR(mp, block, index, maxrecs) \ argument
166 ((char *)(block) + \
171 #define XFS_BMDR_REC_ADDR(block, index) \ argument
173 ((char *)(block) + \
177 #define XFS_BMDR_KEY_ADDR(block, index) \ argument
179 ((char *)(block) + \
[all …]
/fs/sysv/
Dballoc.c48 unsigned block = fs32_to_cpu(sbi, nr); in sysv_free_block() local
58 if (block < sbi->s_firstdatazone || block >= sbi->s_nzones) { in sysv_free_block()
76 block += sbi->s_block_base; in sysv_free_block()
77 bh = sb_getblk(sb, block); in sysv_free_block()
102 unsigned int block; in sysv_new_block() local
116 block = fs32_to_cpu(sbi, nr); in sysv_new_block()
120 if (block < sbi->s_firstdatazone || block >= sbi->s_nzones) { in sysv_new_block()
122 block); in sysv_new_block()
129 block += sbi->s_block_base; in sysv_new_block()
130 if (!(bh = sb_bread(sb, block))) { in sysv_new_block()
[all …]
Ditree.c22 static int block_to_path(struct inode *inode, long block, int offsets[DEPTH]) in block_to_path() argument
31 if (block < 0) { in block_to_path()
33 } else if (block < DIRECT) { in block_to_path()
34 offsets[n++] = block; in block_to_path()
35 } else if ( (block -= DIRECT) < indirect_blocks) { in block_to_path()
37 offsets[n++] = block; in block_to_path()
38 } else if ((block -= indirect_blocks) < double_blocks) { in block_to_path()
40 offsets[n++] = block >> ptrs_bits; in block_to_path()
41 offsets[n++] = block & (indirect_blocks - 1); in block_to_path()
42 } else if (((block -= double_blocks) >> (ptrs_bits * 2)) < indirect_blocks) { in block_to_path()
[all …]
/fs/udf/
Dpartition.c30 uint32_t udf_get_pblock(struct super_block *sb, uint32_t block, in udf_get_pblock() argument
37 "invalid partition\n", block, partition, offset); in udf_get_pblock()
42 return map->s_partition_func(sb, block, partition, offset); in udf_get_pblock()
44 return map->s_partition_root + block + offset; in udf_get_pblock()
47 uint32_t udf_get_pblock_virt15(struct super_block *sb, uint32_t block, in udf_get_pblock_virt15() argument
62 if (block > vdata->s_num_entries) { in udf_get_pblock_virt15()
64 "(%d max %d)\n", block, vdata->s_num_entries); in udf_get_pblock_virt15()
70 vdata->s_start_offset))[block]); in udf_get_pblock_virt15()
74 if (block >= index) { in udf_get_pblock_virt15()
75 block -= index; in udf_get_pblock_virt15()
[all …]
Dmisc.c32 struct buffer_head *udf_tgetblk(struct super_block *sb, int block) in udf_tgetblk() argument
35 return sb_getblk(sb, udf_fixed_to_variable(block)); in udf_tgetblk()
37 return sb_getblk(sb, block); in udf_tgetblk()
40 struct buffer_head *udf_tread(struct super_block *sb, int block) in udf_tread() argument
43 return sb_bread(sb, udf_fixed_to_variable(block)); in udf_tread()
45 return sb_bread(sb, block); in udf_tread()
202 struct buffer_head *udf_read_tagged(struct super_block *sb, uint32_t block, in udf_read_tagged() argument
209 if (block == 0xFFFFFFFF) in udf_read_tagged()
212 bh = udf_tread(sb, block); in udf_read_tagged()
215 block, location); in udf_read_tagged()
[all …]
/fs/affs/
Daffs.h149 extern void affs_free_block(struct super_block *sb, u32 block);
211 affs_bread(struct super_block *sb, int block) in affs_bread() argument
213 pr_debug("affs_bread: %d\n", block); in affs_bread()
214 if (block >= AFFS_SB(sb)->s_reserved && block < AFFS_SB(sb)->s_partition_size) in affs_bread()
215 return sb_bread(sb, block); in affs_bread()
219 affs_getblk(struct super_block *sb, int block) in affs_getblk() argument
221 pr_debug("affs_getblk: %d\n", block); in affs_getblk()
222 if (block >= AFFS_SB(sb)->s_reserved && block < AFFS_SB(sb)->s_partition_size) in affs_getblk()
223 return sb_getblk(sb, block); in affs_getblk()
227 affs_getzeroblk(struct super_block *sb, int block) in affs_getzeroblk() argument
[all …]
/fs/efs/
Ddir.c29 efs_block_t block; in efs_readdir() local
39 block = filp->f_pos >> EFS_DIRBSIZE_BITS; in efs_readdir()
45 while (block < inode->i_blocks) { in efs_readdir()
47 bh = sb_bread(inode->i_sb, efs_bmap(inode, block)); in efs_readdir()
50 printk(KERN_ERR "EFS: readdir(): failed to read dir block %d\n", block); in efs_readdir()
75 …FS: readdir(): block %d slot %d/%d: inode %u, name \"%s\", namelen %u\n", block, slot, dirblock->s… in efs_readdir()
79 filp->f_pos = (block << EFS_DIRBSIZE_BITS) | slot; in efs_readdir()
94 block++; in efs_readdir()
97 filp->f_pos = (block << EFS_DIRBSIZE_BITS) | slot; in efs_readdir()
105 block++; in efs_readdir()
[all …]
Dinode.c20 static sector_t _efs_bmap(struct address_space *mapping, sector_t block) in _efs_bmap() argument
22 return generic_block_bmap(mapping,block,efs_get_block); in _efs_bmap()
56 efs_block_t block, offset; in efs_iget() local
83 block = sb->fs_start + sb->first_block + in efs_iget()
91 bh = sb_bread(inode->i_sb, block); in efs_iget()
93 printk(KERN_WARNING "EFS: bread() failed at block %d\n", block); in efs_iget()
181 efs_extent_check(efs_extent *ptr, efs_block_t block, struct efs_sb_info *sb) { in efs_extent_check() argument
194 if ((block >= offset) && (block < offset+length)) { in efs_extent_check()
195 return(sb->fs_start + start + block - offset); in efs_extent_check()
201 efs_block_t efs_map_block(struct inode *inode, efs_block_t block) { in efs_map_block() argument
[all …]
Dfile.c26 block, in efs_get_block()
38 int efs_bmap(struct inode *inode, efs_block_t block) { in efs_bmap() argument
40 if (block < 0) { in efs_bmap()
46 if (!(block < inode->i_blocks)) { in efs_bmap()
52 block, in efs_bmap()
59 return efs_map_block(inode, block); in efs_bmap()
/fs/ocfs2/
Duptodate.c166 sector_t block) in ocfs2_search_cache_tree() argument
174 if (block < item->c_block) in ocfs2_search_cache_tree()
176 else if (block > item->c_block) in ocfs2_search_cache_tree()
248 sector_t block) in ocfs2_append_cache_array() argument
252 mlog(0, "block %llu takes position %u\n", (unsigned long long) block, in ocfs2_append_cache_array()
255 ci->ci_cache.ci_array[ci->ci_num_cached] = block; in ocfs2_append_cache_array()
265 sector_t block = new->c_block; in __ocfs2_insert_cache_tree() local
270 mlog(0, "Insert block %llu num = %u\n", (unsigned long long) block, in __ocfs2_insert_cache_tree()
278 if (block < tmp->c_block) in __ocfs2_insert_cache_tree()
280 else if (block > tmp->c_block) in __ocfs2_insert_cache_tree()
[all …]
/fs/befs/
Dio.c30 befs_blocknr_t block = 0; in befs_bread_iaddr() local
43 block = iaddr2blockno(sb, &iaddr); in befs_bread_iaddr()
45 befs_debug(sb, "befs_read_iaddr: offset = %lu", block); in befs_bread_iaddr()
47 bh = sb_bread(sb, block); in befs_bread_iaddr()
50 befs_error(sb, "Failed to read block %lu", block); in befs_bread_iaddr()
63 befs_bread(struct super_block *sb, befs_blocknr_t block) in befs_bread() argument
67 befs_debug(sb, "---> Enter befs_read() %Lu", block); in befs_bread()
69 bh = sb_bread(sb, block); in befs_bread()
72 befs_error(sb, "Failed to read block %lu", block); in befs_bread()
/fs/qnx4/
Dbitmap.c89 int qnx4_is_free(struct super_block *sb, long block) in qnx4_is_free() argument
97 start += block / (QNX4_BLOCK_SIZE * 8); in qnx4_is_free()
99 (unsigned long) block, (unsigned long) start)); in qnx4_is_free()
105 g = bh->b_data + (block % QNX4_BLOCK_SIZE); in qnx4_is_free()
106 if (((*g) & (1 << (block % 8))) == 0) { in qnx4_is_free()
118 int qnx4_set_bitmap(struct super_block *sb, long block, int busy) in qnx4_set_bitmap() argument
125 start += block / (QNX4_BLOCK_SIZE * 8); in qnx4_set_bitmap()
127 (unsigned long) block, (unsigned long) start)); in qnx4_set_bitmap()
133 g = bh->b_data + (block % QNX4_BLOCK_SIZE); in qnx4_set_bitmap()
135 (*g) &= ~(1 << (block % 8)); in qnx4_set_bitmap()
[all …]
/fs/ufs/
Dutil.h473 #define ubh_isblockclear(ubh,begin,block) (!_ubh_isblockset_(uspi,ubh,begin,block)) argument
475 #define ubh_isblockset(ubh,begin,block) _ubh_isblockset_(uspi,ubh,begin,block) argument
477 struct ufs_buffer_head * ubh, unsigned begin, unsigned block) in _ubh_isblockset_() argument
481 return (*ubh_get_addr (ubh, begin + block) == 0xff); in _ubh_isblockset_()
483 return (*ubh_get_addr (ubh, begin + (block >> 1)) == (0x0f << ((block & 0x01) << 2))); in _ubh_isblockset_()
485 return (*ubh_get_addr (ubh, begin + (block >> 2)) == (0x03 << ((block & 0x03) << 1))); in _ubh_isblockset_()
487 return (*ubh_get_addr (ubh, begin + (block >> 3)) == (0x01 << (block & 0x07))); in _ubh_isblockset_()
492 #define ubh_clrblock(ubh,begin,block) _ubh_clrblock_(uspi,ubh,begin,block) argument
494 struct ufs_buffer_head * ubh, unsigned begin, unsigned block) in _ubh_clrblock_() argument
498 *ubh_get_addr (ubh, begin + block) = 0x00; in _ubh_clrblock_()
[all …]
/fs/squashfs/
Dinode.c111 u64 block = SQUASHFS_INODE_BLK(ino) + msblk->inode_table; in squashfs_read_inode() local
121 err = squashfs_read_metadata(sb, sqshb_ino, &block, in squashfs_read_inode()
130 block = SQUASHFS_INODE_BLK(ino) + msblk->inode_table; in squashfs_read_inode()
141 err = squashfs_read_metadata(sb, sqsh_ino, &block, &offset, in squashfs_read_inode()
169 squashfs_i(inode)->block_list_start = block; in squashfs_read_inode()
175 offset, squashfs_i(inode)->start, block, offset); in squashfs_read_inode()
184 err = squashfs_read_metadata(sb, sqsh_ino, &block, &offset, in squashfs_read_inode()
214 squashfs_i(inode)->block_list_start = block; in squashfs_read_inode()
220 offset, squashfs_i(inode)->start, block, offset); in squashfs_read_inode()
226 err = squashfs_read_metadata(sb, sqsh_ino, &block, &offset, in squashfs_read_inode()
[all …]
Dcache.c67 struct squashfs_cache *cache, u64 block, int length) in squashfs_cache_get() argument
76 if (cache->entry[i].block == block) in squashfs_cache_get()
113 entry->block = block; in squashfs_cache_get()
121 block, length, &entry->next_index, in squashfs_cache_get()
172 cache->name, i, entry->block, entry->refcount, entry->error); in squashfs_cache_get()
176 block); in squashfs_cache_get()
265 entry->block = SQUASHFS_INVALID_BLK; in squashfs_cache_init()
333 u64 *block, int *offset, int length) in squashfs_read_metadata() argument
339 TRACE("Entered squashfs_read_metadata [%llx:%x]\n", *block, *offset); in squashfs_read_metadata()
342 entry = squashfs_cache_get(sb, msblk->block_cache, *block, 0); in squashfs_read_metadata()
[all …]
/fs/freevxfs/
Dvxfs_lookup.c115 u_long npages, page, nblocks, pblocks, block; in vxfs_find_entry() local
133 for (block = 0; block <= nblocks && block <= pblocks; block++) { in vxfs_find_entry()
138 baddr = kaddr + (block * bsize); in vxfs_find_entry()
246 u_long page, npages, block, pblocks, nblocks, offset; in vxfs_readdir() local
277 block = (u_long)(pos >> sbp->s_blocksize_bits) % pblocks; in vxfs_readdir()
279 for (; page < npages; page++, block = 0) { in vxfs_readdir()
288 for (; block <= nblocks && block <= pblocks; block++) { in vxfs_readdir()
293 baddr = kaddr + (block * bsize); in vxfs_readdir()
/fs/hfs/
Dextent.c21 static void hfs_ext_build_key(hfs_btree_key *key, u32 cnid, u16 block, u8 type) in hfs_ext_build_key() argument
26 key->ext.FABN = cpu_to_be16(block); in hfs_ext_build_key()
82 return be16_to_cpu(ext->block) + off; in hfs_ext_find_block()
107 return be16_to_cpu(ext->block) + be16_to_cpu(ext->count); in hfs_ext_lastblock()
142 u32 cnid, u32 block, u8 type) in __hfs_ext_read_extent() argument
146 hfs_ext_build_key(fd->search_key, cnid, block, type); in __hfs_ext_read_extent()
160 static inline int __hfs_ext_cache_extent(struct hfs_find_data *fd, struct inode *inode, u32 block) in __hfs_ext_cache_extent() argument
168 block, HFS_IS_RSRC(inode) ? HFS_FK_RSRC : HFS_FK_DATA); in __hfs_ext_cache_extent()
179 static int hfs_ext_read_extent(struct inode *inode, u16 block) in hfs_ext_read_extent() argument
184 if (block >= HFS_I(inode)->cached_start && in hfs_ext_read_extent()
[all …]
/fs/isofs/
Dnamei.c56 unsigned long block, f_pos, offset, block_saved, offset_saved; in isofs_find_entry() local
65 block = 0; in isofs_find_entry()
73 bh = isofs_bread(dir, block); in isofs_find_entry()
85 block = f_pos >> bufbits; in isofs_find_entry()
100 block++; in isofs_find_entry()
104 bh = isofs_bread(dir, block); in isofs_find_entry()
117 " in block %lu of inode %lu\n", block, in isofs_find_entry()
168 unsigned long uninitialized_var(block); in isofs_lookup()
181 &block, &offset, in isofs_lookup()
188 inode = isofs_iget(dir->i_sb, block, offset); in isofs_lookup()
/fs/bfs/
Dfile.c66 static int bfs_get_block(struct inode *inode, sector_t block, in bfs_get_block() argument
76 phys = bi->i_sblock + block; in bfs_get_block()
80 create, (unsigned long)block, phys); in bfs_get_block()
92 create, (unsigned long)block, phys); in bfs_get_block()
111 create, (unsigned long)block, phys); in bfs_get_block()
123 if (phys + block >= info->si_blocks) { in bfs_get_block()
140 create, (unsigned long)block, phys); in bfs_get_block()
142 phys += block; in bfs_get_block()
177 static sector_t bfs_bmap(struct address_space *mapping, sector_t block) in bfs_bmap() argument
179 return generic_block_bmap(mapping, block, bfs_get_block); in bfs_bmap()

123456789