Fix compilation of 2.6.23rc4-rt1 without CONFIG_PREEMPT_RT
PATCH 1/1 Fix compilation of 2.6.23rc4-rt1 without CONFIG_PREEMPT_RT
count_active_rt_tasks() is undefined otherwise.
kernel/timer.c +4 -2
@@ -919,18 +919,20 @@ static unsigned long count_active_tasks(#endif } -#ifdef CONFIG_PREEMPT_RT /* * Nr of active tasks - counted in fixed-point numbers */ static unsigned long count_active_rt_tasks (void ) { +#ifdef CONFIG_PREEMPT_RT extern unsigned long rt_nr_running (void );extern unsigned long rt_nr_uninterruptible (void );return (rt_nr_running () +rt_nr_uninterruptible ()) *FIXED_1 ; -} +#else +return 0 ;#endif +}/* * Hmm.. Changed this, as the GNU make sources (load.c) seems to
Quoted 2 lines · Andi Kleen
count_active_rt_tasks()is undefined otherwise.
This does fix the compile issue, but RT tasks can exist in !PREEMPT_RT as well.
Sven
Quoted 33 lines
Signed-off-by Andi Kleen <[email protected]>Index:
linux-2.6.23-rc4-rt1/kernel/timer.c
===================================================================kernel/timer.c +4
-3@@ -919,18 +919,20 @@ static unsigned long count_active_tasks(#endif } -#ifdef CONFIG_PREEMPT_RT /* * Nr of active tasks - counted in fixed-point numbers */ static unsigned long count_active_rt_tasks (void ) { +#ifdef CONFIG_PREEMPT_RT extern unsigned long rt_nr_running (void );extern unsigned long rt_nr_uninterruptible (void );return (rt_nr_running () +rt_nr_uninterruptible ()) *FIXED_1 ; -} +#else +return 0 ;#endif +}/* * Hmm.. Changed this, as the GNU make sources (load.c) seems to -To unsubscribe from this list: send the line "unsubscribe linux-rt-users" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Signature · 2 lines
Sven-Thorsten Dietrich +1 (415) 694-2930
Quoted 6 lines · On Monday 17 September 2007 18:02:54 Sven-Thorsten Dietrich wrote:
Quoted 2 lines · Andi Kleen
count_active_rt_tasks()is undefined otherwise.This does fix the compile issue, but RT tasks can exist in !PREEMPT_RT as well.
That might be, but neither rt_nr_running nor rt_nr_uninterruptible exist in a !PREEMPT_RT kernel. So they are presumably managed in a different way.
-Andi
Quoted 10 lines · Andi Kleen
Quoted 6 lines · On Monday 17 September 2007 18:02:54 Sven-Thorsten Dietrich wrote:
Quoted 2 lines · Andi Kleen
count_active_rt_tasks()is undefined otherwise.This does fix the compile issue, but RT tasks can exist in !PREEMPT_RT as well.
That might be, but neither
rt_nr_runningnorrt_nr_uninterruptibleexist in a !PREEMPT_RT kernel. So they are presumably managed in a different way.
I think this is the 3rd or 4th fix for this same issue .. It's too bad the -rt tree doesn't get updated more frequently ..
Daniel