/fs/ubifs/ |
D | xattr.c | 82 const struct fscrypt_name *nm, const void *value, int size) in create_xattr() argument 102 names_len = host_ui->xattr_names + host_ui->xattr_cnt + fname_len(nm) + 1; in create_xattr() 139 host_ui->xattr_size += CALC_DENT_SIZE(fname_len(nm)); in create_xattr() 141 host_ui->xattr_names += fname_len(nm); in create_xattr() 149 if (strcmp(fname_name(nm), UBIFS_XATTR_NAME_ENCRYPTION_CONTEXT) == 0) in create_xattr() 152 err = ubifs_jnl_update(c, host, nm, inode, 0, 1); in create_xattr() 165 host_ui->xattr_size -= CALC_DENT_SIZE(fname_len(nm)); in create_xattr() 167 host_ui->xattr_names -= fname_len(nm); in create_xattr() 270 struct fscrypt_name nm = { .disk_name = FSTR_INIT((char *)name, strlen(name))}; in ubifs_xattr_set() local 281 if (fname_len(&nm) > UBIFS_MAX_NLEN) in ubifs_xattr_set() [all …]
|
D | dir.c | 188 const struct fscrypt_name *nm) in dbg_check_name() argument 192 if (le16_to_cpu(dent->nlen) != fname_len(nm)) in dbg_check_name() 194 if (memcmp(dent->name, fname_name(nm), fname_len(nm))) in dbg_check_name() 208 struct fscrypt_name nm; in ubifs_lookup() local 212 err = fscrypt_prepare_lookup(dir, dentry, &nm); in ubifs_lookup() 219 if (fname_len(&nm) > UBIFS_MAX_NLEN) { in ubifs_lookup() 230 if (fname_name(&nm) == NULL) { in ubifs_lookup() 231 if (nm.hash & ~UBIFS_S_KEY_HASH_MASK) in ubifs_lookup() 233 dent_key_init_hash(c, &key, dir->i_ino, nm.hash); in ubifs_lookup() 234 err = ubifs_tnc_lookup_dh(c, &key, dent, nm.minor_hash); in ubifs_lookup() [all …]
|
D | key.h | 148 const struct fscrypt_name *nm) in dent_key_init() argument 150 uint32_t hash = c->key_hash(fname_name(nm), fname_len(nm)); in dent_key_init() 183 const struct fscrypt_name *nm) in dent_key_init_flash() argument 186 uint32_t hash = c->key_hash(fname_name(nm), fname_len(nm)); in dent_key_init_flash() 217 const struct fscrypt_name *nm) in xent_key_init() argument 219 uint32_t hash = c->key_hash(fname_name(nm), fname_len(nm)); in xent_key_init() 234 ino_t inum, const struct fscrypt_name *nm) in xent_key_init_flash() argument 237 uint32_t hash = c->key_hash(fname_name(nm), fname_len(nm)); in xent_key_init_flash()
|
D | tnc.c | 569 const struct fscrypt_name *nm) in matches_name() argument 592 err = memcmp(dent->name, fname_name(nm), min_t(int, nlen, fname_len(nm))); in matches_name() 594 if (nlen == fname_len(nm)) in matches_name() 596 else if (nlen < fname_len(nm)) in matches_name() 739 const struct fscrypt_name *nm) in resolve_collision() argument 743 err = matches_name(c, &(*zn)->zbranch[*n], nm); in resolve_collision() 804 err = matches_name(c, &(*zn)->zbranch[*n], nm); in resolve_collision() 826 err = matches_name(c, &znode->zbranch[nn], nm); in resolve_collision() 857 const struct fscrypt_name *nm) in fallible_matches_name() argument 885 err = memcmp(dent->name, fname_name(nm), min_t(int, nlen, fname_len(nm))); in fallible_matches_name() [all …]
|
D | journal.c | 539 const struct fscrypt_name *nm, const struct inode *inode, in ubifs_jnl_update() argument 556 dlen = UBIFS_DENT_NODE_SZ + fname_len(nm) + 1; in ubifs_jnl_update() 591 if (fname_name(nm) == NULL) in ubifs_jnl_update() 592 dent_key_init_hash(c, &dent_key, dir->i_ino, nm->hash); in ubifs_jnl_update() 594 dent_key_init(c, &dent_key, dir->i_ino, nm); in ubifs_jnl_update() 597 xent_key_init(c, &dent_key, dir->i_ino, nm); in ubifs_jnl_update() 603 dent->nlen = cpu_to_le16(fname_len(nm)); in ubifs_jnl_update() 604 memcpy(dent->name, fname_name(nm), fname_len(nm)); in ubifs_jnl_update() 605 dent->name[fname_len(nm)] = '\0'; in ubifs_jnl_update() 650 if (fname_name(nm) == NULL) in ubifs_jnl_update() [all …]
|
D | replay.c | 55 struct fscrypt_name nm; member 252 err = ubifs_tnc_remove_nm(c, &r->key, &r->nm); in apply_replay_entry() 255 r->len, r->hash, &r->nm); in apply_replay_entry() 357 kfree(fname_name(&r->nm)); in destroy_replay_list() 463 fname_len(&r->nm) = nlen; in insert_dent() 466 fname_name(&r->nm) = nbuf; in insert_dent()
|
D | ubifs.h | 1772 const struct fscrypt_name *nm, const struct inode *inode, 1794 const struct inode *inode, const struct fscrypt_name *nm); 1829 void *node, const struct fscrypt_name *nm); 1840 const struct fscrypt_name *nm); 1843 const struct fscrypt_name *nm); 1851 const struct fscrypt_name *nm);
|
D | orphan.c | 161 struct fscrypt_name nm = {0}; in ubifs_add_orphan() local 171 xent = ubifs_tnc_next_ent(c, &key, &nm); in ubifs_add_orphan() 180 fname_name(&nm) = xent->name; in ubifs_add_orphan() 181 fname_len(&nm) = le16_to_cpu(xent->nlen); in ubifs_add_orphan()
|
D | debug.c | 227 struct fscrypt_name nm = {0}; in ubifs_dump_inode() local 273 dent = ubifs_tnc_next_ent(c, &key, &nm); in ubifs_dump_inode() 285 fname_name(&nm) = dent->name; in ubifs_dump_inode() 286 fname_len(&nm) = le16_to_cpu(dent->nlen); in ubifs_dump_inode() 1108 struct fscrypt_name nm = {0}; in dbg_check_dir() local 1121 dent = ubifs_tnc_next_ent(c, &key, &nm); in dbg_check_dir() 1130 fname_name(&nm) = dent->name; in dbg_check_dir() 1131 fname_len(&nm) = le16_to_cpu(dent->nlen); in dbg_check_dir() 1132 size += CALC_DENT_SIZE(fname_len(&nm)); in dbg_check_dir()
|