Module: xenomai-3
Branch: next
Commit: 4fbdfe486e4d92bef4d40e088b551ce7db7d48bc
URL:    
http://git.xenomai.org/?p=xenomai-3.git;a=commit;h=4fbdfe486e4d92bef4d40e088b551ce7db7d48bc

Author: Philippe Gerum <r...@xenomai.org>
Date:   Sat Nov 14 14:47:44 2015 +0100

cobalt/thread: track thread_info unconditionally

We almost always want to track the thread_info structure of the host
task in the core tcb, and doing so is cheap, so there is no point in
building this support conditionally.

---

 kernel/cobalt/arch/arm/Kconfig                     |    3 ---
 kernel/cobalt/arch/arm64/Kconfig                   |    3 ---
 kernel/cobalt/arch/powerpc/Kconfig                 |    4 ----
 kernel/cobalt/include/asm-generic/xenomai/thread.h |    2 --
 kernel/cobalt/sched.c                              |    2 --
 kernel/cobalt/thread.c                             |    4 ----
 6 files changed, 18 deletions(-)

diff --git a/kernel/cobalt/arch/arm/Kconfig b/kernel/cobalt/arch/arm/Kconfig
index dc6485d..2043d70 100644
--- a/kernel/cobalt/arch/arm/Kconfig
+++ b/kernel/cobalt/arch/arm/Kconfig
@@ -26,9 +26,6 @@ config IPIPE_WANT_PREEMPTIBLE_SWITCH
 config IPIPE_WANT_ACTIVE_MM
        def_bool y
 
-config XENO_ARCH_WANT_TIP
-       def_bool y
-
 config XENO_ARCH_FPU
        def_bool VFP
 
diff --git a/kernel/cobalt/arch/arm64/Kconfig b/kernel/cobalt/arch/arm64/Kconfig
index 27b5026..572de3e 100644
--- a/kernel/cobalt/arch/arm64/Kconfig
+++ b/kernel/cobalt/arch/arm64/Kconfig
@@ -4,9 +4,6 @@ source "drivers/xenomai/Kconfig"
 config XENO_ARCH_UNLOCKED_SWITCH
        def_bool IPIPE_WANT_PREEMPTIBLE_SWITCH
 
-config XENO_ARCH_WANT_TIP
-       def_bool y
-
 config XENO_ARCH_FPU
        def_bool y
 
diff --git a/kernel/cobalt/arch/powerpc/Kconfig 
b/kernel/cobalt/arch/powerpc/Kconfig
index 3e950f5..4d5e6db 100644
--- a/kernel/cobalt/arch/powerpc/Kconfig
+++ b/kernel/cobalt/arch/powerpc/Kconfig
@@ -10,9 +10,6 @@ config IPIPE_WANT_PREEMPTIBLE_SWITCH
        default y if XENO_ARCH_UNLOCKED_SWITCH
        default n if !XENO_ARCH_UNLOCKED_SWITCH
 
-config XENO_ARCH_WANT_TIP
-       bool
-
 config XENO_ARCH_FPU
        def_bool PPC_FPU
 
@@ -24,7 +21,6 @@ menu "Machine/platform-specific options"
 config XENO_ARCH_UNLOCKED_SWITCH
        bool "Unlocked context switch"
        depends on IPIPE_HAVE_PREEMPTIBLE_SWITCH
-       select XENO_ARCH_WANT_TIP
        default y
        help
 
diff --git a/kernel/cobalt/include/asm-generic/xenomai/thread.h 
b/kernel/cobalt/include/asm-generic/xenomai/thread.h
index 2ff19a4..cd0c6e9 100644
--- a/kernel/cobalt/include/asm-generic/xenomai/thread.h
+++ b/kernel/cobalt/include/asm-generic/xenomai/thread.h
@@ -33,9 +33,7 @@ struct xntcb {
        struct mm_struct *mm;
        struct mm_struct *active_mm;
        struct thread_struct ts;
-#ifdef CONFIG_XENO_ARCH_WANT_TIP
        struct thread_info *tip;
-#endif
 #ifdef CONFIG_XENO_ARCH_FPU
        struct task_struct *user_fpu_owner;
 #endif
diff --git a/kernel/cobalt/sched.c b/kernel/cobalt/sched.c
index cbe14bd..09960ac 100644
--- a/kernel/cobalt/sched.c
+++ b/kernel/cobalt/sched.c
@@ -806,9 +806,7 @@ static inline void leave_root(struct xnthread *root)
        rootcb->core.host_task = p;
        rootcb->core.tsp = &p->thread;
        rootcb->core.mm = rootcb->core.active_mm = ipipe_get_active_mm();
-#ifdef CONFIG_XENO_ARCH_WANT_TIP
        rootcb->core.tip = task_thread_info(p);
-#endif
        xnarch_leave_root(root);
 }
 
diff --git a/kernel/cobalt/thread.c b/kernel/cobalt/thread.c
index 34eca35..e0c488e 100644
--- a/kernel/cobalt/thread.c
+++ b/kernel/cobalt/thread.c
@@ -260,9 +260,7 @@ void xnthread_init_shadow_tcb(struct xnthread *thread)
        tcb->core.tsp = &p->thread;
        tcb->core.mm = p->mm;
        tcb->core.active_mm = p->mm;
-#ifdef CONFIG_XENO_ARCH_WANT_TIP
        tcb->core.tip = task_thread_info(p);
-#endif
 #ifdef CONFIG_XENO_ARCH_FPU
        tcb->core.user_fpu_owner = p;
 #endif /* CONFIG_XENO_ARCH_FPU */
@@ -278,9 +276,7 @@ void xnthread_init_root_tcb(struct xnthread *thread)
        tcb->core.host_task = p;
        tcb->core.tsp = &tcb->core.ts;
        tcb->core.mm = p->mm;
-#ifdef CONFIG_XENO_ARCH_WANT_TIP
        tcb->core.tip = NULL;
-#endif
        xnarch_init_root_tcb(thread);
 }
 


_______________________________________________
Xenomai-git mailing list
Xenomai-git@xenomai.org
https://xenomai.org/mailman/listinfo/xenomai-git

Reply via email to