2.6.26.3 with rt3 patch: BUG: sleeping function called kernel/rtmutex.c:743
Hello,
I experienced this "rtmutex.c:743" known bug with rt3 patch, using
http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.26.3.tar.bz2
http://rt.et.redhat.com/download/patch-2.6.26.3-rt3.bz2
I compiled this kernel with the "make-kpkg" debian utility.
I first compiled this kernel with NO SMP, NO HIGHMEM, and partial ACPI (without fan, processor, ... modules). Attached file "config-2.6.26.3-rt3lowlty.frwr.gz".
I didn't experience any problem with this kernel.
I then enabled SMP and HIGHMEM, and experienced "rtmutex.c:743" BUG. Attached files
"config-2.6.26.3-rt3rt-smp-hm.gz" and "dmesg.gz" for some BUGGY message.
I have seen somewhere on the archive, that some people still experienced problems with SMP.
I guess no fix has been done from rt3 to rt7 patch. Can you confirm?
If so, which recent kernel should I use in order to get smp and rt running without problems?
Regards, Xavier Droubay.
PATCH 1/1 Convert tlbstate_lock spin_lock to raw_spin_lock
Quoted 19 lines · xavier droubay
Hello,
I experienced this "rtmutex.c:743" known bug with rt3 patch, using
http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.26.3.tar.bz2
http://rt.et.redhat.com/download/patch-2.6.26.3-rt3.bz2I compiled this kernel with the "make-kpkg" debian utility.
I first compiled this kernel with NO SMP, NO HIGHMEM, and partial ACPI (without fan, processor, ... modules). Attached file "config-2.6.26.3-rt3lowlty.frwr.gz".
I didn't experience any problem with this kernel.I then enabled SMP and HIGHMEM, and experienced "rtmutex.c:743" BUG. Attached files
"config-2.6.26.3-rt3rt-smp-hm.gz" and "dmesg.gz" for some BUGGY message.
Quoted 7 lines
I have seen somewhere on the archive, that some people still experienced problems with SMP.
I guess no fix has been done from rt3 to rt7 patch. Can you confirm?If so, which recent kernel should I use in order to get smp and rt running without problems?
This simple patch should solve the above problem. Seeing the config, its seems to be a 32bit box.
It convert tlbstate_lock spin_lock to raw_spin_lock. Preemption has already been disabled, hence this change shouldn't affect latency numbers.
arch/x86/kernel/tlb_32.c +1 -1
@@ -23,7 +23,7 @@ DEFINE_PER_CPU(struct tlb_state, cpu_tlbstate)static cpumask_t flush_cpumask;static struct mm_struct *flush_mm;static unsigned long flush_va; -static DEFINE_SPINLOCK (tlbstate_lock); +static DEFINE_RAW_SPINLOCK (tlbstate_lock);/* * We cannot call mmdrop() because we are in interrupt context,
Re: [PATCH] Convert tlbstate_lock spin_lock to raw_spin_lock
Chirag,
Kindly understand what xavier is trying to do. He is Trying to disable smp.
The RT - Linux Code is dependent on the mutex lock to perform some soft/hard real time processing. This is an problem with the mutex lock.
Kindly check with some one before signing off patches.
Thanks,
Sujit
Quoted 61 lines · Chirag Jog
Quoted 19 lines · xavier droubay
Hello,
I experienced this "rtmutex.c:743" known bug with rt3 patch, using
http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.26.3.tar.bz2
http://rt.et.redhat.com/download/patch-2.6.26.3-rt3.bz2I compiled this kernel with the "make-kpkg" debian utility.
I first compiled this kernel with NO SMP, NO HIGHMEM, and partial ACPI (without fan, processor, ... modules). Attached file "config-2.6.26.3-rt3lowlty.frwr.gz".
I didn't experience any problem with this kernel.I then enabled SMP and HIGHMEM, and experienced "rtmutex.c:743" BUG. Attached files
"config-2.6.26.3-rt3rt-smp-hm.gz" and "dmesg.gz" for some BUGGY message.Quoted 7 lines
I have seen somewhere on the archive, that some people still experienced problems with SMP.
I guess no fix has been done from rt3 to rt7 patch. Can you confirm?If so, which recent kernel should I use in order to get smp and rt running without problems?
This simple patch should solve the above problem. Seeing the config, its seems to be a 32bit box.
It convert
tlbstate_lockspin_locktoraw_spin_lock. Preemption has already been disabled, hence this change shouldn't affect latency numbers.Signed-off-by Chirag <[email protected]>arch/x86/kernel/tlb_32.c +1
-2@@ -23,7 +23,7 @@ DEFINE_PER_CPU(struct tlb_state, cpu_tlbstate)static cpumask_t flush_cpumask;static struct mm_struct *flush_mm;static unsigned long flush_va; -static DEFINE_SPINLOCK (tlbstate_lock); +static DEFINE_RAW_SPINLOCK (tlbstate_lock);/* * We cannot call mmdrop() because we are in interrupt context, -- 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 · 1 line
--linux(2.4/2.6),bsd(4.5.x+),solaris(2.5+)
Re: [PATCH] Convert tlbstate_lock spin_lock to raw_spin_lock
[ Refrain from using "unlisted-recipients" please! ]
Quoted 5 lines · Sujit Karataparambil
Chirag,
Kindly understand what xavier is trying to do. He is Trying to disable smp.
The RT - Linux Code is dependent on the mutex lock to perform some soft/hard real time processing. This is an problem with the mutex lock.
It is not a problem with the mutex lock.
Quoted 2 lines
Kindly check with some one before signing off patches.
The patch is legit.
The problem is simply that functions like flush_tlb_current_task and flush_tlb_mm disable preemption and then call flush_tlb_others. This function locks the tlbstate_lock which is currently a rtmutex. An rtmutex can not be called with preemption disabled. The tlbstate_lock is static, small and confined. I'm not sure we can change this code (flushing the TLB) in a way where we can allow preemption. This may just be a latency that we must hit.
-- Steve
A message that is not in the archive (sent off-list or not yet received): [email protected]
Thanks Carsten, for your informations,
Quoted 3 lines
All 2.6.26 related rt-patches are experimental. In fact, it would be better to call them 2.6.26.3-rtrc3 to indicate that this is, at best, a release candidate - but no release.
As I am these days interested in rt patches I can provide you more info on my attempts to bring a functional rt 2.6.26 kernel. I usually log my compilation results and try to find usefull info (just recompiled kernel with full ACPI support with the rt7 patch, although I guess I will obtain the same results). I am not an expert but I have some background knowledge of linux system as a user.
If you give me info or documentation to read for tests or debugging purpose, I am ready to help you at the moment, if I able to.
Quoted 6 lines
Our "Latest Stable" is 2.6.24.7-rt17
(http://www.osadl.org/Latest-Stable.latest-stable-realtime-linux.0.html).
Can't you use this one? If this kernel has the problem you are experiencing, we are certainly interested to fix it.
As first of all I need a stable kernel for a dual core on the box an impatient friend,
I'll use 2.6.24.7-rt17 as your advise suggests, and tell you in case I get trouble with it.
Regards, Xavier Droubay.