/fs/ |
D | open.c | 166 struct fd f; in do_sys_ftruncate() local 173 f = fdget(fd); in do_sys_ftruncate() 174 if (!f.file) in do_sys_ftruncate() 178 if (f.file->f_flags & O_LARGEFILE) in do_sys_ftruncate() 181 dentry = f.file->f_path.dentry; in do_sys_ftruncate() 182 mnt = f.file->f_path.mnt; in do_sys_ftruncate() 185 if (!S_ISREG(inode->i_mode) || !(f.file->f_mode & FMODE_WRITE)) in do_sys_ftruncate() 198 error = locks_verify_truncate(inode, f.file, length); in do_sys_ftruncate() 200 error = security_path_truncate(&f.file->f_path); in do_sys_ftruncate() 202 error = do_truncate2(mnt, dentry, length, ATTR_MTIME|ATTR_CTIME, f.file); in do_sys_ftruncate() [all …]
|
D | read_write.c | 269 static inline void fdput_pos(struct fd f) in fdput_pos() argument 271 if (f.flags & FDPUT_POS_UNLOCK) in fdput_pos() 272 mutex_unlock(&f.file->f_pos_lock); in fdput_pos() 273 fdput(f); in fdput_pos() 279 struct fd f = fdget_pos(fd); in SYSCALL_DEFINE3() local 280 if (!f.file) in SYSCALL_DEFINE3() 285 loff_t res = vfs_llseek(f.file, offset, whence); in SYSCALL_DEFINE3() 290 fdput_pos(f); in SYSCALL_DEFINE3() 307 struct fd f = fdget_pos(fd); in SYSCALL_DEFINE5() local 310 if (!f.file) in SYSCALL_DEFINE5() [all …]
|
D | file_table.c | 46 struct file *f = container_of(head, struct file, f_u.fu_rcuhead); in file_free_rcu() local 48 put_cred(f->f_cred); in file_free_rcu() 49 kmem_cache_free(filp_cachep, f); in file_free_rcu() 52 static inline void file_free(struct file *f) in file_free() argument 55 call_rcu(&f->f_u.fu_rcuhead, file_free_rcu); in file_free() 107 struct file *f; in get_empty_filp() local 122 f = kmem_cache_zalloc(filp_cachep, GFP_KERNEL); in get_empty_filp() 123 if (unlikely(!f)) in get_empty_filp() 127 f->f_cred = get_cred(cred); in get_empty_filp() 128 error = security_file_alloc(f); in get_empty_filp() [all …]
|
D | sync.c | 156 struct fd f = fdget(fd); in SYSCALL_DEFINE1() local 160 if (!f.file) in SYSCALL_DEFINE1() 162 sb = f.file->f_path.dentry->d_sb; in SYSCALL_DEFINE1() 168 fdput(f); in SYSCALL_DEFINE1() 215 struct fd f = fdget(fd); in do_fsync() local 218 if (f.file) { in do_fsync() 219 ret = vfs_fsync(f.file, datasync); in do_fsync() 220 fdput(f); in do_fsync() 287 struct fd f; in SYSCALL_DEFINE4() local 328 f = fdget(fd); in SYSCALL_DEFINE4() [all …]
|
D | readdir.c | 148 struct fd f = fdget(fd); in SYSCALL_DEFINE3() local 154 if (!f.file) in SYSCALL_DEFINE3() 157 error = iterate_dir(f.file, &buf.ctx); in SYSCALL_DEFINE3() 161 fdput(f); in SYSCALL_DEFINE3() 236 struct fd f; in SYSCALL_DEFINE3() local 248 f = fdget(fd); in SYSCALL_DEFINE3() 249 if (!f.file) in SYSCALL_DEFINE3() 252 error = iterate_dir(f.file, &buf.ctx); in SYSCALL_DEFINE3() 262 fdput(f); in SYSCALL_DEFINE3() 320 struct fd f; in SYSCALL_DEFINE3() local [all …]
|
D | locks.c | 1926 struct fd f = fdget(fd); in SYSCALL_DEFINE2() local 1932 if (!f.file) in SYSCALL_DEFINE2() 1940 !(f.file->f_mode & (FMODE_READ|FMODE_WRITE))) in SYSCALL_DEFINE2() 1943 lock = flock_make_lock(f.file, cmd); in SYSCALL_DEFINE2() 1952 error = security_file_lock(f.file, lock->fl_type); in SYSCALL_DEFINE2() 1956 if (f.file->f_op->flock) in SYSCALL_DEFINE2() 1957 error = f.file->f_op->flock(f.file, in SYSCALL_DEFINE2() 1961 error = locks_lock_file_wait(f.file, lock); in SYSCALL_DEFINE2() 1967 fdput(f); in SYSCALL_DEFINE2() 2162 struct file *f; in fcntl_setlk() local [all …]
|
D | xattr.c | 407 struct fd f = fdget(fd); in SYSCALL_DEFINE5() local 410 if (!f.file) in SYSCALL_DEFINE5() 412 audit_file(f.file); in SYSCALL_DEFINE5() 413 error = mnt_want_write_file(f.file); in SYSCALL_DEFINE5() 415 error = setxattr(f.file->f_path.dentry, name, value, size, flags); in SYSCALL_DEFINE5() 416 mnt_drop_write_file(f.file); in SYSCALL_DEFINE5() 418 fdput(f); in SYSCALL_DEFINE5() 505 struct fd f = fdget(fd); in SYSCALL_DEFINE4() local 508 if (!f.file) in SYSCALL_DEFINE4() 510 audit_file(f.file); in SYSCALL_DEFINE4() [all …]
|
D | timerfd.c | 375 struct fd f = fdget(fd); in timerfd_fget() local 376 if (!f.file) in timerfd_fget() 378 if (f.file->f_op != &timerfd_fops) { in timerfd_fget() 379 fdput(f); in timerfd_fget() 382 *p = f; in timerfd_fget() 438 struct fd f; in do_timerfd_settime() local 447 ret = timerfd_fget(ufd, &f); in do_timerfd_settime() 450 ctx = f.file->private_data; in do_timerfd_settime() 453 fdput(f); in do_timerfd_settime() 499 fdput(f); in do_timerfd_settime() [all …]
|
/fs/jffs2/ |
D | gc.c | 29 struct jffs2_inode_info *f, struct jffs2_full_dnode *fd); 31 struct jffs2_inode_info *f, struct jffs2_full_dirent *fd); 33 struct jffs2_inode_info *f, struct jffs2_full_dirent *fd); 35 struct jffs2_inode_info *f, struct jffs2_full_dnode *fn, 38 struct jffs2_inode_info *f, struct jffs2_full_dnode *fn, 41 struct jffs2_raw_node_ref *raw, struct jffs2_inode_info *f); 126 struct jffs2_inode_info *f; in jffs2_garbage_collect_pass() local 434 f = jffs2_gc_fetch_inode(c, inum, !nlink); in jffs2_garbage_collect_pass() 435 if (IS_ERR(f)) { in jffs2_garbage_collect_pass() 436 ret = PTR_ERR(f); in jffs2_garbage_collect_pass() [all …]
|
D | readinode.c | 452 struct jffs2_inode_info *f, in jffs2_build_inode_fragtree() argument 518 ret = jffs2_add_full_dnode_to_inode(c, f, this->fn); in jffs2_build_inode_fragtree() 981 static int jffs2_get_inode_nodes(struct jffs2_sb_info *c, struct jffs2_inode_info *f, in jffs2_get_inode_nodes() argument 992 dbg_readinode("ino #%u\n", f->inocache->ino); in jffs2_get_inode_nodes() 1002 valid_ref = jffs2_first_valid_node(f->inocache->nodes); in jffs2_get_inode_nodes() 1003 if (!valid_ref && f->inocache->ino != 1) in jffs2_get_inode_nodes() 1004 JFFS2_WARNING("Eep. No valid nodes for ino #%u.\n", f->inocache->ino); in jffs2_get_inode_nodes() 1130 f->highest_version = rii->highest_version; in jffs2_get_inode_nodes() 1133 f->inocache->ino, rii->highest_version, rii->latest_mctime, in jffs2_get_inode_nodes() 1146 struct jffs2_inode_info *f, in jffs2_do_read_inode_internal() argument [all …]
|
D | os-linux.h | 23 #define OFNI_EDONI_2SFFJ(f) (&(f)->vfs_inode) argument 28 #define JFFS2_F_I_SIZE(f) (OFNI_EDONI_2SFFJ(f)->i_size) argument 29 #define JFFS2_F_I_MODE(f) (OFNI_EDONI_2SFFJ(f)->i_mode) argument 30 #define JFFS2_F_I_UID(f) (i_uid_read(OFNI_EDONI_2SFFJ(f))) argument 31 #define JFFS2_F_I_GID(f) (i_gid_read(OFNI_EDONI_2SFFJ(f))) argument 32 #define JFFS2_F_I_RDEV(f) (OFNI_EDONI_2SFFJ(f)->i_rdev) argument 36 #define JFFS2_F_I_CTIME(f) (OFNI_EDONI_2SFFJ(f)->i_ctime.tv_sec) argument 37 #define JFFS2_F_I_MTIME(f) (OFNI_EDONI_2SFFJ(f)->i_mtime.tv_sec) argument 38 #define JFFS2_F_I_ATIME(f) (OFNI_EDONI_2SFFJ(f)->i_atime.tv_sec) argument 50 static inline void jffs2_init_inode_info(struct jffs2_inode_info *f) in jffs2_init_inode_info() argument [all …]
|
D | fs.c | 33 struct jffs2_inode_info *f = JFFS2_INODE_INFO(inode); in jffs2_do_setattr() local 58 mutex_lock(&f->sem); in jffs2_do_setattr() 59 mdatalen = f->metadata->size; in jffs2_do_setattr() 60 mdata = kmalloc(f->metadata->size, GFP_USER); in jffs2_do_setattr() 62 mutex_unlock(&f->sem); in jffs2_do_setattr() 65 ret = jffs2_read_dnode(c, f, f->metadata, mdata, 0, mdatalen); in jffs2_do_setattr() 67 mutex_unlock(&f->sem); in jffs2_do_setattr() 71 mutex_unlock(&f->sem); in jffs2_do_setattr() 91 mutex_lock(&f->sem); in jffs2_do_setattr() 100 ri->version = cpu_to_je32(++f->highest_version); in jffs2_do_setattr() [all …]
|
D | write.c | 23 int jffs2_do_new_inode(struct jffs2_sb_info *c, struct jffs2_inode_info *f, in jffs2_do_new_inode() argument 35 f->inocache = ic; in jffs2_do_new_inode() 36 f->inocache->pino_nlink = 1; /* Will be overwritten shortly for directories */ in jffs2_do_new_inode() 37 f->inocache->nodes = (struct jffs2_raw_node_ref *)f->inocache; in jffs2_do_new_inode() 38 f->inocache->state = INO_STATE_PRESENT; in jffs2_do_new_inode() 40 jffs2_add_ino_cache(c, f->inocache); in jffs2_do_new_inode() 41 jffs2_dbg(1, "%s(): Assigned ino# %d\n", __func__, f->inocache->ino); in jffs2_do_new_inode() 42 ri->ino = cpu_to_je32(f->inocache->ino); in jffs2_do_new_inode() 50 f->highest_version = 1; in jffs2_do_new_inode() 51 ri->version = cpu_to_je32(f->highest_version); in jffs2_do_new_inode() [all …]
|
D | dir.c | 121 struct jffs2_inode_info *f = JFFS2_INODE_INFO(inode); in jffs2_readdir() local 130 mutex_lock(&f->sem); in jffs2_readdir() 131 for (fd = f->dents; fd; fd = fd->next) { in jffs2_readdir() 151 mutex_unlock(&f->sem); in jffs2_readdir() 162 struct jffs2_inode_info *f, *dir_f; in jffs2_create() local 188 f = JFFS2_INODE_INFO(inode); in jffs2_create() 196 mutex_unlock(&f->sem); in jffs2_create() 198 ret = jffs2_do_create(c, dir_f, f, ri, &dentry->d_name); in jffs2_create() 208 f->inocache->pino_nlink, inode->i_mapping->nrpages); in jffs2_create() 244 struct jffs2_inode_info *f = JFFS2_INODE_INFO(d_inode(old_dentry)); in jffs2_link() local [all …]
|
D | debug.h | 181 __jffs2_dbg_fragtree_paranoia_check(struct jffs2_inode_info *f); 183 __jffs2_dbg_fragtree_paranoia_check_nolock(struct jffs2_inode_info *f); 210 __jffs2_dbg_dump_fragtree(struct jffs2_inode_info *f); 212 __jffs2_dbg_dump_fragtree_nolock(struct jffs2_inode_info *f); 219 #define jffs2_dbg_fragtree_paranoia_check(f) \ argument 220 __jffs2_dbg_fragtree_paranoia_check(f) 221 #define jffs2_dbg_fragtree_paranoia_check_nolock(f) \ argument 222 __jffs2_dbg_fragtree_paranoia_check_nolock(f) 230 #define jffs2_dbg_fragtree_paranoia_check(f) argument 231 #define jffs2_dbg_fragtree_paranoia_check_nolock(f) argument [all …]
|
D | file.c | 84 struct jffs2_inode_info *f = JFFS2_INODE_INFO(inode); in jffs2_do_readpage_nolock() local 97 ret = jffs2_read_inode_range(c, f, pg_buf, pg->index << PAGE_CACHE_SHIFT, PAGE_CACHE_SIZE); in jffs2_do_readpage_nolock() 124 struct jffs2_inode_info *f = JFFS2_INODE_INFO(pg->mapping->host); in jffs2_readpage() local 127 mutex_lock(&f->sem); in jffs2_readpage() 129 mutex_unlock(&f->sem); in jffs2_readpage() 139 struct jffs2_inode_info *f = JFFS2_INODE_INFO(inode); in jffs2_write_begin() local 166 mutex_lock(&f->sem); in jffs2_write_begin() 174 ri.ino = cpu_to_je32(f->inocache->ino); in jffs2_write_begin() 175 ri.version = cpu_to_je32(++f->highest_version); in jffs2_write_begin() 188 fn = jffs2_write_dnode(c, f, &ri, NULL, 0, ALLOC_NORMAL); in jffs2_write_begin() [all …]
|
D | super.c | 39 struct jffs2_inode_info *f; in jffs2_alloc_inode() local 41 f = kmem_cache_alloc(jffs2_inode_cachep, GFP_KERNEL); in jffs2_alloc_inode() 42 if (!f) in jffs2_alloc_inode() 44 return &f->vfs_inode; in jffs2_alloc_inode() 50 struct jffs2_inode_info *f = JFFS2_INODE_INFO(inode); in jffs2_i_callback() local 52 kfree(f->target); in jffs2_i_callback() 53 kmem_cache_free(jffs2_inode_cachep, f); in jffs2_i_callback() 63 struct jffs2_inode_info *f = foo; in jffs2_i_init_once() local 65 mutex_init(&f->sem); in jffs2_i_init_once() 66 inode_init_once(&f->vfs_inode); in jffs2_i_init_once() [all …]
|
/fs/notify/ |
D | fdinfo.c | 23 static void show_fdinfo(struct seq_file *m, struct file *f, in show_fdinfo() argument 27 struct fsnotify_group *group = f->private_data; in show_fdinfo() 45 } f; in show_mark_fhandle() local 48 f.handle.handle_bytes = sizeof(f.pad); in show_mark_fhandle() 49 size = f.handle.handle_bytes >> 2; in show_mark_fhandle() 51 ret = exportfs_encode_inode_fh(inode, (struct fid *)f.handle.f_handle, &size, 0); in show_mark_fhandle() 57 f.handle.handle_type = ret; in show_mark_fhandle() 58 f.handle.handle_bytes = size * sizeof(u32); in show_mark_fhandle() 61 f.handle.handle_bytes, f.handle.handle_type); in show_mark_fhandle() 63 for (i = 0; i < f.handle.handle_bytes; i++) in show_mark_fhandle() [all …]
|
/fs/proc/ |
D | devices.c | 6 static int devinfo_show(struct seq_file *f, void *v) in devinfo_show() argument 12 seq_puts(f, "Character devices:\n"); in devinfo_show() 13 chrdev_show(f, i); in devinfo_show() 19 seq_puts(f, "\nBlock devices:\n"); in devinfo_show() 20 blkdev_show(f, i); in devinfo_show() 26 static void *devinfo_start(struct seq_file *f, loff_t *pos) in devinfo_start() argument 33 static void *devinfo_next(struct seq_file *f, void *v, loff_t *pos) in devinfo_next() argument 41 static void devinfo_stop(struct seq_file *f, void *v) in devinfo_stop() argument
|
D | proc_net.c | 39 int seq_open_net(struct inode *ino, struct file *f, in seq_open_net() argument 51 p = __seq_open_private(f, ops, size); in seq_open_net() 87 int seq_release_net(struct inode *ino, struct file *f) in seq_release_net() argument 91 seq = f->private_data; in seq_release_net() 94 seq_release_private(ino, f); in seq_release_net() 99 int single_release_net(struct inode *ino, struct file *f) in single_release_net() argument 101 struct seq_file *seq = f->private_data; in single_release_net() 103 return single_release(ino, f); in single_release_net()
|
/fs/ntfs/ |
D | debug.h | 44 #define ntfs_debug(f, a...) \ argument 45 __ntfs_debug(__FILE__, __LINE__, __func__, f, ##a) 64 #define ntfs_warning(sb, f, a...) __ntfs_warning(__func__, sb, f, ##a) argument 69 #define ntfs_error(sb, f, a...) __ntfs_error(__func__, sb, f, ##a) argument
|
/fs/lockd/ |
D | svcsubs.c | 35 static inline void nlm_debug_print_fh(char *msg, struct nfs_fh *f) in nlm_debug_print_fh() argument 37 u32 *fhp = (u32*)f->data; in nlm_debug_print_fh() 53 static inline void nlm_debug_print_fh(char *msg, struct nfs_fh *f) in nlm_debug_print_fh() argument 64 static inline unsigned int file_hash(struct nfs_fh *f) in file_hash() argument 69 tmp += f->data[i]; in file_hash() 84 struct nfs_fh *f) in nlm_lookup_file() argument 90 nlm_debug_print_fh("nlm_lookup_file", f); in nlm_lookup_file() 92 hash = file_hash(f); in nlm_lookup_file() 98 if (!nfs_compare_fh(&file->f_handle, f)) in nlm_lookup_file() 101 nlm_debug_print_fh("creating file for", f); in nlm_lookup_file() [all …]
|
/fs/nfsd/ |
D | auth.c | 9 struct exp_flavor_info *f; in nfsexp_flags() local 12 for (f = exp->ex_flavors; f < end; f++) { in nfsexp_flags() 13 if (f->pseudoflavor == rqstp->rq_cred.cr_flavor) in nfsexp_flags() 14 return f->flags; in nfsexp_flags()
|
/fs/openpromfs/ |
D | inode.c | 65 static int property_show(struct seq_file *f, void *v) in property_show() argument 67 struct property *prop = f->private; in property_show() 78 seq_printf(f, "%s", (char *) pval); in property_show() 85 seq_printf(f, " + "); in property_show() 92 seq_printf(f, "%02x.", in property_show() 95 seq_printf(f, "%02x", in property_show() 104 seq_printf(f, "%08x.", in property_show() 107 seq_printf(f, "%08x", in property_show() 113 seq_printf(f, "\n"); in property_show() 118 static void *property_start(struct seq_file *f, loff_t *pos) in property_start() argument [all …]
|
/fs/xfs/ |
D | xfs_linux.h | 122 #define current_test_flags(f) (current->flags & (f)) argument 123 #define current_set_flags_nested(sp, f) \ argument 124 (*(sp) = current->flags, current->flags |= (f)) 125 #define current_clear_flags_nested(sp, f) \ argument 126 (*(sp) = current->flags, current->flags &= ~(f)) 127 #define current_restore_flags_nested(sp, f) \ argument 128 (current->flags = ((current->flags & ~(f)) | (*(sp) & (f))))
|