/fs/ |
D | statfs.c | 53 static int statfs_by_dentry(struct dentry *dentry, struct kstatfs *buf) in statfs_by_dentry() argument 60 memset(buf, 0, sizeof(*buf)); in statfs_by_dentry() 64 retval = dentry->d_sb->s_op->statfs(dentry, buf); in statfs_by_dentry() 65 if (retval == 0 && buf->f_frsize == 0) in statfs_by_dentry() 66 buf->f_frsize = buf->f_bsize; in statfs_by_dentry() 84 int vfs_statfs(const struct path *path, struct kstatfs *buf) in vfs_statfs() argument 88 error = statfs_by_dentry(path->dentry, buf); in vfs_statfs() 90 buf->f_flags = calculate_f_flags(path->mnt); in vfs_statfs() 126 struct statfs buf; in do_statfs_native() local 128 if (sizeof(buf) == sizeof(*st)) in do_statfs_native() [all …]
|
D | readdir.c | 146 struct readdir_callback *buf = in fillonedir() local 151 if (buf->result) in fillonedir() 155 buf->result = -EOVERFLOW; in fillonedir() 158 buf->result++; in fillonedir() 159 dirent = buf->dirent; in fillonedir() 172 buf->result = -EFAULT; in fillonedir() 181 struct readdir_callback buf = { in SYSCALL_DEFINE3() local 189 error = iterate_dir(f.file, &buf.ctx); in SYSCALL_DEFINE3() 190 if (buf.result) in SYSCALL_DEFINE3() 191 error = buf.result; in SYSCALL_DEFINE3() [all …]
|
D | seq_file.c | 103 if (!m->buf) { in traverse() 104 m->buf = seq_buf_alloc(m->size = PAGE_SIZE); in traverse() 105 if (!m->buf) in traverse() 138 kvfree(m->buf); in traverse() 140 m->buf = seq_buf_alloc(m->size <<= 1); in traverse() 141 return !m->buf ? -ENOMEM : -EAGAIN; in traverse() 153 ssize_t seq_read(struct file *file, char __user *buf, size_t size, loff_t *ppos) in seq_read() argument 203 if (!m->buf) { in seq_read() 204 m->buf = seq_buf_alloc(m->size = PAGE_SIZE); in seq_read() 205 if (!m->buf) in seq_read() [all …]
|
D | pipe.c | 123 struct pipe_buffer *buf) in anon_pipe_buf_release() argument 125 struct page *page = buf->page; in anon_pipe_buf_release() 139 struct pipe_buffer *buf) in anon_pipe_buf_steal() argument 141 struct page *page = buf->page; in anon_pipe_buf_steal() 164 struct pipe_buffer *buf) in generic_pipe_buf_steal() argument 166 struct page *page = buf->page; in generic_pipe_buf_steal() 192 bool generic_pipe_buf_get(struct pipe_inode_info *pipe, struct pipe_buffer *buf) in generic_pipe_buf_get() argument 194 return try_get_page(buf->page); in generic_pipe_buf_get() 208 struct pipe_buffer *buf) in generic_pipe_buf_confirm() argument 223 struct pipe_buffer *buf) in generic_pipe_buf_release() argument [all …]
|
D | splice.c | 48 struct pipe_buffer *buf) in page_cache_pipe_buf_steal() argument 50 struct page *page = buf->page; in page_cache_pipe_buf_steal() 78 buf->flags |= PIPE_BUF_FLAG_LRU; in page_cache_pipe_buf_steal() 93 struct pipe_buffer *buf) in page_cache_pipe_buf_release() argument 95 put_page(buf->page); in page_cache_pipe_buf_release() 96 buf->flags &= ~PIPE_BUF_FLAG_LRU; in page_cache_pipe_buf_release() 104 struct pipe_buffer *buf) in page_cache_pipe_buf_confirm() argument 106 struct page *page = buf->page; in page_cache_pipe_buf_confirm() 149 struct pipe_buffer *buf) in user_page_pipe_buf_steal() argument 151 if (!(buf->flags & PIPE_BUF_FLAG_GIFT)) in user_page_pipe_buf_steal() [all …]
|
D | d_path.c | 178 char *buf, int buflen) in __d_path() argument 180 char *res = buf + buflen; in __d_path() 194 char *buf, int buflen) in d_absolute_path() argument 197 char *res = buf + buflen; in d_absolute_path() 215 char **buf, int *buflen) in path_with_deleted() argument 217 prepend(buf, buflen, "\0", 1); in path_with_deleted() 219 int error = prepend(buf, buflen, " (deleted)", 10); in path_with_deleted() 224 return prepend_path(path, root, buf, buflen); in path_with_deleted() 258 char *d_path(const struct path *path, char *buf, int buflen) in d_path() argument 260 char *res = buf + buflen; in d_path() [all …]
|
/fs/ocfs2/dlm/ |
D | dlmdebug.c | 32 static int stringify_lockname(const char *lockname, int locklen, char *buf, 85 char buf[DLM_LOCKID_NAME_MAX]; in __dlm_print_one_lock_resource() local 90 buf, sizeof(buf)); in __dlm_print_one_lock_resource() 92 buf, res->owner, res->state); in __dlm_print_one_lock_resource() 236 static int stringify_lockname(const char *lockname, int locklen, char *buf, in stringify_lockname() argument 247 out += snprintf(buf + out, len - out, "%.*s%08x", in stringify_lockname() 251 out += snprintf(buf + out, len - out, "%.*s", in stringify_lockname() 257 char *buf, int len) in stringify_nodemap() argument 263 out += snprintf(buf + out, len - out, "%d ", i); in stringify_nodemap() 268 static int dump_mle(struct dlm_master_list_entry *mle, char *buf, int len) in dump_mle() argument [all …]
|
/fs/nilfs2/ |
D | sysfs.c | 22 #define NILFS_SHOW_TIME(time_t_val, buf) ({ \ argument 28 count = scnprintf(buf, PAGE_SIZE, \ 37 struct attribute *attr, char *buf) \ 45 return a->show ? a->show(a, nilfs, buf) : 0; \ 49 const char *buf, size_t len) \ 57 return a->store ? a->store(a, nilfs, buf, len) : 0; \ 111 struct nilfs_root *root, char *buf) in nilfs_snapshot_inodes_count_show() argument 113 return snprintf(buf, PAGE_SIZE, "%llu\n", in nilfs_snapshot_inodes_count_show() 119 struct nilfs_root *root, char *buf) in nilfs_snapshot_blocks_count_show() argument 121 return snprintf(buf, PAGE_SIZE, "%llu\n", in nilfs_snapshot_blocks_count_show() [all …]
|
/fs/xfs/ |
D | xfs_itable.c | 35 struct xfs_bulkstat *buf; member 64 struct xfs_bulkstat *buf = bc->buf; in xfs_bulkstat_one_int() local 87 buf->bs_projectid = xfs_get_projid(ip); in xfs_bulkstat_one_int() 88 buf->bs_ino = ino; in xfs_bulkstat_one_int() 89 buf->bs_uid = dic->di_uid; in xfs_bulkstat_one_int() 90 buf->bs_gid = dic->di_gid; in xfs_bulkstat_one_int() 91 buf->bs_size = dic->di_size; in xfs_bulkstat_one_int() 93 buf->bs_nlink = inode->i_nlink; in xfs_bulkstat_one_int() 94 buf->bs_atime = inode->i_atime.tv_sec; in xfs_bulkstat_one_int() 95 buf->bs_atime_nsec = inode->i_atime.tv_nsec; in xfs_bulkstat_one_int() [all …]
|
D | xfs_sysfs.c | 18 ssize_t (*show)(struct kobject *kobject, char *buf); 19 ssize_t (*store)(struct kobject *kobject, const char *buf, 42 char *buf) in xfs_sysfs_object_show() argument 46 return xfs_attr->show ? xfs_attr->show(kobject, buf) : 0; in xfs_sysfs_object_show() 53 const char *buf, in xfs_sysfs_object_store() argument 58 return xfs_attr->store ? xfs_attr->store(kobject, buf, count) : 0; in xfs_sysfs_object_store() 82 const char *buf, in bug_on_assert_store() argument 88 ret = kstrtoint(buf, 0, &val); in bug_on_assert_store() 105 char *buf) in bug_on_assert_show() argument 107 return snprintf(buf, PAGE_SIZE, "%d\n", xfs_globals.bug_on_assert ? 1 : 0); in bug_on_assert_show() [all …]
|
/fs/quota/ |
D | quota_tree.c | 52 char *buf = kmalloc(size, GFP_NOFS); in getdqbuf() local 53 if (!buf) in getdqbuf() 56 return buf; in getdqbuf() 59 static ssize_t read_blk(struct qtree_mem_dqinfo *info, uint blk, char *buf) in read_blk() argument 63 memset(buf, 0, info->dqi_usable_bs); in read_blk() 64 return sb->s_op->quota_read(sb, info->dqi_type, buf, in read_blk() 68 static ssize_t write_blk(struct qtree_mem_dqinfo *info, uint blk, char *buf) in write_blk() argument 73 ret = sb->s_op->quota_write(sb, info->dqi_type, buf, in write_blk() 86 char *buf = getdqbuf(info->dqi_usable_bs); in get_free_dqblk() local 87 struct qt_disk_dqdbheader *dh = (struct qt_disk_dqdbheader *)buf; in get_free_dqblk() [all …]
|
/fs/gfs2/ |
D | sys.c | 37 char *buf) in gfs2_attr_show() argument 41 return a->show ? a->show(sdp, buf) : 0; in gfs2_attr_show() 45 const char *buf, size_t len) in gfs2_attr_store() argument 49 return a->store ? a->store(sdp, buf, len) : len; in gfs2_attr_store() 60 static ssize_t id_show(struct gfs2_sbd *sdp, char *buf) in id_show() argument 62 return snprintf(buf, PAGE_SIZE, "%u:%u\n", in id_show() 66 static ssize_t fsname_show(struct gfs2_sbd *sdp, char *buf) in fsname_show() argument 68 return snprintf(buf, PAGE_SIZE, "%s\n", sdp->sd_fsname); in fsname_show() 71 static ssize_t uuid_show(struct gfs2_sbd *sdp, char *buf) in uuid_show() argument 75 buf[0] = '\0'; in uuid_show() [all …]
|
/fs/hostfs/ |
D | hostfs_user.c | 21 static void stat64_to_hostfs(const struct stat64 *buf, struct hostfs_stat *p) in stat64_to_hostfs() argument 23 p->ino = buf->st_ino; in stat64_to_hostfs() 24 p->mode = buf->st_mode; in stat64_to_hostfs() 25 p->nlink = buf->st_nlink; in stat64_to_hostfs() 26 p->uid = buf->st_uid; in stat64_to_hostfs() 27 p->gid = buf->st_gid; in stat64_to_hostfs() 28 p->size = buf->st_size; in stat64_to_hostfs() 29 p->atime.tv_sec = buf->st_atime; in stat64_to_hostfs() 31 p->ctime.tv_sec = buf->st_ctime; in stat64_to_hostfs() 33 p->mtime.tv_sec = buf->st_mtime; in stat64_to_hostfs() [all …]
|
/fs/nfsd/ |
D | nfsctl.c | 64 static ssize_t write_filehandle(struct file *file, char *buf, size_t size); 65 static ssize_t write_unlock_ip(struct file *file, char *buf, size_t size); 66 static ssize_t write_unlock_fs(struct file *file, char *buf, size_t size); 67 static ssize_t write_threads(struct file *file, char *buf, size_t size); 68 static ssize_t write_pool_threads(struct file *file, char *buf, size_t size); 69 static ssize_t write_versions(struct file *file, char *buf, size_t size); 70 static ssize_t write_ports(struct file *file, char *buf, size_t size); 71 static ssize_t write_maxblksize(struct file *file, char *buf, size_t size); 72 static ssize_t write_maxconn(struct file *file, char *buf, size_t size); 74 static ssize_t write_leasetime(struct file *file, char *buf, size_t size); [all …]
|
/fs/ext4/ |
D | hash.c | 16 static void TEA_transform(__u32 buf[4], __u32 const in[]) in TEA_transform() 19 __u32 b0 = buf[0], b1 = buf[1]; in TEA_transform() 29 buf[0] += b0; in TEA_transform() 30 buf[1] += b1; in TEA_transform() 53 static __u32 half_md4_transform(__u32 buf[4], __u32 const in[8]) in half_md4_transform() 55 __u32 a = buf[0], b = buf[1], c = buf[2], d = buf[3]; in half_md4_transform() 87 buf[0] += a; in half_md4_transform() 88 buf[1] += b; in half_md4_transform() 89 buf[2] += c; in half_md4_transform() 90 buf[3] += d; in half_md4_transform() [all …]
|
D | sysfs.c | 55 static ssize_t session_write_kbytes_show(struct ext4_sb_info *sbi, char *buf) in session_write_kbytes_show() argument 60 return snprintf(buf, PAGE_SIZE, "0\n"); in session_write_kbytes_show() 61 return snprintf(buf, PAGE_SIZE, "%lu\n", in session_write_kbytes_show() 67 static ssize_t lifetime_write_kbytes_show(struct ext4_sb_info *sbi, char *buf) in lifetime_write_kbytes_show() argument 72 return snprintf(buf, PAGE_SIZE, "0\n"); in lifetime_write_kbytes_show() 73 return snprintf(buf, PAGE_SIZE, "%llu\n", in lifetime_write_kbytes_show() 81 const char *buf, size_t count) in inode_readahead_blks_store() argument 86 ret = kstrtoul(skip_spaces(buf), 0, &t); in inode_readahead_blks_store() 98 const char *buf, size_t count) in reserved_clusters_store() argument 105 ret = kstrtoull(skip_spaces(buf), 0, &val); in reserved_clusters_store() [all …]
|
/fs/squashfs/ |
D | xz_wrapper.c | 26 struct xz_buf buf; member 128 stream->buf.in_pos = 0; in squashfs_xz_uncompress() 129 stream->buf.in_size = 0; in squashfs_xz_uncompress() 130 stream->buf.out_pos = 0; in squashfs_xz_uncompress() 131 stream->buf.out_size = PAGE_SIZE; in squashfs_xz_uncompress() 132 stream->buf.out = squashfs_first_page(output); in squashfs_xz_uncompress() 135 if (stream->buf.in_pos == stream->buf.in_size && k < b) { in squashfs_xz_uncompress() 138 stream->buf.in = bh[k]->b_data + offset; in squashfs_xz_uncompress() 139 stream->buf.in_size = avail; in squashfs_xz_uncompress() 140 stream->buf.in_pos = 0; in squashfs_xz_uncompress() [all …]
|
/fs/ubifs/ |
D | scan.c | 28 static int scan_padding_bytes(void *buf, int len) in scan_padding_bytes() argument 31 uint8_t *p = buf; in scan_padding_bytes() 57 int ubifs_scan_a_node(const struct ubifs_info *c, void *buf, int len, int lnum, in ubifs_scan_a_node() argument 60 struct ubifs_ch *ch = buf; in ubifs_scan_a_node() 71 return scan_padding_bytes(buf, len); in ubifs_scan_a_node() 79 if (ubifs_check_node(c, buf, lnum, offs, quiet, 1)) in ubifs_scan_a_node() 83 struct ubifs_pad_node *pad = buf; in ubifs_scan_a_node() 139 sleb->buf = sbuf; in ubifs_start_scan() 182 void *buf, int offs) in ubifs_add_snod() argument 184 struct ubifs_ch *ch = buf; in ubifs_add_snod() [all …]
|
D | io.c | 87 int ubifs_leb_read(const struct ubifs_info *c, int lnum, void *buf, int offs, in ubifs_leb_read() argument 92 err = ubi_read(c->ubi, lnum, buf, offs, len); in ubifs_leb_read() 105 int ubifs_leb_write(struct ubifs_info *c, int lnum, const void *buf, int offs, in ubifs_leb_write() argument 114 err = ubi_leb_write(c->ubi, lnum, buf, offs, len); in ubifs_leb_write() 116 err = dbg_leb_write(c, lnum, buf, offs, len); in ubifs_leb_write() 126 int ubifs_leb_change(struct ubifs_info *c, int lnum, const void *buf, int len) in ubifs_leb_change() argument 134 err = ubi_leb_change(c->ubi, lnum, buf, len); in ubifs_leb_change() 136 err = dbg_leb_change(c, lnum, buf, len); in ubifs_leb_change() 225 int ubifs_check_node(const struct ubifs_info *c, const void *buf, int lnum, in ubifs_check_node() argument 230 const struct ubifs_ch *ch = buf; in ubifs_check_node() [all …]
|
D | recovery.c | 50 static int is_empty(void *buf, int len) in is_empty() argument 52 uint8_t *p = buf; in is_empty() 69 static int first_non_ff(void *buf, int len) in first_non_ff() argument 71 uint8_t *p = buf; in first_non_ff() 102 void *sbuf, *buf; in get_master_node() local 114 buf = sbuf; in get_master_node() 117 struct ubifs_ch *ch = buf; in get_master_node() 122 buf += sz; in get_master_node() 130 buf -= sz; in get_master_node() 132 ret = ubifs_scan_a_node(c, buf, len, lnum, offs, 1); in get_master_node() [all …]
|
/fs/romfs/ |
D | storage.c | 24 void *buf, size_t buflen) in romfs_mtd_read() argument 29 ret = ROMFS_MTD_READ(sb, pos, buflen, &rlen, buf); in romfs_mtd_read() 41 u_char buf[16], *p; in romfs_mtd_strnlen() local 48 ret = ROMFS_MTD_READ(sb, pos, segment, &len, buf); in romfs_mtd_strnlen() 51 p = memchr(buf, 0, len); in romfs_mtd_strnlen() 53 return n + (p - buf); in romfs_mtd_strnlen() 69 u_char buf[17]; in romfs_mtd_strcmp() local 75 buf[0] = 0xff; in romfs_mtd_strcmp() 79 ret = ROMFS_MTD_READ(sb, pos, segment, &len, buf); in romfs_mtd_strcmp() 83 if (memcmp(buf, str, len) != 0) in romfs_mtd_strcmp() [all …]
|
/fs/f2fs/ |
D | hash.c | 26 static void TEA_transform(unsigned int buf[4], unsigned int const in[]) in TEA_transform() 29 __u32 b0 = buf[0], b1 = buf[1]; in TEA_transform() 39 buf[0] += b0; in TEA_transform() 40 buf[1] += b1; in TEA_transform() 44 unsigned int *buf, int num) in str2hashbuf() argument 60 *buf++ = val; in str2hashbuf() 66 *buf++ = val; in str2hashbuf() 68 *buf++ = pad; in str2hashbuf() 77 __u32 in[8], buf[4]; in __f2fs_dentry_hash() local 89 buf[0] = 0x67452301; in __f2fs_dentry_hash() [all …]
|
D | sysfs.c | 66 struct f2fs_sb_info *sbi, char *buf) in dirty_segments_show() argument 68 return snprintf(buf, PAGE_SIZE, "%llu\n", in dirty_segments_show() 73 struct f2fs_sb_info *sbi, char *buf) in unusable_show() argument 81 return snprintf(buf, PAGE_SIZE, "%llu\n", in unusable_show() 86 struct f2fs_sb_info *sbi, char *buf) in encoding_show() argument 90 return snprintf(buf, PAGE_SIZE, "%s (%d.%d.%d)\n", in encoding_show() 96 return snprintf(buf, PAGE_SIZE, "(none)"); in encoding_show() 100 struct f2fs_sb_info *sbi, char *buf) in lifetime_write_kbytes_show() argument 105 return snprintf(buf, PAGE_SIZE, "0\n"); in lifetime_write_kbytes_show() 107 return snprintf(buf, PAGE_SIZE, "%llu\n", in lifetime_write_kbytes_show() [all …]
|
/fs/cifs/ |
D | smb2file.c | 39 __u32 *oplock, FILE_ALL_INFO *buf) in smb2_open_file() argument 90 if (buf) { in smb2_open_file() 106 move_smb2_info_to_cifs(buf, smb2_data); in smb2_open_file() 122 struct smb2_lock_element *buf, *cur; in smb2_unlock_range() local 142 buf = kcalloc(max_num, sizeof(struct smb2_lock_element), GFP_KERNEL); in smb2_unlock_range() 143 if (!buf) in smb2_unlock_range() 146 cur = buf; in smb2_unlock_range() 178 current->tgid, num, buf); in smb2_unlock_range() 194 cur = buf; in smb2_unlock_range() 202 num, buf); in smb2_unlock_range() [all …]
|
/fs/pstore/ |
D | platform.c | 291 char *buf; in allocate_buf_for_compression() local 313 buf = kmalloc(size, GFP_KERNEL); in allocate_buf_for_compression() 314 if (!buf) { in allocate_buf_for_compression() 322 kfree(buf); in allocate_buf_for_compression() 331 big_oops_buf = buf; in allocate_buf_for_compression() 363 memcpy(psinfo->buf, big_oops_buf, hsize); in copy_kmsg_to_buffer() 364 memcpy(psinfo->buf + hsize, big_oops_buf + diff, in copy_kmsg_to_buffer() 368 memcpy(psinfo->buf, big_oops_buf, total_len); in copy_kmsg_to_buffer() 425 record.buf = psinfo->buf; in pstore_dump() 431 dst = psinfo->buf; in pstore_dump() [all …]
|