From: "Allen Curtis" <acurtis@onz.com>
To: <brian.auld@adic.com>, <linuxppc-embedded@lists.linuxppc.org>
Subject: RE: Kernel Preemption patch
Date: Sun, 23 Feb 2003 14:33:55 -0800 [thread overview]
Message-ID: <NCBBIINEHIPFGJPLBEIFGEILECAA.acurtis@onz.com> (raw)
In-Reply-To: <995FF289C9D69747A09E42992644595405B23680@penguin.adic.com>
[-- Attachment #1: Type: text/plain, Size: 593 bytes --]
> Has anyone successfully applied and run the linux kernel
> preemption patch on
> a 2.4.20 kernel. I have the following:
>
> - Latest Denx kernel (2_4_devel) running on 440GP ebony
> - 'preempt-kernel-rml-2.4.20-1.patch' applied to my kernel source
> (I manually corrected a couple of fails and double checked a few
> 'successfully applied with fuzz' instances when applying the patch).
> - Kernel compiled with 'Kernel preemption =y' in make oldconfig
Yes, but didn't you get any compile errors? There are some missing brackets,
etc. to fix. Check the attached message from this list.
[-- Attachment #2: Type: message/rfc822, Size: 2498 bytes --]
From: "Eugene Surovegin" <ebs@innocent.com>
To: "Joakim Tjernlund" <Joakim.Tjernlund@lumentis.se>
Cc: <linuxppc-dev@lists.linuxppc.org>
Subject: Re: Is the preemptive kernel patch unsafe for 8xx/PPC?
Date: Thu, 12 Dec 2002 22:09:48 -0800
Message-ID: <5.1.0.14.2.20021212214102.02bf1338@mail.attbi.com>
Joakim,
At 12:35 PM 12/12/2002, you wrote:
>Was that the 2.4.19-2 patch? What were the bugs and have you fixed them?
I had the following issues with 2.4.19-2 (2.4.20-1 is identical in this
regard):
1) arch/ppc/kernel.entry.S
diff -urN linux-2.4.20/arch/ppc/kernel/entry.S linux/arch/ppc/kernel/entry.S
--- linux-2.4.20/arch/ppc/kernel/entry.S 2002-11-28
18:53:11.000000000 -0500
+++ linux/arch/ppc/kernel/entry.S 2002-12-11 02:34:47.000000000 -0500
@@ -278,6 +278,41 @@
*/
cmpi 0,r3,0
beq restore
+#ifdef CONFIG_PREEMPT
+ lwz r3,PREEMPT_COUNT(r2)
+ cmpi 0,r3,1
+ bge ret_from_except
+ lwz r5,_MSR(r1)
+ andi. r5,r5,MSR_PR
+ bne do_signal_ret
<rest of the diff is skipped>
I had to change the last command to "bne ret_from_except".
I checked MontaVista tree, and they have "ret_from_except" there also.
Without this change trivial code:
while (true) ;
locked the box completely.
2) include/asm-ppc/pgalloc.h There are curly brackets missing in
get_pgd_fast()
3) to support 440GP you have to modify
arc/ppc/kernel/irc.c:preempt_intercept:
#if !defined(CONFIG_4xx) || defined(CONFIG_440)
case 0x900:
#else
case 0x1000:
#endif
With these changes (an maybe some others I forgot to mention here :),
I have pretty stable preemptable kernel (2.4.19, PPC440GP & 405GP, also
with rtsched patch by George Anzinger)
Thanks,
Eugene Surovegin <mailto:ebs@innocent.com>
next prev parent reply other threads:[~2003-02-23 22:33 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-02-23 22:28 Kernel Preemption patch brian.auld
2003-02-23 22:33 ` Allen Curtis [this message]
2003-02-23 22:54 ` Eugene Surovegin
2003-02-23 23:05 ` Eugene Surovegin
-- strict thread matches above, loose matches on Subject: below --
2003-02-24 12:54 brian.auld
2003-02-24 15:38 brian.auld
2003-02-24 18:05 ` Eugene Surovegin
2003-02-24 18:50 ` Matt Porter
2003-02-24 15:56 brian.auld
2003-02-24 18:02 ` Eugene Surovegin
2003-02-24 19:06 ` Todd Poynor
2003-02-24 20:45 brian.auld
2003-02-24 22:29 ` Eugene Surovegin
2003-02-25 9:12 ` Stefan Roese
2003-02-25 13:24 ` Matt Porter
2003-02-26 4:18 ` Matt Porter
2003-02-26 4:25 ` Eugene Surovegin
2003-02-26 4:52 ` Matt Porter
[not found] <995FF289C9D69747A09E42992644595405B23683@penguin.adic.com>
2003-02-24 21:15 ` Wolfgang Denk
2003-02-25 14:32 brian.auld
2003-02-26 4:14 ` Matt Porter
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=NCBBIINEHIPFGJPLBEIFGEILECAA.acurtis@onz.com \
--to=acurtis@onz.com \
--cc=brian.auld@adic.com \
--cc=linuxppc-embedded@lists.linuxppc.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).