Lines Matching defs:task
315 static void __init lsm_early_task(struct task_struct *task);
343 init_debug("task blob size = %d\n", blob_sizes.lbs_task);
599 * lsm_task_alloc - allocate a composite task blob
600 * @task: the task that needs a blob
602 * Allocate the task blob for all the modules
606 static int lsm_task_alloc(struct task_struct *task)
609 task->security = NULL;
613 task->security = kzalloc(blob_sizes.lbs_task, GFP_KERNEL);
614 if (task->security == NULL)
662 * lsm_early_task - during initialization allocate a composite task blob
663 * @task: the task that needs a blob
665 * Allocate the task blob for all the modules
667 static void __init lsm_early_task(struct task_struct *task)
669 int rc = lsm_task_alloc(task);
672 panic("%s: Early task alloc failed.\n", __func__);
1617 int security_task_alloc(struct task_struct *task, unsigned long clone_flags)
1619 int rc = lsm_task_alloc(task);
1623 rc = call_int_hook(task_alloc, 0, task, clone_flags);
1625 security_task_free(task);
1629 void security_task_free(struct task_struct *task)
1631 call_void_hook(task_free, task);
1633 kfree(task->security);
1634 task->security = NULL;