Home
last modified time | relevance | path

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

/fs/jffs2/
Dwrite.c206 struct jffs2_raw_dirent *rd, const unsigned char *name, in jffs2_write_dirent() argument
218 je32_to_cpu(rd->pino), name, name, je32_to_cpu(rd->ino), in jffs2_write_dirent()
219 je32_to_cpu(rd->name_crc)); in jffs2_write_dirent()
221 D1(if(je32_to_cpu(rd->hdr_crc) != crc32(0, rd, sizeof(struct jffs2_unknown_node)-4)) { in jffs2_write_dirent()
231 je32_to_cpu(rd->pino), name, name, je32_to_cpu(rd->ino), in jffs2_write_dirent()
232 je32_to_cpu(rd->name_crc)); in jffs2_write_dirent()
237 vecs[0].iov_base = rd; in jffs2_write_dirent()
238 vecs[0].iov_len = sizeof(*rd); in jffs2_write_dirent()
246 fd->version = je32_to_cpu(rd->version); in jffs2_write_dirent()
247 fd->ino = je32_to_cpu(rd->ino); in jffs2_write_dirent()
[all …]
Ddir.c290 struct jffs2_raw_dirent *rd; in jffs2_symlink() local
384 ret = jffs2_reserve_space(c, sizeof(*rd)+namelen, &alloclen, in jffs2_symlink()
389 rd = jffs2_alloc_raw_dirent(); in jffs2_symlink()
390 if (!rd) { in jffs2_symlink()
400 rd->magic = cpu_to_je16(JFFS2_MAGIC_BITMASK); in jffs2_symlink()
401 rd->nodetype = cpu_to_je16(JFFS2_NODETYPE_DIRENT); in jffs2_symlink()
402 rd->totlen = cpu_to_je32(sizeof(*rd) + namelen); in jffs2_symlink()
403 rd->hdr_crc = cpu_to_je32(crc32(0, rd, sizeof(struct jffs2_unknown_node)-4)); in jffs2_symlink()
405 rd->pino = cpu_to_je32(dir_i->i_ino); in jffs2_symlink()
406 rd->version = cpu_to_je32(++dir_f->highest_version); in jffs2_symlink()
[all …]
Dreadinode.c587 struct jffs2_raw_dirent *rd, size_t read, in read_direntry() argument
596 crc = crc32(0, rd, sizeof(*rd) - 8); in read_direntry()
597 if (unlikely(crc != je32_to_cpu(rd->node_crc))) { in read_direntry()
599 ref_offset(ref), je32_to_cpu(rd->node_crc), crc); in read_direntry()
610 if (unlikely(PAD((rd->nsize + sizeof(*rd))) != PAD(je32_to_cpu(rd->totlen)))) { in read_direntry()
612 ref_offset(ref), rd->nsize, je32_to_cpu(rd->totlen)); in read_direntry()
625 ref->flash_offset = ref_offset(ref) | dirent_node_state(rd); in read_direntry()
629 fd = jffs2_alloc_full_dirent(rd->nsize + 1); in read_direntry()
634 fd->version = je32_to_cpu(rd->version); in read_direntry()
635 fd->ino = je32_to_cpu(rd->ino); in read_direntry()
[all …]
Dgc.c854 struct jffs2_raw_dirent rd; in jffs2_garbage_collect_dirent() local
858 rd.magic = cpu_to_je16(JFFS2_MAGIC_BITMASK); in jffs2_garbage_collect_dirent()
859 rd.nodetype = cpu_to_je16(JFFS2_NODETYPE_DIRENT); in jffs2_garbage_collect_dirent()
860 rd.nsize = strlen(fd->name); in jffs2_garbage_collect_dirent()
861 rd.totlen = cpu_to_je32(sizeof(rd) + rd.nsize); in jffs2_garbage_collect_dirent()
862 rd.hdr_crc = cpu_to_je32(crc32(0, &rd, sizeof(struct jffs2_unknown_node)-4)); in jffs2_garbage_collect_dirent()
864 rd.pino = cpu_to_je32(f->inocache->ino); in jffs2_garbage_collect_dirent()
865 rd.version = cpu_to_je32(++f->highest_version); in jffs2_garbage_collect_dirent()
866 rd.ino = cpu_to_je32(fd->ino); in jffs2_garbage_collect_dirent()
870 rd.mctime = cpu_to_je32(JFFS2_F_I_MTIME(f)); in jffs2_garbage_collect_dirent()
[all …]
Dscan.c49 struct jffs2_raw_dirent *rd, uint32_t ofs, struct jffs2_summary *s);
1046 struct jffs2_raw_dirent *rd, uint32_t ofs, struct jffs2_summary *s) in jffs2_scan_dirent_node() argument
1058 crc = crc32(0, rd, sizeof(*rd)-8); in jffs2_scan_dirent_node()
1060 if (crc != je32_to_cpu(rd->node_crc)) { in jffs2_scan_dirent_node()
1062 __func__, ofs, je32_to_cpu(rd->node_crc), crc); in jffs2_scan_dirent_node()
1064 if ((err = jffs2_scan_dirty_space(c, jeb, PAD(je32_to_cpu(rd->totlen))))) in jffs2_scan_dirent_node()
1069 pseudo_random += je32_to_cpu(rd->version); in jffs2_scan_dirent_node()
1072 checkedlen = strnlen(rd->name, rd->nsize); in jffs2_scan_dirent_node()
1073 if (checkedlen < rd->nsize) { in jffs2_scan_dirent_node()
1081 memcpy(&fd->name, rd->name, checkedlen); in jffs2_scan_dirent_node()
[all …]
Dsummary.c133 int jffs2_sum_add_dirent_mem(struct jffs2_summary *s, struct jffs2_raw_dirent *rd, in jffs2_sum_add_dirent_mem() argument
137 kmalloc(sizeof(struct jffs2_sum_dirent_mem) + rd->nsize, GFP_KERNEL); in jffs2_sum_add_dirent_mem()
142 temp->nodetype = rd->nodetype; in jffs2_sum_add_dirent_mem()
143 temp->totlen = rd->totlen; in jffs2_sum_add_dirent_mem()
145 temp->pino = rd->pino; in jffs2_sum_add_dirent_mem()
146 temp->version = rd->version; in jffs2_sum_add_dirent_mem()
147 temp->ino = rd->ino; in jffs2_sum_add_dirent_mem()
148 temp->nsize = rd->nsize; in jffs2_sum_add_dirent_mem()
149 temp->type = rd->type; in jffs2_sum_add_dirent_mem()
152 memcpy(temp->name, rd->name, rd->nsize); in jffs2_sum_add_dirent_mem()
Dnodelist.h144 #define dirent_node_state(rd) ( (je32_to_cpu((rd)->ino)?REF_PRISTINE:REF_NORMAL) ) argument
402 struct jffs2_raw_dirent *rd, const unsigned char *name,
Dsummary.h186 int jffs2_sum_add_dirent_mem(struct jffs2_summary *s, struct jffs2_raw_dirent *rd, uint32_t ofs);
/fs/hfs/
Ddir.c56 struct hfs_readdir_data *rd; in hfs_readdir() local
149 rd = file->private_data; in hfs_readdir()
150 if (!rd) { in hfs_readdir()
151 rd = kmalloc(sizeof(struct hfs_readdir_data), GFP_KERNEL); in hfs_readdir()
152 if (!rd) { in hfs_readdir()
156 file->private_data = rd; in hfs_readdir()
157 rd->file = file; in hfs_readdir()
159 list_add(&rd->list, &HFS_I(inode)->open_dir_list); in hfs_readdir()
166 memcpy(&rd->key, &fd.key->cat, sizeof(struct hfs_cat_key)); in hfs_readdir()
174 struct hfs_readdir_data *rd = file->private_data; in hfs_dir_release() local
[all …]
Dcatalog.c225 struct hfs_readdir_data *rd; in hfs_cat_delete() local
253 list_for_each_entry(rd, &HFS_I(dir)->open_dir_list, list) { in hfs_cat_delete()
254 if (fd.tree->keycmp(fd.search_key, (void *)&rd->key) < 0) in hfs_cat_delete()
255 rd->file->f_pos--; in hfs_cat_delete()
/fs/hfsplus/
Ddir.c138 struct hfsplus_readdir_data *rd; in hfsplus_readdir() local
264 rd = file->private_data; in hfsplus_readdir()
265 if (!rd) { in hfsplus_readdir()
266 rd = kmalloc(sizeof(struct hfsplus_readdir_data), GFP_KERNEL); in hfsplus_readdir()
267 if (!rd) { in hfsplus_readdir()
271 file->private_data = rd; in hfsplus_readdir()
272 rd->file = file; in hfsplus_readdir()
274 list_add(&rd->list, &HFSPLUS_I(inode)->open_dir_list); in hfsplus_readdir()
281 memcpy(&rd->key, fd.key, sizeof(struct hfsplus_cat_key)); in hfsplus_readdir()
290 struct hfsplus_readdir_data *rd = file->private_data; in hfsplus_dir_release() local
[all …]
Dcatalog.c397 struct hfsplus_readdir_data *rd = in hfsplus_delete_cat() local
399 if (fd.tree->keycmp(fd.search_key, (void *)&rd->key) < 0) in hfsplus_delete_cat()
400 rd->file->f_pos--; in hfsplus_delete_cat()
/fs/ecryptfs/
Dinode.c596 struct renamedata rd = {}; in ecryptfs_rename() local
627 rd.old_mnt_idmap = &nop_mnt_idmap; in ecryptfs_rename()
628 rd.old_dir = d_inode(lower_old_dir_dentry); in ecryptfs_rename()
629 rd.old_dentry = lower_old_dentry; in ecryptfs_rename()
630 rd.new_mnt_idmap = &nop_mnt_idmap; in ecryptfs_rename()
631 rd.new_dir = d_inode(lower_new_dir_dentry); in ecryptfs_rename()
632 rd.new_dentry = lower_new_dentry; in ecryptfs_rename()
633 rc = vfs_rename(&rd); in ecryptfs_rename()
/fs/dlm/
Dmidcomms.c1476 struct dlm_rawmsg_data *rd = data; in midcomms_new_rawmsg_cb() local
1477 struct dlm_header *h = rd->buf; in midcomms_new_rawmsg_cb()
1486 h->u.h_seq = cpu_to_le32(atomic_fetch_inc(&rd->node->seq_send)); in midcomms_new_rawmsg_cb()
1498 struct dlm_rawmsg_data rd; in dlm_midcomms_rawmsg_send() local
1502 rd.node = node; in dlm_midcomms_rawmsg_send()
1503 rd.buf = buf; in dlm_midcomms_rawmsg_send()
1506 &msgbuf, midcomms_new_rawmsg_cb, &rd); in dlm_midcomms_rawmsg_send()
/fs/
Dnamei.c4753 int vfs_rename(struct renamedata *rd) in vfs_rename() argument
4756 struct inode *old_dir = rd->old_dir, *new_dir = rd->new_dir; in vfs_rename()
4757 struct dentry *old_dentry = rd->old_dentry; in vfs_rename()
4758 struct dentry *new_dentry = rd->new_dentry; in vfs_rename()
4759 struct inode **delegated_inode = rd->delegated_inode; in vfs_rename()
4760 unsigned int flags = rd->flags; in vfs_rename()
4772 error = may_delete(rd->old_mnt_idmap, old_dir, old_dentry, is_dir); in vfs_rename()
4777 error = may_create(rd->new_mnt_idmap, new_dir, new_dentry); in vfs_rename()
4782 error = may_delete(rd->new_mnt_idmap, new_dir, in vfs_rename()
4785 error = may_delete(rd->new_mnt_idmap, new_dir, in vfs_rename()
[all …]
/fs/qnx4/
Dinode.c155 int rd, rl; in qnx4_checkroot() local
161 rd = le32_to_cpu(s->RootDir.di_first_xtnt.xtnt_blk) - 1; in qnx4_checkroot()
164 bh = sb_bread(sb, rd + j); /* root dir, first block */ in qnx4_checkroot()
/fs/incfs/
Dvfs.c1404 struct renamedata rd = {}; in dir_rename() local
1446 rd.old_dir = d_inode(backing_old_dir_dentry); in dir_rename()
1447 rd.old_dentry = backing_old_dentry; in dir_rename()
1448 rd.new_dir = d_inode(backing_new_dir_dentry); in dir_rename()
1449 rd.new_dentry = backing_new_dentry; in dir_rename()
1450 rd.flags = flags; in dir_rename()
1451 rd.old_mnt_idmap = &nop_mnt_idmap; in dir_rename()
1452 rd.new_mnt_idmap = &nop_mnt_idmap; in dir_rename()
1453 rd.delegated_inode = NULL; in dir_rename()
1455 error = vfs_rename(&rd); in dir_rename()
/fs/smb/server/
Dvfs.c690 struct renamedata rd; in ksmbd_vfs_rename() local
773 rd.old_mnt_idmap = mnt_idmap(old_path->mnt), in ksmbd_vfs_rename()
774 rd.old_dir = d_inode(old_parent), in ksmbd_vfs_rename()
775 rd.old_dentry = old_child, in ksmbd_vfs_rename()
776 rd.new_mnt_idmap = mnt_idmap(new_path.mnt), in ksmbd_vfs_rename()
777 rd.new_dir = new_path.dentry->d_inode, in ksmbd_vfs_rename()
778 rd.new_dentry = new_dentry, in ksmbd_vfs_rename()
779 rd.flags = flags, in ksmbd_vfs_rename()
780 rd.delegated_inode = NULL, in ksmbd_vfs_rename()
781 err = vfs_rename(&rd); in ksmbd_vfs_rename()
/fs/hpfs/
Ddnode.c242 struct dnode *d, *ad, *rd, *nd = NULL; in hpfs_add_to_dnode() local
341 if (!(rd = hpfs_alloc_dnode(i->i_sb, le32_to_cpu(d->up), &rdno, &qbh2))) { in hpfs_add_to_dnode()
351 rd->root_dnode = 1; in hpfs_add_to_dnode()
352 rd->up = d->up; in hpfs_add_to_dnode()
373 set_last_pointer(i->i_sb, rd, dno); in hpfs_add_to_dnode()
375 d = rd; in hpfs_add_to_dnode()
/fs/cachefiles/
Dnamei.c384 struct renamedata rd = { in cachefiles_bury_object() local
395 ret = vfs_rename(&rd); in cachefiles_bury_object()
/fs/overlayfs/
Doverlayfs.h345 struct renamedata rd = { in ovl_do_rename() local
356 err = vfs_rename(&rd); in ovl_do_rename()
/fs/ubifs/
Dlpt.c1889 int ubifs_lpt_init(struct ubifs_info *c, int rd, int wr) in ubifs_lpt_init() argument
1893 if (rd) { in ubifs_lpt_init()
1910 if (rd) in ubifs_lpt_init()
Dubifs.h1967 int ubifs_lpt_init(struct ubifs_info *c, int rd, int wr);
/fs/fuse/
Dbacking.c1615 struct renamedata rd; in fuse_rename_backing_common() local
1651 rd = (struct renamedata) { in fuse_rename_backing_common()
1660 err = vfs_rename(&rd); in fuse_rename_backing_common()
/fs/nfsd/
Dvfs.c1830 struct renamedata rd = { in nfsd_rename() local
1841 host_err = vfs_rename(&rd); in nfsd_rename()