linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Robert Love <rml@mvista.com>
To: William Lee Irwin III <wli@holomorphy.com>
Cc: Mark_H_Johnson@Raytheon.com, kpreempt-tech@lists.sourceforge.net,
	linux-mm@kvack.org, Robert_Horton@Raytheon.com,
	James_P_Cassidy@Raytheon.com, Stanley_R_Allen@Raytheon.com
Subject: Re: [kpreempt-tech] Re: Oops in kernel 2.4.19-pre10-ac2-preempt
Date: 20 Jun 2002 10:58:21 -0700	[thread overview]
Message-ID: <1024595902.1195.169.camel@sinai> (raw)
In-Reply-To: <20020620172220.GT25360@holomorphy.com>

On Thu, 2002-06-20 at 10:22, William Lee Irwin III wrote:

> That'd be great, the two places are pte_chain_lock() and pte_chain_unlock().
> They're basically a spin_lock_bit() and spin_unlock_bit(), so they need
> the same kind of disable preempt before the spinloop and re-enable it after
> dropping the lock treatment as spinlocks.

Here is the patch... I will put out an updated -ac patch shortly with
this and some other bits.

Correct?

	Robert Love

diff -urN linux-2.4.19-pre10-ac2/include/linux/mm.h linux/include/linux/mm.h
--- linux-2.4.19-pre10-ac2/include/linux/mm.h	Thu Jun  6 11:16:03 2002
+++ linux/include/linux/mm.h	Thu Jun 20 10:57:01 2002
@@ -340,6 +340,7 @@
 	 * busywait with less bus contention for a good time to
 	 * attempt to acquire the lock bit.
 	 */
+	preempt_disable();
 	while (test_and_set_bit(PG_chainlock, &page->flags)) {
 		while (test_bit(PG_chainlock, &page->flags))
 			cpu_relax();
@@ -349,6 +350,7 @@
 static inline void pte_chain_unlock(struct page *page)
 {
 	clear_bit(PG_chainlock, &page->flags);
+	preempt_enable();
 }
 
 /*


--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/

  reply	other threads:[~2002-06-20 17:58 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-06-20 16:01 Mark_H_Johnson
2002-06-20 17:16 ` William Lee Irwin III
2002-06-20 17:19   ` [kpreempt-tech] " Robert Love
2002-06-20 17:22     ` William Lee Irwin III
2002-06-20 17:58       ` Robert Love [this message]
2002-06-20 18:01         ` William Lee Irwin III

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=1024595902.1195.169.camel@sinai \
    --to=rml@mvista.com \
    --cc=James_P_Cassidy@Raytheon.com \
    --cc=Mark_H_Johnson@Raytheon.com \
    --cc=Robert_Horton@Raytheon.com \
    --cc=Stanley_R_Allen@Raytheon.com \
    --cc=kpreempt-tech@lists.sourceforge.net \
    --cc=linux-mm@kvack.org \
    --cc=wli@holomorphy.com \
    /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