/fs/jffs2/ |
D | write.c | 200 struct jffs2_raw_dirent *rd, const unsigned char *name, in jffs2_write_dirent() argument 211 je32_to_cpu(rd->pino), name, name, je32_to_cpu(rd->ino), in jffs2_write_dirent() 212 je32_to_cpu(rd->name_crc))); in jffs2_write_dirent() 214 D1(if(je32_to_cpu(rd->hdr_crc) != crc32(0, rd, sizeof(struct jffs2_unknown_node)-4)) { in jffs2_write_dirent() 224 je32_to_cpu(rd->pino), name, name, je32_to_cpu(rd->ino), in jffs2_write_dirent() 225 je32_to_cpu(rd->name_crc)); in jffs2_write_dirent() 230 vecs[0].iov_base = rd; in jffs2_write_dirent() 231 vecs[0].iov_len = sizeof(*rd); in jffs2_write_dirent() 239 fd->version = je32_to_cpu(rd->version); in jffs2_write_dirent() 240 fd->ino = je32_to_cpu(rd->ino); in jffs2_write_dirent() [all …]
|
D | dir.c | 303 struct jffs2_raw_dirent *rd; in jffs2_symlink() local 399 ret = jffs2_reserve_space(c, sizeof(*rd)+namelen, &alloclen, in jffs2_symlink() 407 rd = jffs2_alloc_raw_dirent(); in jffs2_symlink() 408 if (!rd) { in jffs2_symlink() 418 rd->magic = cpu_to_je16(JFFS2_MAGIC_BITMASK); in jffs2_symlink() 419 rd->nodetype = cpu_to_je16(JFFS2_NODETYPE_DIRENT); in jffs2_symlink() 420 rd->totlen = cpu_to_je32(sizeof(*rd) + namelen); in jffs2_symlink() 421 rd->hdr_crc = cpu_to_je32(crc32(0, rd, sizeof(struct jffs2_unknown_node)-4)); in jffs2_symlink() 423 rd->pino = cpu_to_je32(dir_i->i_ino); in jffs2_symlink() 424 rd->version = cpu_to_je32(++dir_f->highest_version); in jffs2_symlink() [all …]
|
D | readinode.c | 604 struct jffs2_raw_dirent *rd, size_t read, in read_direntry() argument 613 crc = crc32(0, rd, sizeof(*rd) - 8); in read_direntry() 614 if (unlikely(crc != je32_to_cpu(rd->node_crc))) { in read_direntry() 616 ref_offset(ref), je32_to_cpu(rd->node_crc), crc); in read_direntry() 627 if (unlikely(PAD((rd->nsize + sizeof(*rd))) != PAD(je32_to_cpu(rd->totlen)))) { in read_direntry() 629 ref_offset(ref), rd->nsize, je32_to_cpu(rd->totlen)); in read_direntry() 642 ref->flash_offset = ref_offset(ref) | dirent_node_state(rd); in read_direntry() 646 fd = jffs2_alloc_full_dirent(rd->nsize + 1); in read_direntry() 651 fd->version = je32_to_cpu(rd->version); in read_direntry() 652 fd->ino = je32_to_cpu(rd->ino); in read_direntry() [all …]
|
D | gc.c | 788 struct jffs2_raw_dirent rd; in jffs2_garbage_collect_dirent() local 792 rd.magic = cpu_to_je16(JFFS2_MAGIC_BITMASK); in jffs2_garbage_collect_dirent() 793 rd.nodetype = cpu_to_je16(JFFS2_NODETYPE_DIRENT); in jffs2_garbage_collect_dirent() 794 rd.nsize = strlen(fd->name); in jffs2_garbage_collect_dirent() 795 rd.totlen = cpu_to_je32(sizeof(rd) + rd.nsize); in jffs2_garbage_collect_dirent() 796 rd.hdr_crc = cpu_to_je32(crc32(0, &rd, sizeof(struct jffs2_unknown_node)-4)); in jffs2_garbage_collect_dirent() 798 rd.pino = cpu_to_je32(f->inocache->ino); in jffs2_garbage_collect_dirent() 799 rd.version = cpu_to_je32(++f->highest_version); in jffs2_garbage_collect_dirent() 800 rd.ino = cpu_to_je32(fd->ino); in jffs2_garbage_collect_dirent() 804 rd.mctime = cpu_to_je32(JFFS2_F_I_MTIME(f)); in jffs2_garbage_collect_dirent() [all …]
|
D | scan.c | 47 struct jffs2_raw_dirent *rd, uint32_t ofs, struct jffs2_summary *s); 1004 struct jffs2_raw_dirent *rd, uint32_t ofs, struct jffs2_summary *s) in jffs2_scan_dirent_node() argument 1016 crc = crc32(0, rd, sizeof(*rd)-8); in jffs2_scan_dirent_node() 1018 if (crc != je32_to_cpu(rd->node_crc)) { in jffs2_scan_dirent_node() 1020 ofs, je32_to_cpu(rd->node_crc), crc); in jffs2_scan_dirent_node() 1022 if ((err = jffs2_scan_dirty_space(c, jeb, PAD(je32_to_cpu(rd->totlen))))) in jffs2_scan_dirent_node() 1027 pseudo_random += je32_to_cpu(rd->version); in jffs2_scan_dirent_node() 1030 checkedlen = strnlen(rd->name, rd->nsize); in jffs2_scan_dirent_node() 1031 if (checkedlen < rd->nsize) { in jffs2_scan_dirent_node() 1039 memcpy(&fd->name, rd->name, checkedlen); in jffs2_scan_dirent_node() [all …]
|
D | summary.c | 131 int jffs2_sum_add_dirent_mem(struct jffs2_summary *s, struct jffs2_raw_dirent *rd, in jffs2_sum_add_dirent_mem() argument 135 kmalloc(sizeof(struct jffs2_sum_dirent_mem) + rd->nsize, GFP_KERNEL); in jffs2_sum_add_dirent_mem() 140 temp->nodetype = rd->nodetype; in jffs2_sum_add_dirent_mem() 141 temp->totlen = rd->totlen; in jffs2_sum_add_dirent_mem() 143 temp->pino = rd->pino; in jffs2_sum_add_dirent_mem() 144 temp->version = rd->version; in jffs2_sum_add_dirent_mem() 145 temp->ino = rd->ino; in jffs2_sum_add_dirent_mem() 146 temp->nsize = rd->nsize; in jffs2_sum_add_dirent_mem() 147 temp->type = rd->type; in jffs2_sum_add_dirent_mem() 150 memcpy(temp->name, rd->name, rd->nsize); in jffs2_sum_add_dirent_mem()
|
D | nodelist.h | 145 #define dirent_node_state(rd) ( (je32_to_cpu((rd)->ino)?REF_PRISTINE:REF_NORMAL) ) argument 398 struct jffs2_raw_dirent *rd, const unsigned char *name,
|
D | summary.h | 186 int jffs2_sum_add_dirent_mem(struct jffs2_summary *s, struct jffs2_raw_dirent *rd, uint32_t ofs);
|
/fs/hfs/ |
D | dir.c | 62 struct hfs_readdir_data *rd; in hfs_readdir() local 145 rd = filp->private_data; in hfs_readdir() 146 if (!rd) { in hfs_readdir() 147 rd = kmalloc(sizeof(struct hfs_readdir_data), GFP_KERNEL); in hfs_readdir() 148 if (!rd) { in hfs_readdir() 152 filp->private_data = rd; in hfs_readdir() 153 rd->file = filp; in hfs_readdir() 154 list_add(&rd->list, &HFS_I(inode)->open_dir_list); in hfs_readdir() 156 memcpy(&rd->key, &fd.key, sizeof(struct hfs_cat_key)); in hfs_readdir() 164 struct hfs_readdir_data *rd = file->private_data; in hfs_dir_release() local [all …]
|
D | catalog.c | 237 struct hfs_readdir_data *rd = in hfs_cat_delete() local 239 if (fd.tree->keycmp(fd.search_key, (void *)&rd->key) < 0) in hfs_cat_delete() 240 rd->file->f_pos--; in hfs_cat_delete()
|
/fs/hfsplus/ |
D | dir.c | 121 struct hfsplus_readdir_data *rd; in hfsplus_readdir() local 211 rd = filp->private_data; in hfsplus_readdir() 212 if (!rd) { in hfsplus_readdir() 213 rd = kmalloc(sizeof(struct hfsplus_readdir_data), GFP_KERNEL); in hfsplus_readdir() 214 if (!rd) { in hfsplus_readdir() 218 filp->private_data = rd; in hfsplus_readdir() 219 rd->file = filp; in hfsplus_readdir() 220 list_add(&rd->list, &HFSPLUS_I(inode).open_dir_list); in hfsplus_readdir() 222 memcpy(&rd->key, fd.key, sizeof(struct hfsplus_cat_key)); in hfsplus_readdir() 230 struct hfsplus_readdir_data *rd = file->private_data; in hfsplus_dir_release() local [all …]
|
D | catalog.c | 283 struct hfsplus_readdir_data *rd = in hfsplus_delete_cat() local 285 if (fd.tree->keycmp(fd.search_key, (void *)&rd->key) < 0) in hfsplus_delete_cat() 286 rd->file->f_pos--; in hfsplus_delete_cat()
|
/fs/qnx4/ |
D | inode.c | 309 int rd, rl; in qnx4_checkroot() local 317 rd = le32_to_cpu(qnx4_sb(sb)->sb->RootDir.di_first_xtnt.xtnt_blk) - 1; in qnx4_checkroot() 320 bh = sb_bread(sb, rd + j); /* root dir, first block */ in qnx4_checkroot()
|
/fs/hpfs/ |
D | dnode.c | 230 struct dnode *d, *ad, *rd, *nd = NULL; in hpfs_add_to_dnode() local 326 if (!(rd = hpfs_alloc_dnode(i->i_sb, d->up, &rdno, &qbh2, 0))) { in hpfs_add_to_dnode() 336 rd->root_dnode = 1; in hpfs_add_to_dnode() 337 rd->up = d->up; in hpfs_add_to_dnode() 357 set_last_pointer(i->i_sb, rd, dno); in hpfs_add_to_dnode() 359 d = rd; in hpfs_add_to_dnode()
|
/fs/ubifs/ |
D | ubifs.h | 1611 int ubifs_lpt_init(struct ubifs_info *c, int rd, int wr);
|
D | lpt.c | 1728 int ubifs_lpt_init(struct ubifs_info *c, int rd, int wr) in ubifs_lpt_init() argument 1732 if (rd) { in ubifs_lpt_init()
|