| /linux/net/sunrpc/ |
| H A D | sched.c | 45 static void rpc_release_task(struct rpc_task *task); 68 bool rpc_task_set_rpc_status(struct rpc_task *task, int rpc_status) in rpc_task_set_rpc_status() argument 70 if (cmpxchg(&task->tk_rpc_status, 0, rpc_status) == 0) in rpc_task_set_rpc_status() 76 rpc_task_timeout(const struct rpc_task *task) in rpc_task_timeout() argument 78 unsigned long timeout = READ_ONCE(task->tk_timeout); in rpc_task_timeout() 95 __rpc_disable_timer(struct rpc_wait_queue *queue, struct rpc_task *task) in __rpc_disable_timer() argument 97 if (list_empty(&task->u.tk_wait.timer_list)) in __rpc_disable_timer() 99 task->tk_timeout = 0; in __rpc_disable_timer() 100 list_del(&task->u.tk_wait.timer_list); in __rpc_disable_timer() 121 __rpc_add_timer(struct rpc_wait_queue *queue, struct rpc_task *task, in __rpc_add_timer() argument [all …]
|
| H A D | clnt.c | 53 static void call_start(struct rpc_task *task); 54 static void call_reserve(struct rpc_task *task); 55 static void call_reserveresult(struct rpc_task *task); 56 static void call_allocate(struct rpc_task *task); 57 static void call_encode(struct rpc_task *task); 58 static void call_decode(struct rpc_task *task); 59 static void call_bind(struct rpc_task *task); 60 static void call_bind_status(struct rpc_task *task); 61 static void call_transmit(struct rpc_task *task); 62 static void call_status(struct rpc_task *task); [all …]
|
| H A D | xprt.c | 75 static void xprt_request_init(struct rpc_task *task); 265 int xprt_reserve_xprt(struct rpc_xprt *xprt, struct rpc_task *task) in xprt_reserve_xprt() argument 267 struct rpc_rqst *req = task->tk_rqstp; in xprt_reserve_xprt() 270 if (task == xprt->snd_task) in xprt_reserve_xprt() 276 xprt->snd_task = task; in xprt_reserve_xprt() 279 trace_xprt_reserve_xprt(xprt, task); in xprt_reserve_xprt() 285 task->tk_status = -EAGAIN; in xprt_reserve_xprt() 286 if (RPC_IS_SOFT(task) || RPC_IS_SOFTCONN(task)) in xprt_reserve_xprt() 287 rpc_sleep_on_timeout(&xprt->sending, task, NULL, in xprt_reserve_xprt() 290 rpc_sleep_on(&xprt->sending, task, NULL); in xprt_reserve_xprt() [all …]
|
| /linux/tools/testing/selftests/bpf/progs/ |
| H A D | task_kfunc_failure.c | 20 static struct __tasks_kfunc_map_value *insert_lookup_task(struct task_struct *task) in insert_lookup_task() argument 24 status = tasks_kfunc_map_insert(task); in insert_lookup_task() 28 return tasks_kfunc_map_value_lookup(task); in insert_lookup_task() 33 int BPF_PROG(task_kfunc_acquire_untrusted, struct task_struct *task, u64 clone_flags) in BPF_PROG() argument 38 v = insert_lookup_task(task); in BPF_PROG() 43 acquired = bpf_task_acquire(v->task); in BPF_PROG() 54 int BPF_PROG(task_kfunc_acquire_fp, struct task_struct *task, u64 clone_flags) in BPF_PROG() argument 70 int BPF_PROG(task_kfunc_acquire_unsafe_kretprobe, struct task_struct *task, u64 clone_flags) in BPF_PROG() argument 75 acquired = bpf_task_acquire(task); in BPF_PROG() 85 int BPF_PROG(task_kfunc_acquire_unsafe_kretprobe_rcu, struct task_struct *task, u64 clone_flags) in BPF_PROG() argument [all …]
|
| H A D | task_kfunc_success.c | 24 struct task_struct *bpf_task_acquire___one(struct task_struct *task) __ksym __weak; 40 static int test_acquire_release(struct task_struct *task) in test_acquire_release() argument 58 acquired = bpf_task_acquire(task); in test_acquire_release() 68 int BPF_PROG(test_task_kfunc_flavor_relo, struct task_struct *task, u64 clone_flags) in BPF_PROG() argument 74 acquired = bpf_task_acquire___one(task); in BPF_PROG() 80 acquired = bpf_task_acquire___two(task, &fake_ctx); in BPF_PROG() 98 int BPF_PROG(test_task_kfunc_flavor_relo_not_found, struct task_struct *task, u64 clone_flags) in BPF_PROG() argument 112 int BPF_PROG(test_task_acquire_release_argument, struct task_struct *task, u64 clone_flags) in BPF_PROG() argument 117 return test_acquire_release(task); in BPF_PROG() 121 int BPF_PROG(test_task_acquire_release_current, struct task_struct *task, u64 clone_flags) in BPF_PROG() argument [all …]
|
| H A D | rcu_read_lock.c | 43 struct task_struct *task; in get_cgroup_id() local 46 task = bpf_get_current_task_btf(); in get_cgroup_id() 47 if (task->pid != target_pid) in get_cgroup_id() 52 cgroups = task->cgroups; in get_cgroup_id() 64 struct task_struct *task, *real_parent; in task_succ() local 68 task = bpf_get_current_task_btf(); in task_succ() 69 if (task->pid != target_pid) in task_succ() 74 real_parent = task->real_parent; in task_succ() 93 struct task_struct *task, *real_parent; in no_lock() local 96 task = bpf_get_current_task_btf(); in no_lock() [all …]
|
| H A D | verifier_global_ptr_args.c | 15 __weak int subprog_trusted_task_nullable(struct task_struct *task __arg_trusted __arg_nullable) in subprog_trusted_task_nullable() 17 if (!task) in subprog_trusted_task_nullable() 19 return task->pid + task->tgid; in subprog_trusted_task_nullable() 22 __weak int subprog_trusted_task_nullable_extra_layer(struct task_struct *task __arg_trusted __arg_nullable) in subprog_trusted_task_nullable_extra_layer() 24 return subprog_trusted_task_nullable(task) + subprog_trusted_task_nullable(NULL); in subprog_trusted_task_nullable_extra_layer() 59 __weak int subprog_trusted_task_nonnull(struct task_struct *task __arg_trusted) in subprog_trusted_task_nonnull() 61 return task->pid + task->tgid; in subprog_trusted_task_nonnull() 108 struct task_struct___local *task __arg_truste in subprog_nullable_task_flavor() 157 BPF_PROG(trusted_destroy_fail,struct task_struct * task,u64 clone_flags) BPF_PROG() argument 177 BPF_PROG(trusted_acq_rel,struct task_struct * task,u64 clone_flags) BPF_PROG() argument [all...] |
| /linux/kernel/livepatch/ |
| H A D | transition.c | 85 struct task_struct *g, *task; 122 for_each_process_thread(g, task) { in klp_complete_transition() 123 WARN_ON_ONCE(test_tsk_thread_flag(task, TIF_PATCH_PENDING)); in klp_complete_transition() 124 task->patch_state = KLP_TRANSITION_IDLE; in klp_complete_transition() 129 task = idle_task(cpu); in klp_complete_transition() 130 WARN_ON_ONCE(test_tsk_thread_flag(task, TIF_PATCH_PENDING)); in klp_complete_transition() 131 task->patch_state = KLP_TRANSITION_IDLE; in klp_complete_transition() 169 * Switch the patched state of the task to the set of functions in the target in klp_cancel_transition() 172 * NOTE: If task is not 'current', the caller must ensure the task i in klp_cancel_transition() 94 struct task_struct *g, *task; klp_complete_transition() local 184 klp_update_patch_state(struct task_struct * task) klp_update_patch_state() argument 263 klp_check_stack(struct task_struct * task,const char ** oldname) klp_check_stack() argument 293 klp_check_and_switch_task(struct task_struct * task,void * arg) klp_check_and_switch_task() argument 314 klp_try_switch_task(struct task_struct * task) klp_try_switch_task() argument 410 struct task_struct *g, *task; klp_send_signals() local 454 struct task_struct *g, *task; klp_try_complete_transition() local 532 struct task_struct *g, *task; klp_start_transition() local 575 struct task_struct *g, *task; klp_init_transition() local 651 struct task_struct *g, *task; klp_reverse_transition() local 730 struct task_struct *g, *task; klp_force_transition() local [all...] |
| /linux/drivers/scsi/libsas/ |
| H A D | sas_scsi_host.c | 38 static void sas_end_task(struct scsi_cmnd *sc, struct sas_task *task) in sas_end_task() argument 40 struct task_status_struct *ts = &task->task_status; in sas_end_task() 79 task->dev->port->ha->sas_ha_name); in sas_end_task() 97 sas_free_task(task); in sas_end_task() 100 static void sas_scsi_task_done(struct sas_task *task) in sas_scsi_task_done() argument 102 struct scsi_cmnd *sc = task->uldd_task; in sas_scsi_task_done() 103 struct domain_device *dev = task->dev; in sas_scsi_task_done() 109 task = NULL; in sas_scsi_task_done() 114 if (unlikely(!task)) { in sas_scsi_task_done() 122 sas_free_task(task); in sas_scsi_task_done() [all …]
|
| /linux/kernel/bpf/ |
| H A D | task_iter.c | 41 struct task_struct *task; in task_group_seq_get_next() local 48 task = get_pid_task(pid, PIDTYPE_TGID); in task_group_seq_get_next() 49 if (!task) in task_group_seq_get_next() 55 return task; in task_group_seq_get_next() 64 task = get_pid_task(pid, PIDTYPE_PID); in task_group_seq_get_next() 66 return task; in task_group_seq_get_next() 69 task = find_task_by_pid_ns(common->pid_visiting, common->ns); in task_group_seq_get_next() 70 if (!task) in task_group_seq_get_next() 74 task = __next_thread(task); in task_group_seq_get_next() 75 if (!task) in task_group_seq_get_next() [all …]
|
| /linux/arch/mips/include/asm/ |
| H A D | syscall.h | 29 static inline bool mips_syscall_is_indirect(struct task_struct *task, in mips_syscall_is_indirect() argument 34 test_tsk_thread_flag(task, TIF_32BIT_REGS)) && in mips_syscall_is_indirect() 38 static inline long syscall_get_nr(struct task_struct *task, in syscall_get_nr() argument 41 return task_thread_info(task)->syscall; in syscall_get_nr() 44 static inline void syscall_set_nr(struct task_struct *task, in syscall_set_nr() argument 56 task_thread_info(task)->syscall = regs->regs[2] = nr; in syscall_set_nr() 59 static inline void mips_syscall_update_nr(struct task_struct *task, in mips_syscall_update_nr() argument 66 if (mips_syscall_is_indirect(task, regs)) in mips_syscall_update_nr() 67 task_thread_info(task)->syscall = regs->regs[4]; in mips_syscall_update_nr() 69 task_thread_info(task)->syscall = regs->regs[2]; in mips_syscall_update_nr() [all …]
|
| /linux/arch/powerpc/kernel/ |
| H A D | signal.h | 36 struct task_struct *task); 38 struct task_struct *task); 39 extern unsigned long copy_vsx_from_user(struct task_struct *task, 41 extern unsigned long copy_ckvsx_from_user(struct task_struct *task, 43 unsigned long copy_fpr_to_user(void __user *to, struct task_struct *task); 44 unsigned long copy_ckfpr_to_user(void __user *to, struct task_struct *task); 45 unsigned long copy_fpr_from_user(struct task_struct *task, void __user *from); 46 unsigned long copy_ckfpr_from_user(struct task_struct *task, void __user *from); 48 #define unsafe_copy_fpr_to_user(to, task, label) do { \ argument 49 struct task_struct *__t = task; \ [all …]
|
| /linux/include/linux/ |
| H A D | cn_proc.h | 23 void proc_fork_connector(struct task_struct *task); 24 void proc_exec_connector(struct task_struct *task); 25 void proc_id_connector(struct task_struct *task, int which_id); 26 void proc_sid_connector(struct task_struct *task); 27 void proc_ptrace_connector(struct task_struct *task, int which_id); 28 void proc_comm_connector(struct task_struct *task); 29 void proc_coredump_connector(struct task_struct *task); 30 void proc_exit_connector(struct task_struct *task); 32 static inline void proc_fork_connector(struct task_struct *task) in proc_fork_connector() argument 35 static inline void proc_exec_connector(struct task_struct *task) in proc_exec_connector() argument [all …]
|
| /linux/drivers/scsi/ |
| H A D | libiscsi.c | 146 void iscsi_prep_data_out_pdu(struct iscsi_task *task, struct iscsi_r2t_info *r2t, in iscsi_prep_data_out_pdu() argument 149 struct iscsi_conn *conn = task->conn; in iscsi_prep_data_out_pdu() 152 task->hdr_len = sizeof(struct iscsi_data); in iscsi_prep_data_out_pdu() 159 hdr->lun = task->lun; in iscsi_prep_data_out_pdu() 160 hdr->itt = task->hdr_itt; in iscsi_prep_data_out_pdu() 176 static int iscsi_add_hdr(struct iscsi_task *task, unsigned len) in iscsi_add_hdr() argument 178 unsigned exp_len = task->hdr_len + len; in iscsi_add_hdr() 180 if (exp_len > task->hdr_max) { in iscsi_add_hdr() 186 task->hdr_len = exp_len; in iscsi_add_hdr() 193 static int iscsi_prep_ecdb_ahs(struct iscsi_task *task) in iscsi_prep_ecdb_ahs() argument [all …]
|
| /linux/arch/riscv/kernel/ |
| H A D | usercfi.c | 24 bool is_shstk_enabled(struct task_struct *task) in is_shstk_enabled() argument 26 return task->thread_info.user_cfi_state.ubcfi_en; in is_shstk_enabled() 29 bool is_shstk_allocated(struct task_struct *task) in is_shstk_allocated() argument 31 return task->thread_info.user_cfi_state.shdw_stk_base; in is_shstk_allocated() 34 bool is_shstk_locked(struct task_struct *task) in is_shstk_locked() argument 36 return task->thread_info.user_cfi_state.ubcfi_locked; in is_shstk_locked() 39 void set_shstk_base(struct task_struct *task, unsigned long shstk_addr, unsigned long size) in set_shstk_base() argument 41 task->thread_info.user_cfi_state.shdw_stk_base = shstk_addr; in set_shstk_base() 42 task->thread_info.user_cfi_state.shdw_stk_size = size; in set_shstk_base() 45 unsigned long get_shstk_base(struct task_struct *task, unsigned long *size) in get_shstk_base() argument [all …]
|
| /linux/drivers/scsi/pm8001/ |
| H A D | pm8001_sas.c | 50 static int pm8001_find_tag(struct sas_task *task, u32 *tag) in pm8001_find_tag() argument 52 if (task->lldd_task) { in pm8001_find_tag() 54 ccb = task->lldd_task; in pm8001_find_tag() 104 static void pm80xx_get_tag_opcodes(struct sas_task *task, int *ata_op, in pm80xx_get_tag_opcodes() argument 114 if (!task) in pm80xx_get_tag_opcodes() 117 spin_lock_irqsave(&task->task_state_lock, flags); in pm80xx_get_tag_opcodes() 118 if (unlikely((task->task_state_flags & SAS_TASK_STATE_ABORTED))) in pm80xx_get_tag_opcodes() 120 spin_unlock_irqrestore(&task->task_state_lock, flags); in pm80xx_get_tag_opcodes() 122 if (task->task_proto == SAS_PROTOCOL_STP) { in pm80xx_get_tag_opcodes() 125 qc = task->uldd_task; in pm80xx_get_tag_opcodes() [all …]
|
| /linux/drivers/scsi/isci/ |
| H A D | task.c | 76 static void isci_task_refuse(struct isci_host *ihost, struct sas_task *task, in isci_task_refuse() argument 85 __func__, task, response, status); in isci_task_refuse() 87 spin_lock_irqsave(&task->task_state_lock, flags); in isci_task_refuse() 89 task->task_status.resp = response; in isci_task_refuse() 90 task->task_status.stat = status; in isci_task_refuse() 93 task->task_state_flags |= SAS_TASK_STATE_DONE; in isci_task_refuse() 94 task->task_state_flags &= ~SAS_TASK_STATE_PENDING; in isci_task_refuse() 95 task->lldd_task = NULL; in isci_task_refuse() 96 spin_unlock_irqrestore(&task->task_state_lock, flags); in isci_task_refuse() 98 task->task_done(task); in isci_task_refuse() [all …]
|
| /linux/scripts/gdb/linux/ |
| H A D | tasks.py | 4 # task & thread tools 39 for task in task_lists(): 40 if int(task['pid']) == pid: 41 return task 46 """Find Linux task by PID and return the task_struct variable. 55 task = get_task_by_pid(pid) 56 if task: 57 return task.dereference() 59 raise gdb.GdbError("No task of PID " + str(pid)) 73 for task i 86 get_thread_info(task) global() argument 103 invoke(self, task) global() argument [all...] |
| /linux/fs/proc/ |
| H A D | namespaces.c | 47 struct task_struct *task; in proc_ns_get_link() local 54 task = get_proc_task(inode); in proc_ns_get_link() 55 if (!task) in proc_ns_get_link() 58 error = down_read_killable(&task->signal->exec_update_lock); in proc_ns_get_link() 63 if (!ptrace_may_access(task, PTRACE_MODE_READ_FSCREDS)) in proc_ns_get_link() 66 error = ns_get_path(&ns_path, task, ns_ops); in proc_ns_get_link() 72 up_read(&task->signal->exec_update_lock); in proc_ns_get_link() 74 put_task_struct(task); in proc_ns_get_link() 82 struct task_struct *task; in proc_ns_readlink() local 86 task = get_proc_task(inode); in proc_ns_readlink() [all …]
|
| /linux/tools/perf/util/bpf_skel/ |
| H A D | kwork_top.bpf.c | 105 static __always_inline void update_task_info(struct task_struct *task, __u32 cpu) in update_task_info() argument 108 .pid = task->pid, in update_task_info() 114 .tgid = task->tgid, in update_task_info() 115 .is_kthread = task->flags & PF_KTHREAD ? 1 : 0, in update_task_info() 117 BPF_CORE_READ_STR_INTO(&data.comm, task, comm); in update_task_info() 139 static void on_sched_out(struct task_struct *task, __u64 ts, __u32 cpu) in on_sched_out() argument 144 pelem = bpf_task_storage_get(&kwork_top_task_time, task, NULL, 0); in on_sched_out() 152 .pid = task->pid, in on_sched_out() 153 .task_p = (__u64)task, in on_sched_out() 157 update_task_info(task, cpu); in on_sched_out() [all …]
|
| /linux/drivers/gpu/drm/ |
| H A D | drm_flip_work.c | 38 struct drm_flip_task *task; in drm_flip_work_allocate_task() local 40 task = kzalloc_obj(*task, flags); in drm_flip_work_allocate_task() 41 if (task) in drm_flip_work_allocate_task() 42 task->data = data; in drm_flip_work_allocate_task() 44 return task; in drm_flip_work_allocate_task() 47 static void drm_flip_work_queue_task(struct drm_flip_work *work, struct drm_flip_task *task) in drm_flip_work_queue_task() argument 52 list_add_tail(&task->node, &work->queued); in drm_flip_work_queue_task() 66 struct drm_flip_task *task; in drm_flip_work_queue() local 68 task = drm_flip_work_allocate_task(val, in drm_flip_work_queue() 70 if (task) { in drm_flip_work_queue() [all …]
|
| /linux/include/linux/fsl/bestcomm/ |
| H A D | bestcomm_priv.h | 238 extern int bcom_load_image(int task, u32 *task_image); 239 extern void bcom_set_initiator(int task, int initiator); 261 bcom_enable_task(int task) in bcom_enable_task() argument 264 reg = in_be16(&bcom_eng->regs->tcr[task]); in bcom_enable_task() 265 out_be16(&bcom_eng->regs->tcr[task], reg | TASK_ENABLE); in bcom_enable_task() 269 bcom_disable_task(int task) in bcom_disable_task() argument 271 u16 reg = in_be16(&bcom_eng->regs->tcr[task]); in bcom_disable_task() 272 out_be16(&bcom_eng->regs->tcr[task], reg & ~TASK_ENABLE); in bcom_disable_task() 277 bcom_task_desc(int task) in bcom_task_desc() argument 279 return bcom_sram_pa2va(bcom_eng->tdt[task].start); in bcom_task_desc() [all …]
|
| /linux/arch/microblaze/include/asm/ |
| H A D | processor.h | 72 # define task_tos(task) ((unsigned long)(task) + KERNEL_STACK_SIZE) argument 73 # define task_regs(task) ((struct pt_regs *)task_tos(task) - 1) argument 78 # define task_sp(task) (task_regs(task)->r1) argument 79 # define task_pc(task) (task_regs(task)->pc) argument 81 # define KSTK_EIP(task) (task_pc(task)) argument 82 # define KSTK_ESP(task) (task_sp(task)) argument
|
| /linux/arch/riscv/include/asm/ |
| H A D | switch_to.h | 28 static inline void fstate_off(struct task_struct *task, in fstate_off() argument 34 static inline void fstate_save(struct task_struct *task, in fstate_save() argument 38 __fstate_save(task); in fstate_save() 43 static inline void fstate_restore(struct task_struct *task, in fstate_restore() argument 47 __fstate_restore(task); in fstate_restore() 69 #define fstate_save(task, regs) do { } while (0) argument 70 #define fstate_restore(task, regs) do { } while (0) argument 74 static inline void envcfg_update_bits(struct task_struct *task, in envcfg_update_bits() argument 79 envcfg = (task->thread.envcfg & ~mask) | val; in envcfg_update_bits() 80 task->thread.envcfg = envcfg; in envcfg_update_bits() [all …]
|
| /linux/drivers/scsi/aic94xx/ |
| H A D | aic94xx_tmf.c | 214 static int asd_clear_nexus_tag(struct sas_task *task) in asd_clear_nexus_tag() argument 216 struct asd_ha_struct *asd_ha = task->dev->port->ha->lldd_ha; in asd_clear_nexus_tag() 217 struct asd_ascb *tascb = task->lldd_task; in asd_clear_nexus_tag() 221 memcpy(scb->clear_nexus.ssp_task.lun, task->ssp_task.LUN, 8); in asd_clear_nexus_tag() 223 if (task->dev->tproto) in asd_clear_nexus_tag() 225 task->dev->lldd_dev); in asd_clear_nexus_tag() 229 static int asd_clear_nexus_index(struct sas_task *task) in asd_clear_nexus_index() argument 231 struct asd_ha_struct *asd_ha = task->dev->port->ha->lldd_ha; in asd_clear_nexus_index() 232 struct asd_ascb *tascb = task->lldd_task; in asd_clear_nexus_index() 236 if (task->dev->tproto) in asd_clear_nexus_index() [all …]
|