Home
last modified time | relevance | path

Searched refs:ptr (Results 1 – 25 of 85) sorted by relevance

1234

/fs/xfs/linux-2.6/
Dkmem.c35 void *ptr; in kmem_alloc() local
47 ptr = kmalloc(size, lflags); in kmem_alloc()
49 ptr = __vmalloc(size, lflags, PAGE_KERNEL); in kmem_alloc()
50 if (ptr || (flags & (KM_MAYFAIL|KM_NOSLEEP))) in kmem_alloc()
51 return ptr; in kmem_alloc()
63 void *ptr; in kmem_zalloc() local
65 ptr = kmem_alloc(size, flags); in kmem_zalloc()
66 if (ptr) in kmem_zalloc()
67 memset((char *)ptr, 0, (int)size); in kmem_zalloc()
68 return ptr; in kmem_zalloc()
[all …]
/fs/xfs/
Dxfs_btree.c188 union xfs_btree_ptr *ptr, /* btree block disk address */ in xfs_btree_check_ptr() argument
194 be64_to_cpu((&ptr->l)[index]), level); in xfs_btree_check_ptr()
197 be32_to_cpu((&ptr->s)[index]), level); in xfs_btree_check_ptr()
843 union xfs_btree_ptr *ptr) in xfs_btree_ptr_is_null() argument
846 return be64_to_cpu(ptr->l) == NULLDFSBNO; in xfs_btree_ptr_is_null()
848 return be32_to_cpu(ptr->s) == NULLAGBLOCK; in xfs_btree_ptr_is_null()
854 union xfs_btree_ptr *ptr) in xfs_btree_set_ptr_null() argument
857 ptr->l = cpu_to_be64(NULLDFSBNO); in xfs_btree_set_ptr_null()
859 ptr->s = cpu_to_be32(NULLAGBLOCK); in xfs_btree_set_ptr_null()
869 union xfs_btree_ptr *ptr, in xfs_btree_get_sibling() argument
[all …]
Dxfs_btree_trace.c31 union xfs_btree_ptr ptr, in xfs_btree_trace_ptr() argument
36 __u64 val = be64_to_cpu(ptr.l); in xfs_btree_trace_ptr()
41 *low = be32_to_cpu(ptr.s); in xfs_btree_trace_ptr()
122 union xfs_btree_ptr ptr, in xfs_btree_trace_argipk() argument
129 xfs_btree_trace_ptr(cur, ptr, &high, &low); in xfs_btree_trace_argipk()
146 union xfs_btree_ptr ptr, in xfs_btree_trace_argipr() argument
153 xfs_btree_trace_ptr(cur, ptr, &high, &low); in xfs_btree_trace_argipr()
Dxfs_alloc_btree.c56 union xfs_btree_ptr *ptr, in xfs_allocbt_set_root() argument
64 ASSERT(ptr->s != 0); in xfs_allocbt_set_root()
66 agf->agf_roots[btnum] = ptr->s; in xfs_allocbt_set_root()
147 int ptr, in xfs_allocbt_update_lastrec() argument
163 if (ptr != xfs_btree_get_numrecs(block)) in xfs_allocbt_update_lastrec()
175 if (ptr <= numrecs) in xfs_allocbt_update_lastrec()
177 ASSERT(ptr == numrecs + 1); in xfs_allocbt_update_lastrec()
251 union xfs_btree_ptr *ptr) in xfs_allocbt_init_ptr_from_cur() argument
258 ptr->s = agf->agf_roots[cur->bc_btnum]; in xfs_allocbt_init_ptr_from_cur()
/fs/btrfs/
Dinode-item.c28 unsigned long ptr; in find_name_in_backref() local
36 ptr = btrfs_item_ptr_offset(leaf, path->slots[0]); in find_name_in_backref()
38 ref = (struct btrfs_inode_ref *)(ptr + cur_offset); in find_name_in_backref()
61 unsigned long ptr; in btrfs_del_inode_ref() local
97 ptr = (unsigned long)ref; in btrfs_del_inode_ref()
100 memmove_extent_buffer(leaf, ptr, ptr + sub_item_len, in btrfs_del_inode_ref()
101 item_size - (ptr + sub_item_len - item_start)); in btrfs_del_inode_ref()
118 unsigned long ptr; in btrfs_insert_inode_ref() local
146 ptr = (unsigned long)(ref + 1); in btrfs_insert_inode_ref()
155 ptr = (unsigned long)(ref + 1); in btrfs_insert_inode_ref()
[all …]
Dctree.h996 #define read_eb_member(eb, ptr, type, member, result) ( \ argument
998 ((unsigned long)(ptr)) + \
1002 #define write_eb_member(eb, ptr, type, member, result) ( \ argument
1004 ((unsigned long)(ptr)) + \
1196 unsigned long ptr = (unsigned long)inode_item; in btrfs_inode_atime() local
1197 ptr += offsetof(struct btrfs_inode_item, atime); in btrfs_inode_atime()
1198 return (struct btrfs_timespec *)ptr; in btrfs_inode_atime()
1204 unsigned long ptr = (unsigned long)inode_item; in btrfs_inode_mtime() local
1205 ptr += offsetof(struct btrfs_inode_item, mtime); in btrfs_inode_mtime()
1206 return (struct btrfs_timespec *)ptr; in btrfs_inode_mtime()
[all …]
Dstruct-funcs.c127 unsigned long ptr = btrfs_node_key_ptr_offset(nr); in btrfs_node_key() local
128 if (eb->map_token && ptr >= eb->map_start && in btrfs_node_key()
129 ptr + sizeof(*disk_key) <= eb->map_start + eb->map_len) { in btrfs_node_key()
130 memcpy(disk_key, eb->kaddr + ptr - eb->map_start, in btrfs_node_key()
137 read_eb_member(eb, (struct btrfs_key_ptr *)ptr, in btrfs_node_key()
Ddir-item.c42 char *ptr; in insert_with_overflow() local
60 ptr = btrfs_item_ptr(leaf, path->slots[0], char); in insert_with_overflow()
62 ptr += btrfs_item_size(leaf, item) - data_size; in insert_with_overflow()
63 return (struct btrfs_dir_item *)ptr; in insert_with_overflow()
376 unsigned long ptr = (unsigned long)di; in btrfs_delete_one_dir_name() local
380 memmove_extent_buffer(leaf, ptr, ptr + sub_item_len, in btrfs_delete_one_dir_name()
381 item_len - (ptr + sub_item_len - start)); in btrfs_delete_one_dir_name()
Droot-tree.c125 unsigned long ptr; in btrfs_update_root() local
143 ptr = btrfs_item_ptr_offset(l, slot); in btrfs_update_root()
144 write_extent_buffer(l, item, ptr, sizeof(*item)); in btrfs_update_root()
342 unsigned long ptr; in btrfs_add_root_ref() local
360 ptr = (unsigned long)(ref + 1); in btrfs_add_root_ref()
361 write_extent_buffer(leaf, name, ptr, name_len); in btrfs_add_root_ref()
Dtree-log.c667 unsigned long ptr; in backref_in_log() local
681 ptr = btrfs_item_ptr_offset(path->nodes[0], path->slots[0]); in backref_in_log()
682 ptr_end = ptr + item_size; in backref_in_log()
683 while (ptr < ptr_end) { in backref_in_log()
684 ref = (struct btrfs_inode_ref *)ptr; in backref_in_log()
695 ptr = (unsigned long)(ref + 1) + found_name_len; in backref_in_log()
776 unsigned long ptr; in add_inode_ref() local
790 ptr = btrfs_item_ptr_offset(leaf, path->slots[0]); in add_inode_ref()
791 ptr_end = ptr + btrfs_item_size_nr(leaf, path->slots[0]); in add_inode_ref()
792 while (ptr < ptr_end) { in add_inode_ref()
[all …]
/fs/udf/
Ddirectory.c214 uint8_t *ptr; in udf_get_fileident() local
223 ptr = buffer; in udf_get_fileident()
226 ptr += *offset; in udf_get_fileident()
227 fi = (struct fileIdentDesc *)ptr; in udf_get_fileident()
256 uint8_t *ptr;
271 ptr = (uint8_t *)(fe->extendedAttr) +
275 ptr += *offset;
277 ext = (extent_ad *)ptr;
284 short_ad *udf_get_fileshortad(uint8_t *ptr, int maxoffset, uint32_t *offset, in udf_get_fileshortad() argument
289 if ((!ptr) || (!offset)) { in udf_get_fileshortad()
[all …]
Dunicode.c48 int udf_build_ustr(struct ustr *dest, dstring *ptr, int size) in udf_build_ustr() argument
52 if (!dest || !ptr || !size) in udf_build_ustr()
56 usesize = min_t(size_t, ptr[size - 1], sizeof(dest->u_name)); in udf_build_ustr()
58 dest->u_cmpID = ptr[0]; in udf_build_ustr()
60 memcpy(dest->u_name, ptr + 1, usesize); in udf_build_ustr()
69 static int udf_build_ustr_exact(struct ustr *dest, dstring *ptr, int exactsize) in udf_build_ustr_exact() argument
71 if ((!dest) || (!ptr) || (!exactsize)) in udf_build_ustr_exact()
75 dest->u_cmpID = ptr[0]; in udf_build_ustr_exact()
77 memcpy(dest->u_name, ptr + 1, exactsize - 1); in udf_build_ustr_exact()
/fs/adfs/
Ddir_f.c52 static inline int adfs_readname(char *buf, char *ptr, int maxlen) in adfs_readname() argument
56 while ((unsigned char)*ptr >= ' ' && maxlen--) { in adfs_readname()
57 if (*ptr == '/') in adfs_readname()
60 *buf++ = *ptr; in adfs_readname()
61 ptr++; in adfs_readname()
98 union { __le32 *ptr32; u8 *ptr8; } ptr, end; in adfs_dir_checkbyte() local
122 ptr.ptr8 = bufoff(bh, i); in adfs_dir_checkbyte()
123 end.ptr8 = ptr.ptr8 + last - i; in adfs_dir_checkbyte()
126 dircheck = *ptr.ptr8++ ^ ror13(dircheck); in adfs_dir_checkbyte()
127 } while (ptr.ptr8 < end.ptr8); in adfs_dir_checkbyte()
[all …]
/fs/gfs2/
Dlops.c164 __be64 *ptr; in buf_lo_before_commit() local
180 ptr = bh_log_ptr(bh); in buf_lo_before_commit()
187 *ptr++ = cpu_to_be64(bd1->bd_bh->b_blocknr); in buf_lo_before_commit()
243 struct gfs2_log_descriptor *ld, __be64 *ptr, in buf_lo_scan_elements() argument
260 blkno = be64_to_cpu(*ptr++); in buf_lo_scan_elements()
378 struct gfs2_log_descriptor *ld, __be64 *ptr, in revoke_lo_scan_elements() argument
535 __be32 *ptr; in gfs2_check_magic() local
539 ptr = kaddr + bh_offset(bh); in gfs2_check_magic()
540 if (*ptr == cpu_to_be32(GFS2_MAGIC)) in gfs2_check_magic()
552 __be64 *ptr; in gfs2_write_blocks() local
[all …]
Dbmap.c295 __be64 *ptr; in lookup_metapath() local
300 ptr = metapointer(x, mp); in lookup_metapath()
301 dblock = be64_to_cpu(*ptr); in lookup_metapath()
339 static inline unsigned int gfs2_extent_length(void *start, unsigned int len, __be64 *ptr, unsigned … in gfs2_extent_length() argument
342 const __be64 *first = ptr; in gfs2_extent_length()
343 u64 d = be64_to_cpu(*ptr); in gfs2_extent_length()
347 ptr++; in gfs2_extent_length()
348 if (ptr >= end) in gfs2_extent_length()
354 } while(be64_to_cpu(*ptr) == d); in gfs2_extent_length()
355 if (ptr >= end) in gfs2_extent_length()
[all …]
/fs/partitions/
Dibm.c25 cchh2blk (struct vtoc_cchh *ptr, struct hd_geometry *geo) { in cchh2blk() argument
26 return ptr->cc * geo->heads * geo->sectors + in cchh2blk()
27 ptr->hh * geo->sectors; in cchh2blk()
35 cchhb2blk (struct vtoc_cchhb *ptr, struct hd_geometry *geo) { in cchhb2blk() argument
36 return ptr->cc * geo->heads * geo->sectors + in cchhb2blk()
37 ptr->hh * geo->sectors + in cchhb2blk()
38 ptr->b; in cchhb2blk()
/fs/ocfs2/
Docfs2.h469 #define OCFS2_IS_VALID_DINODE(ptr) \ argument
470 (!strcmp((ptr)->i_signature, OCFS2_INODE_SIGNATURE))
472 #define OCFS2_IS_VALID_EXTENT_BLOCK(ptr) \ argument
473 (!strcmp((ptr)->h_signature, OCFS2_EXTENT_BLOCK_SIGNATURE))
475 #define OCFS2_IS_VALID_GROUP_DESC(ptr) \ argument
476 (!strcmp((ptr)->bg_signature, OCFS2_GROUP_DESC_SIGNATURE))
479 #define OCFS2_IS_VALID_XATTR_BLOCK(ptr) \ argument
480 (!strcmp((ptr)->xb_signature, OCFS2_XATTR_BLOCK_SIGNATURE))
482 #define OCFS2_IS_VALID_DIR_TRAILER(ptr) \ argument
483 (!strcmp((ptr)->db_signature, OCFS2_DIR_TRAILER_SIGNATURE))
Dstack_user.c370 char *ptr = NULL; in ocfs2_control_do_setnode_msg() local
385 nodenum = simple_strtol(msg->nodestr, &ptr, 16); in ocfs2_control_do_setnode_msg()
386 if (!ptr || *ptr) in ocfs2_control_do_setnode_msg()
401 char *ptr = NULL; in ocfs2_control_do_setversion_msg() local
419 major = simple_strtol(msg->major, &ptr, 16); in ocfs2_control_do_setversion_msg()
420 if (!ptr || *ptr) in ocfs2_control_do_setversion_msg()
422 minor = simple_strtol(msg->minor, &ptr, 16); in ocfs2_control_do_setversion_msg()
423 if (!ptr || *ptr) in ocfs2_control_do_setversion_msg()
/fs/ramfs/
Dfile-nommu.c247 struct page **pages = NULL, **ptr, *page; in ramfs_nommu_get_unmapped_area() local
276 ptr = pages; in ramfs_nommu_get_unmapped_area()
277 page = *ptr++; in ramfs_nommu_get_unmapped_area()
280 if (*ptr++ != page++) in ramfs_nommu_get_unmapped_area()
287 ptr = pages; in ramfs_nommu_get_unmapped_area()
289 put_page(*ptr++); in ramfs_nommu_get_unmapped_area()
/fs/omfs/
Dinode.c77 unsigned char *ptr = (unsigned char *) oi; in omfs_update_checksums() local
82 crc = crc_itu_t(crc, ptr + ofs, count); in omfs_update_checksums()
85 xor = ptr[0]; in omfs_update_checksums()
87 xor ^= ptr[i]; in omfs_update_checksums()
298 unsigned long **ptr; in omfs_get_imap() local
313 ptr = sbi->s_imap; in omfs_get_imap()
318 *ptr = kmalloc(sb->s_blocksize, GFP_KERNEL); in omfs_get_imap()
319 if (!*ptr) { in omfs_get_imap()
323 memcpy(*ptr, bh->b_data, sb->s_blocksize); in omfs_get_imap()
325 memset((void *)*ptr + count, 0xff, in omfs_get_imap()
[all …]
/fs/hfs/
Dmdb.c71 char *ptr; in hfs_mdb_get() local
176 ptr = (u8 *)HFS_SB(sb)->bitmap; in hfs_mdb_get()
185 memcpy(ptr, bh->b_data + off2, len); in hfs_mdb_get()
187 ptr += len; in hfs_mdb_get()
295 char *ptr; in hfs_mdb_commit() local
302 ptr = (u8 *)HFS_SB(sb)->bitmap; in hfs_mdb_commit()
310 memcpy(bh->b_data + off, ptr, len); in hfs_mdb_commit()
315 ptr += len; in hfs_mdb_commit()
Dbfind.c16 void *ptr; in hfs_find_init() local
20 ptr = kmalloc(tree->max_key_len * 2 + 4, GFP_KERNEL); in hfs_find_init()
21 if (!ptr) in hfs_find_init()
23 fd->search_key = ptr; in hfs_find_init()
24 fd->key = ptr + tree->max_key_len + 2; in hfs_find_init()
/fs/hfsplus/
Dbfind.c16 void *ptr; in hfs_find_init() local
20 ptr = kmalloc(tree->max_key_len * 2 + 4, GFP_KERNEL); in hfs_find_init()
21 if (!ptr) in hfs_find_init()
23 fd->search_key = ptr; in hfs_find_init()
24 fd->key = ptr + tree->max_key_len + 2; in hfs_find_init()
/fs/ufs/
Dinode.c422 unsigned long ptr,phys; in ufs_getfrag_block() local
451 ptr = fragment; in ufs_getfrag_block()
470 if (ptr < UFS_NDIR_FRAGMENT) { in ufs_getfrag_block()
471 bh = GET_INODE_DATABLOCK(ptr); in ufs_getfrag_block()
474 ptr -= UFS_NDIR_FRAGMENT; in ufs_getfrag_block()
475 if (ptr < (1 << (uspi->s_apbshift + uspi->s_fpbshift))) { in ufs_getfrag_block()
476 bh = GET_INODE_PTR(UFS_IND_FRAGMENT + (ptr >> uspi->s_apbshift)); in ufs_getfrag_block()
479 ptr -= 1 << (uspi->s_apbshift + uspi->s_fpbshift); in ufs_getfrag_block()
480 if (ptr < (1 << (uspi->s_2apbshift + uspi->s_fpbshift))) { in ufs_getfrag_block()
481 bh = GET_INODE_PTR(UFS_DIND_FRAGMENT + (ptr >> uspi->s_2apbshift)); in ufs_getfrag_block()
[all …]
/fs/autofs/
Ddirhash.c170 off_t *ptr, struct autofs_dir_ent *last) in autofs_hash_enum() argument
175 bucket = (*ptr >> 16) - 1; in autofs_hash_enum()
176 ecount = *ptr & 0xffff; in autofs_hash_enum()
212 *ptr = ((bucket+1) << 16) + ecount; in autofs_hash_enum()

1234