Home
last modified time | relevance | path

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

123456789

/Linux-v6.1/net/ipv6/
Dip6_flowlabel.c60 #define for_each_fl_rcu(hash, fl) \ argument
61 for (fl = rcu_dereference_bh(fl_ht[(hash)]); \
62 fl != NULL; \
63 fl = rcu_dereference_bh(fl->next))
64 #define for_each_fl_continue_rcu(fl) \ argument
65 for (fl = rcu_dereference_bh(fl->next); \
66 fl != NULL; \
67 fl = rcu_dereference_bh(fl->next))
76 struct ip6_flowlabel *fl; in __fl_lookup() local
78 for_each_fl_rcu(FL_HASH(label), fl) { in __fl_lookup()
[all …]
/Linux-v6.1/fs/
Dlocks.c72 #define IS_POSIX(fl) (fl->fl_flags & FL_POSIX) argument
73 #define IS_FLOCK(fl) (fl->fl_flags & FL_FLOCK) argument
74 #define IS_LEASE(fl) (fl->fl_flags & (FL_LEASE|FL_DELEG|FL_LAYOUT)) argument
75 #define IS_OFDLCK(fl) (fl->fl_flags & FL_OFDLCK) argument
76 #define IS_REMOTELCK(fl) (fl->fl_pid <= 0) argument
78 static bool lease_breaking(struct file_lock *fl) in lease_breaking() argument
80 return fl->fl_flags & (FL_UNLOCK_PENDING | FL_DOWNGRADE_PENDING); in lease_breaking()
83 static int target_leasetype(struct file_lock *fl) in target_leasetype() argument
85 if (fl->fl_flags & FL_UNLOCK_PENDING) in target_leasetype()
87 if (fl->fl_flags & FL_DOWNGRADE_PENDING) in target_leasetype()
[all …]
/Linux-v6.1/include/trace/events/
Dfilelock.h63 TP_PROTO(struct inode *inode, struct file_lock *fl, int ret),
65 TP_ARGS(inode, fl, ret),
68 __field(struct file_lock *, fl)
82 __entry->fl = fl ? fl : NULL;
85 __entry->fl_blocker = fl ? fl->fl_blocker : NULL;
86 __entry->fl_owner = fl ? fl->fl_owner : NULL;
87 __entry->fl_pid = fl ? fl->fl_pid : 0;
88 __entry->fl_flags = fl ? fl->fl_flags : 0;
89 __entry->fl_type = fl ? fl->fl_type : 0;
90 __entry->fl_start = fl ? fl->fl_start : 0;
[all …]
/Linux-v6.1/fs/lockd/
Dclntproc.c31 static void nlmclnt_locks_init_private(struct file_lock *fl, struct nlm_host *host);
126 static void nlmclnt_setlockargs(struct nlm_rqst *req, struct file_lock *fl) in nlmclnt_setlockargs() argument
133 memcpy(&lock->fh, NFS_FH(locks_inode(fl->fl_file)), sizeof(struct nfs_fh)); in nlmclnt_setlockargs()
137 (unsigned int)fl->fl_u.nfs_fl.owner->pid, in nlmclnt_setlockargs()
139 lock->svid = fl->fl_u.nfs_fl.owner->pid; in nlmclnt_setlockargs()
140 lock->fl.fl_start = fl->fl_start; in nlmclnt_setlockargs()
141 lock->fl.fl_end = fl->fl_end; in nlmclnt_setlockargs()
142 lock->fl.fl_type = fl->fl_type; in nlmclnt_setlockargs()
147 WARN_ON_ONCE(req->a_args.lock.fl.fl_ops != NULL); in nlmclnt_release_lockargs()
158 int nlmclnt_proc(struct nlm_host *host, int cmd, struct file_lock *fl, void *data) in nlmclnt_proc() argument
[all …]
Dsvclock.c149 struct file_lock *fl; in nlmsvc_lookup_block() local
152 file, lock->fl.fl_pid, in nlmsvc_lookup_block()
153 (long long)lock->fl.fl_start, in nlmsvc_lookup_block()
154 (long long)lock->fl.fl_end, lock->fl.fl_type); in nlmsvc_lookup_block()
156 fl = &block->b_call->a_args.lock.fl; in nlmsvc_lookup_block()
158 block->b_file, fl->fl_pid, in nlmsvc_lookup_block()
159 (long long)fl->fl_start, in nlmsvc_lookup_block()
160 (long long)fl->fl_end, fl->fl_type, in nlmsvc_lookup_block()
162 if (block->b_file == file && nlm_compare_locks(fl, &lock->fl)) { in nlmsvc_lookup_block()
240 call->a_args.lock.fl.fl_flags |= FL_SLEEP; in nlmsvc_create_block()
[all …]
Dxdr.c74 struct file_lock *fl = &lock->fl; in svcxdr_decode_lock() local
90 locks_init_lock(fl); in svcxdr_decode_lock()
91 fl->fl_flags = FL_POSIX; in svcxdr_decode_lock()
92 fl->fl_type = F_RDLCK; in svcxdr_decode_lock()
94 fl->fl_start = s32_to_loff_t(start); in svcxdr_decode_lock()
96 fl->fl_end = OFFSET_MAX; in svcxdr_decode_lock()
98 fl->fl_end = s32_to_loff_t(end); in svcxdr_decode_lock()
106 const struct file_lock *fl = &lock->fl; in svcxdr_encode_holder() local
110 if (xdr_stream_encode_bool(xdr, fl->fl_type != F_RDLCK) < 0) in svcxdr_encode_holder()
116 start = loff_t_to_s32(fl->fl_start); in svcxdr_encode_holder()
[all …]
Dxdr4.c65 struct file_lock *fl = &lock->fl; in svcxdr_decode_lock() local
80 locks_init_lock(fl); in svcxdr_decode_lock()
81 fl->fl_flags = FL_POSIX; in svcxdr_decode_lock()
82 fl->fl_type = F_RDLCK; in svcxdr_decode_lock()
90 const struct file_lock *fl = &lock->fl; in svcxdr_encode_holder() local
94 if (xdr_stream_encode_bool(xdr, fl->fl_type != F_RDLCK) < 0) in svcxdr_encode_holder()
100 start = loff_t_to_s64(fl->fl_start); in svcxdr_encode_holder()
101 if (fl->fl_end == OFFSET_MAX) in svcxdr_encode_holder()
104 len = loff_t_to_s64(fl->fl_end - fl->fl_start + 1); in svcxdr_encode_holder()
151 argp->lock.fl.fl_type = F_WRLCK; in nlm4svc_decode_testargs()
[all …]
Dclntlock.c100 struct nlm_wait *nlmclnt_prepare_block(struct nlm_host *host, struct file_lock *fl) in nlmclnt_prepare_block() argument
107 block->b_lock = fl; in nlmclnt_prepare_block()
166 const struct file_lock *fl = &lock->fl; in nlmclnt_grant() local
179 if (fl_blocked->fl_start != fl->fl_start) in nlmclnt_grant()
181 if (fl_blocked->fl_end != fl->fl_end) in nlmclnt_grant()
234 struct file_lock *fl, *next; in reclaimer() local
260 list_for_each_entry_safe(fl, next, &host->h_reclaim, fl_u.nfs_fl.list) { in reclaimer()
261 list_del_init(&fl->fl_u.nfs_fl.list); in reclaimer()
271 if (nlmclnt_reclaim(host, fl, req) != 0) in reclaimer()
273 list_add_tail(&fl->fl_u.nfs_fl.list, &host->h_granted); in reclaimer()
Dclnt4xdr.c68 const struct file_lock *fl = &lock->fl; in nlm4_compute_offsets() local
70 *l_offset = loff_t_to_s64(fl->fl_start); in nlm4_compute_offsets()
71 if (fl->fl_end == OFFSET_MAX) in nlm4_compute_offsets()
74 *l_len = loff_t_to_s64(fl->fl_end - fl->fl_start + 1); in nlm4_compute_offsets()
246 encode_bool(xdr, lock->fl.fl_type == F_RDLCK); in encode_nlm4_holder()
259 struct file_lock *fl = &lock->fl; in decode_nlm4_holder() local
267 locks_init_lock(fl); in decode_nlm4_holder()
274 fl->fl_pid = (pid_t)lock->svid; in decode_nlm4_holder()
284 fl->fl_flags = FL_POSIX; in decode_nlm4_holder()
285 fl->fl_type = exclusive != 0 ? F_WRLCK : F_RDLCK; in decode_nlm4_holder()
[all …]
/Linux-v6.1/fs/afs/
Dflock.c17 static void afs_fl_copy_lock(struct file_lock *new, struct file_lock *fl);
18 static void afs_fl_release_private(struct file_lock *fl);
452 static int afs_do_setlk(struct file *file, struct file_lock *fl) in afs_do_setlk() argument
467 fl->fl_start, fl->fl_end, fl->fl_type, mode); in afs_do_setlk()
469 fl->fl_ops = &afs_lock_ops; in afs_do_setlk()
470 INIT_LIST_HEAD(&fl->fl_u.afs.link); in afs_do_setlk()
471 fl->fl_u.afs.state = AFS_LOCK_PENDING; in afs_do_setlk()
473 partial = (fl->fl_start != 0 || fl->fl_end != OFFSET_MAX); in afs_do_setlk()
474 type = (fl->fl_type == F_RDLCK) ? AFS_LOCK_READ : AFS_LOCK_WRITE; in afs_do_setlk()
482 trace_afs_flock_op(vnode, fl, afs_flock_op_set_lock); in afs_do_setlk()
[all …]
/Linux-v6.1/fs/ceph/
Dlocks.c41 static void ceph_fl_release_lock(struct file_lock *fl) in ceph_fl_release_lock() argument
43 struct ceph_file_info *fi = fl->fl_file->private_data; in ceph_fl_release_lock()
44 struct inode *inode = file_inode(fl->fl_file); in ceph_fl_release_lock()
64 int cmd, u8 wait, struct file_lock *fl) in ceph_lock_message() argument
79 fl->fl_ops = &ceph_fl_lock_ops; in ceph_lock_message()
80 fl->fl_ops->fl_copy_lock(fl, NULL); in ceph_lock_message()
94 if (LLONG_MAX == fl->fl_end) in ceph_lock_message()
97 length = fl->fl_end - fl->fl_start + 1; in ceph_lock_message()
99 owner = secure_addr(fl->fl_owner); in ceph_lock_message()
103 (int)operation, owner, (u64)fl->fl_pid, fl->fl_start, length, in ceph_lock_message()
[all …]
Dutil.c31 void ceph_file_layout_from_legacy(struct ceph_file_layout *fl, in ceph_file_layout_from_legacy() argument
34 fl->stripe_unit = le32_to_cpu(legacy->fl_stripe_unit); in ceph_file_layout_from_legacy()
35 fl->stripe_count = le32_to_cpu(legacy->fl_stripe_count); in ceph_file_layout_from_legacy()
36 fl->object_size = le32_to_cpu(legacy->fl_object_size); in ceph_file_layout_from_legacy()
37 fl->pool_id = le32_to_cpu(legacy->fl_pg_pool); in ceph_file_layout_from_legacy()
38 if (fl->pool_id == 0 && fl->stripe_unit == 0 && in ceph_file_layout_from_legacy()
39 fl->stripe_count == 0 && fl->object_size == 0) in ceph_file_layout_from_legacy()
40 fl->pool_id = -1; in ceph_file_layout_from_legacy()
43 void ceph_file_layout_to_legacy(struct ceph_file_layout *fl, in ceph_file_layout_to_legacy() argument
46 legacy->fl_stripe_unit = cpu_to_le32(fl->stripe_unit); in ceph_file_layout_to_legacy()
[all …]
/Linux-v6.1/fs/dlm/
Dplock.c23 void *fl; member
26 int (*callback)(struct file_lock *fl, int result);
105 int cmd, struct file_lock *fl) in dlm_posix_lock() argument
123 op->info.pid = fl->fl_pid; in dlm_posix_lock()
124 op->info.ex = (fl->fl_type == F_WRLCK); in dlm_posix_lock()
128 op->info.start = fl->fl_start; in dlm_posix_lock()
129 op->info.end = fl->fl_end; in dlm_posix_lock()
131 if (fl->fl_lmops && fl->fl_lmops->lm_grant) { in dlm_posix_lock()
141 op->info.owner = (__u64) fl->fl_pid; in dlm_posix_lock()
142 op_data->callback = fl->fl_lmops->lm_grant; in dlm_posix_lock()
[all …]
/Linux-v6.1/include/linux/
Dthread_info.h149 #define set_syscall_work(fl) \ argument
150 set_bit(SYSCALL_WORK_BIT_##fl, &current_thread_info()->syscall_work)
151 #define test_syscall_work(fl) \ argument
152 test_bit(SYSCALL_WORK_BIT_##fl, &current_thread_info()->syscall_work)
153 #define clear_syscall_work(fl) \ argument
154 clear_bit(SYSCALL_WORK_BIT_##fl, &current_thread_info()->syscall_work)
156 #define set_task_syscall_work(t, fl) \ argument
157 set_bit(SYSCALL_WORK_BIT_##fl, &task_thread_info(t)->syscall_work)
158 #define test_task_syscall_work(t, fl) \ argument
159 test_bit(SYSCALL_WORK_BIT_##fl, &task_thread_info(t)->syscall_work)
[all …]
/Linux-v6.1/drivers/misc/
Dfastrpc.c179 struct fastrpc_user *fl; member
201 struct fastrpc_user *fl; member
230 struct fastrpc_user *fl; member
306 &(map->fl->cctx->vmperms[0].vmid), &perm, 1); in fastrpc_free_map()
308 dev_err(map->fl->sctx->dev, "Failed to assign memory phys 0x%llx size 0x%llx err %d", in fastrpc_free_map()
335 static int fastrpc_map_lookup(struct fastrpc_user *fl, int fd, in fastrpc_map_lookup() argument
340 mutex_lock(&fl->mutex); in fastrpc_map_lookup()
341 list_for_each_entry(map, &fl->maps, node) { in fastrpc_map_lookup()
344 mutex_unlock(&fl->mutex); in fastrpc_map_lookup()
348 mutex_unlock(&fl->mutex); in fastrpc_map_lookup()
[all …]
/Linux-v6.1/fs/nfs/filelayout/
Dfilelayout.c539 struct nfs4_filelayout_segment *fl, in filelayout_check_deviceid() argument
547 if (fl->dsaddr != NULL) in filelayout_check_deviceid()
551 d = nfs4_find_get_deviceid(NFS_SERVER(lo->plh_inode), &fl->deviceid, in filelayout_check_deviceid()
561 if (fl->first_stripe_index >= dsaddr->stripe_count) { in filelayout_check_deviceid()
563 __func__, fl->first_stripe_index); in filelayout_check_deviceid()
567 if ((fl->stripe_type == STRIPE_SPARSE && in filelayout_check_deviceid()
568 fl->num_fh > 1 && fl->num_fh != dsaddr->ds_num) || in filelayout_check_deviceid()
569 (fl->stripe_type == STRIPE_DENSE && in filelayout_check_deviceid()
570 fl->num_fh != dsaddr->stripe_count)) { in filelayout_check_deviceid()
572 __func__, fl->num_fh); in filelayout_check_deviceid()
[all …]
/Linux-v6.1/drivers/net/ethernet/chelsio/cxgb4vf/
Dsge.c247 static inline unsigned int fl_cap(const struct sge_fl *fl) in fl_cap() argument
249 return fl->size - FL_PER_EQ_UNIT; in fl_cap()
262 const struct sge_fl *fl) in fl_starving() argument
266 return fl->avail - fl->pend_cred <= s->fl_starve_thres; in fl_starving()
473 static void free_rx_bufs(struct adapter *adapter, struct sge_fl *fl, int n) in free_rx_bufs() argument
476 struct rx_sw_desc *sdesc = &fl->sdesc[fl->cidx]; in free_rx_bufs()
484 if (++fl->cidx == fl->size) in free_rx_bufs()
485 fl->cidx = 0; in free_rx_bufs()
486 fl->avail--; in free_rx_bufs()
503 static void unmap_rx_buf(struct adapter *adapter, struct sge_fl *fl) in unmap_rx_buf() argument
[all …]
/Linux-v6.1/fs/ocfs2/
Dlocks.c23 int cmd, struct file_lock *fl) in ocfs2_do_flock() argument
29 if (fl->fl_type == F_WRLCK) in ocfs2_do_flock()
71 ret = locks_lock_file_wait(file, fl); in ocfs2_do_flock()
81 static int ocfs2_do_funlock(struct file *file, int cmd, struct file_lock *fl) in ocfs2_do_funlock() argument
88 ret = locks_lock_file_wait(file, fl); in ocfs2_do_funlock()
97 int ocfs2_flock(struct file *file, int cmd, struct file_lock *fl) in ocfs2_flock() argument
102 if (!(fl->fl_flags & FL_FLOCK)) in ocfs2_flock()
107 return locks_lock_file_wait(file, fl); in ocfs2_flock()
109 if (fl->fl_type == F_UNLCK) in ocfs2_flock()
110 return ocfs2_do_funlock(file, cmd, fl); in ocfs2_flock()
[all …]
/Linux-v6.1/fs/9p/
Dvfs_file.c117 static int v9fs_file_lock(struct file *filp, int cmd, struct file_lock *fl) in v9fs_file_lock() argument
121 p9_debug(P9_DEBUG_VFS, "filp: %p lock: %p\n", filp, fl); in v9fs_file_lock()
123 if ((IS_SETLK(cmd) || IS_SETLKW(cmd)) && fl->fl_type != F_UNLCK) { in v9fs_file_lock()
131 static int v9fs_file_do_lock(struct file *filp, int cmd, struct file_lock *fl) in v9fs_file_do_lock() argument
143 BUG_ON((fl->fl_flags & FL_POSIX) != FL_POSIX); in v9fs_file_do_lock()
145 res = locks_lock_file_wait(filp, fl); in v9fs_file_do_lock()
152 switch (fl->fl_type) { in v9fs_file_do_lock()
163 flock.start = fl->fl_start; in v9fs_file_do_lock()
164 if (fl->fl_end == OFFSET_MAX) in v9fs_file_do_lock()
167 flock.length = fl->fl_end - fl->fl_start + 1; in v9fs_file_do_lock()
[all …]
/Linux-v6.1/fs/nfsd/
Dflexfilelayout.c30 struct pnfs_ff_layout *fl; in nfsd4_ff_proc_layoutget() local
38 fl = kzalloc(sizeof(*fl), GFP_KERNEL); in nfsd4_ff_proc_layoutget()
39 if (!fl) in nfsd4_ff_proc_layoutget()
41 args->lg_content = fl; in nfsd4_ff_proc_layoutget()
48 fl->flags = FF_FLAGS_NO_LAYOUTCOMMIT | FF_FLAGS_NO_IO_THRU_MDS | in nfsd4_ff_proc_layoutget()
54 fl->uid = make_kuid(&init_user_ns, u); in nfsd4_ff_proc_layoutget()
56 fl->uid = inode->i_uid; in nfsd4_ff_proc_layoutget()
57 fl->gid = inode->i_gid; in nfsd4_ff_proc_layoutget()
59 error = nfsd4_set_deviceid(&fl->deviceid, fhp, device_generation); in nfsd4_ff_proc_layoutget()
63 fl->fh.size = fhp->fh_handle.fh_size; in nfsd4_ff_proc_layoutget()
[all …]
Dflexfilelayoutxdr.c22 struct pnfs_ff_layout *fl = lgp->lg_content; in nfsd4_ff_encode_layoutget() local
33 fh_len = 4 + fl->fh.size; in nfsd4_ff_encode_layoutget()
35 uid.len = sprintf(uid.buf, "%u", from_kuid(&init_user_ns, fl->uid)); in nfsd4_ff_encode_layoutget()
36 gid.len = sprintf(gid.buf, "%u", from_kgid(&init_user_ns, fl->gid)); in nfsd4_ff_encode_layoutget()
57 p = xdr_encode_opaque_fixed(p, &fl->deviceid, in nfsd4_ff_encode_layoutget()
62 *p++ = cpu_to_be32(fl->stateid.si_generation); in nfsd4_ff_encode_layoutget()
63 p = xdr_encode_opaque_fixed(p, &fl->stateid.si_opaque, in nfsd4_ff_encode_layoutget()
67 p = xdr_encode_opaque(p, fl->fh.data, fl->fh.size); in nfsd4_ff_encode_layoutget()
72 *p++ = cpu_to_be32(fl->flags); in nfsd4_ff_encode_layoutget()
/Linux-v6.1/drivers/mtd/parsers/
Dredboot.c79 struct fis_list *fl = NULL, *tmp_fl; in parse_redboot_partitions() local
221 prev = &fl; in parse_redboot_partitions()
230 if (fl->img->flash_base) { in parse_redboot_partitions()
235 for (tmp_fl = fl; tmp_fl->next; tmp_fl = tmp_fl->next) { in parse_redboot_partitions()
259 if (fl->img->flash_base) { in parse_redboot_partitions()
261 parts[0].size = fl->img->flash_base; in parse_redboot_partitions()
267 parts[i].size = fl->img->size; in parse_redboot_partitions()
268 parts[i].offset = fl->img->flash_base; in parse_redboot_partitions()
271 strcpy(names, fl->img->name); in parse_redboot_partitions()
282 …if (fl->next && fl->img->flash_base + fl->img->size + master->erasesize <= fl->next->img->flash_ba… in parse_redboot_partitions()
[all …]
/Linux-v6.1/drivers/net/wireguard/
Dsocket.c23 struct flowi4 fl = { in send4() local
46 fl.fl4_sport = inet_sk(sock)->inet_sport; in send4()
49 rt = dst_cache_get_ip4(cache, &fl.saddr); in send4()
52 security_sk_classify_flow(sock, flowi4_to_flowi_common(&fl)); in send4()
54 fl.saddr, RT_SCOPE_HOST))) { in send4()
57 fl.saddr = 0; in send4()
61 rt = ip_route_output_flow(sock_net(sock), &fl, sock); in send4()
67 fl.saddr = 0; in send4()
72 rt = ip_route_output_flow(sock_net(sock), &fl, sock); in send4()
81 dst_cache_set_ip4(cache, &rt->dst, fl.saddr); in send4()
[all …]
/Linux-v6.1/fs/nfs/
Dfile.c690 do_getlk(struct file *filp, int cmd, struct file_lock *fl, int is_local) in do_getlk() argument
694 unsigned int saved_type = fl->fl_type; in do_getlk()
697 posix_test_lock(filp, fl); in do_getlk()
698 if (fl->fl_type != F_UNLCK) { in do_getlk()
702 fl->fl_type = saved_type; in do_getlk()
710 status = NFS_PROTO(inode)->lock(filp, cmd, fl); in do_getlk()
714 fl->fl_type = F_UNLCK; in do_getlk()
719 do_unlk(struct file *filp, int cmd, struct file_lock *fl, int is_local) in do_unlk() argument
739 if (status < 0 && !(fl->fl_flags & FL_CLOSE)) in do_unlk()
748 status = NFS_PROTO(inode)->lock(filp, cmd, fl); in do_unlk()
[all …]
/Linux-v6.1/net/l3mdev/
Dl3mdev.c247 int l3mdev_fib_rule_match(struct net *net, struct flowi *fl, in l3mdev_fib_rule_match() argument
254 if (!fl->flowi_l3mdev) in l3mdev_fib_rule_match()
259 dev = dev_get_by_index_rcu(net, fl->flowi_l3mdev); in l3mdev_fib_rule_match()
271 void l3mdev_update_flow(struct net *net, struct flowi *fl) in l3mdev_update_flow() argument
277 if (fl->flowi_oif) { in l3mdev_update_flow()
278 dev = dev_get_by_index_rcu(net, fl->flowi_oif); in l3mdev_update_flow()
280 if (!fl->flowi_l3mdev) in l3mdev_update_flow()
281 fl->flowi_l3mdev = l3mdev_master_ifindex_rcu(dev); in l3mdev_update_flow()
287 fl->flowi_oif = 0; in l3mdev_update_flow()
292 if (fl->flowi_iif > LOOPBACK_IFINDEX && !fl->flowi_l3mdev) { in l3mdev_update_flow()
[all …]

123456789