hc
2023-12-11 6778948f9de86c3cfaf36725a7c87dcff9ba247f
kernel/kernel/fork.c
....@@ -42,7 +42,6 @@
4242 #include <linux/mmu_notifier.h>
4343 #include <linux/fs.h>
4444 #include <linux/mm.h>
45
-#include <linux/kprobes.h>
4645 #include <linux/vmacache.h>
4746 #include <linux/nsproxy.h>
4847 #include <linux/capability.h>
....@@ -295,7 +294,7 @@
295294 return;
296295 }
297296
298
- vfree(tsk->stack);
297
+ vfree_atomic(tsk->stack);
299298 return;
300299 }
301300 #endif
....@@ -724,19 +723,6 @@
724723 }
725724 EXPORT_SYMBOL_GPL(__mmdrop);
726725
727
-#ifdef CONFIG_PREEMPT_RT
728
-/*
729
- * RCU callback for delayed mm drop. Not strictly rcu, but we don't
730
- * want another facility to make this work.
731
- */
732
-void __mmdrop_delayed(struct rcu_head *rhp)
733
-{
734
- struct mm_struct *mm = container_of(rhp, struct mm_struct, delayed_drop);
735
-
736
- __mmdrop(mm);
737
-}
738
-#endif
739
-
740726 static void mmdrop_async_fn(struct work_struct *work)
741727 {
742728 struct mm_struct *mm;
....@@ -777,15 +763,6 @@
777763 WARN_ON(!tsk->exit_state);
778764 WARN_ON(refcount_read(&tsk->usage));
779765 WARN_ON(tsk == current);
780
-
781
- /*
782
- * Remove function-return probe instances associated with this
783
- * task and put them back on the free list.
784
- */
785
- kprobe_flush_task(tsk);
786
-
787
- /* Task is done with its stack. */
788
- put_task_stack(tsk);
789766
790767 io_uring_free(tsk);
791768 cgroup_free(tsk);
....@@ -984,13 +961,11 @@
984961 tsk->splice_pipe = NULL;
985962 tsk->task_frag.page = NULL;
986963 tsk->wake_q.next = NULL;
987
- tsk->wake_q_sleeper.next = NULL;
988964 tsk->pf_io_worker = NULL;
989965
990966 account_kernel_stack(tsk, 1);
991967
992968 kcov_task_init(tsk);
993
- kmap_local_fork(tsk);
994969
995970 #ifdef CONFIG_FAULT_INJECTION
996971 tsk->fail_nth = 0;
....@@ -2084,7 +2059,6 @@
20842059 spin_lock_init(&p->alloc_lock);
20852060
20862061 init_sigpending(&p->pending);
2087
- p->sigqueue_cache = NULL;
20882062
20892063 p->utime = p->stime = p->gtime = 0;
20902064 #ifdef CONFIG_ARCH_HAS_SCALED_CPUTIME