linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: "Juan J. Quintela" <quintela@fi.udc.es>
To: "Stephen C. Tweedie" <sct@redhat.com>
Cc: linux-mm@kvack.org, linux-kernel@vger.rutgers.edu,
	Linus Torvalds <torvalds@transmeta.com>
Subject: PATCH: Re: Helding the Kernel lock while doing IO???
Date: 15 May 2000 00:02:45 +0200	[thread overview]
Message-ID: <yttbt2823ju.fsf_-_@vexeta.dc.fi.udc.es> (raw)
In-Reply-To: "Stephen C. Tweedie"'s message of "Sat, 6 May 2000 12:48:09 +0100"

>>>>> "stephen" == Stephen C Tweedie <sct@redhat.com> writes:

stephen> Hi,
stephen> On Sat, May 06, 2000 at 03:30:47AM +0200, Juan J. Quintela wrote:
>> 
>> read_swap_cache is called synchronously, then we can have to wait
>> until we read the page to liberate the lock kernel.  It is intended?
>> I am losing some detail?

stephen> Holding the big kernel lock while we sleep is quite legal.  The 
stephen> scheduler drops the lock while we sleep and reacquires it when we
stephen> are rescheduled.  The lock_kernel() lock is not at all like other
stephen> spinlocks.

Thanks again for the comment, what do you think about add a comment
about that?  Patch attached.

Later, Juan.

diff -urN --exclude-from=/home/lfcia/quintela/work/kernel/exclude work/include/linux/smp_lock.h testing/include/linux/smp_lock.h
--- work/include/linux/smp_lock.h	Sun May 14 20:20:41 2000
+++ testing/include/linux/smp_lock.h	Mon May 15 00:00:29 2000
@@ -5,6 +5,11 @@
 
 #ifndef CONFIG_SMP
 
+/* We can hold the big kernel lock while we sleep.  The scheduler
+ * drops the lock while we sleep and re-acquires it when we are
+ * rescheduled.  
+ */
+
 #define lock_kernel()				do { } while(0)
 #define unlock_kernel()				do { } while(0)
 #define release_kernel_lock(task, cpu)		do { } while(0)


-- 
In theory, practice and theory are the same, but in practice they 
are different -- Larry McVoy
--
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.eu.org/Linux-MM/

  reply	other threads:[~2000-05-14 22:02 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-05-06  1:30 Juan J. Quintela
2000-05-06  1:34 ` Helding the Kernel lock while doing IO??? (take 2) Juan J. Quintela
2000-05-06 11:48 ` Helding the Kernel lock while doing IO??? Stephen C. Tweedie
2000-05-14 22:02   ` Juan J. Quintela [this message]
2000-05-06 13:16 ` Andrea Arcangeli

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=yttbt2823ju.fsf_-_@vexeta.dc.fi.udc.es \
    --to=quintela@fi.udc.es \
    --cc=linux-kernel@vger.rutgers.edu \
    --cc=linux-mm@kvack.org \
    --cc=sct@redhat.com \
    --cc=torvalds@transmeta.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