Hi Kefeng, On Fri, Aug 19, 2022 at 3:39 AM Kefeng Wang <wangkefeng.wang@xxxxxxxxxx> wrote:
Only x86 has own release_thread(), introduce a new weak release_thread() function to clean empty definitions in other ARCHs. Signed-off-by: Kefeng Wang <wangkefeng.wang@xxxxxxxxxx>
arch/m68k/include/asm/processor.h | 5 -----
Acked-by: Geert Uytterhoeven <geert@xxxxxxxxxxxxxx>
--- a/kernel/exit.c +++ b/kernel/exit.c @@ -183,6 +183,10 @@ void put_task_struct_rcu_user(struct task_struct *task) call_rcu(&task->rcu, delayed_put_task_struct); } +void __weak release_thread(struct task_struct *dead_task) +{ +}
As the default implementation is empty, it might be better to keep this as a static inline function, protected by #ifndef release_thread, and let x86 #define release_thread.
+ void release_task(struct task_struct *p) { struct task_struct *leader;
Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds