arm64: remove unneeded BUILD_BUG_ON assertion
authorDawei Li <dawei.li@shingroup.cn>
Fri, 2 Feb 2024 04:02:11 +0000 (12:02 +0800)
committerCatalin Marinas <catalin.marinas@arm.com>
Thu, 22 Feb 2024 11:02:51 +0000 (11:02 +0000)
Since commit c02433dd6de3 ("arm64: split thread_info from task stack"),
CONFIG_THREAD_INFO_IN_TASK is enabled unconditionally for arm64. So
remove this always-true assertion from arch_dup_task_struct.

Signed-off-by: Dawei Li <dawei.li@shingroup.cn>
Acked-by: Mark Rutland <mark.rutland@arm.com>
Link: https://lore.kernel.org/r/20240202040211.3118918-1-dawei.li@shingroup.cn
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
arch/arm64/kernel/process.c

index 7387b68c745b21344370af4598c5d738953c3595..4ae31b7af6c31176c072cebb0c5b5269311bc3b1 100644 (file)
@@ -290,9 +290,6 @@ int arch_dup_task_struct(struct task_struct *dst, struct task_struct *src)
                fpsimd_preserve_current_state();
        *dst = *src;
 
-       /* We rely on the above assignment to initialize dst's thread_flags: */
-       BUILD_BUG_ON(!IS_ENABLED(CONFIG_THREAD_INFO_IN_TASK));
-
        /*
         * Detach src's sve_state (if any) from dst so that it does not
         * get erroneously used or freed prematurely.  dst's copies