linux-um archives
 help / color / mirror / Atom feed
From: blaisorblade_spam@yahoo.it
To: akpm@osdl.org
Cc: linux-kernel@vger.kernel.org, jdike@addtoit.com,
	user-mode-linux-devel@lists.sourceforge.net,
	blaisorblade_spam@yahoo.it
Subject: [uml-devel] [patch 3/8] uml: Commentary addition to recent SYSEMU fix.
Date: Thu, 13 Jan 2005 06:13:29 +0100	[thread overview]
Message-ID: <20050113051330.097A36324D@zion> (raw)


From: Paolo 'Blaisorblade' Giarrusso <blaisorblade_spam@yahoo.it>

Add some comments about the "uml-sysemu-fixes" patch of 2.6.10-mm1 (merged in 2.6.11-rc1).

Signed-off-by: Paolo 'Blaisorblade' Giarrusso <blaisorblade_spam@yahoo.it>
---

 linux-2.6.11-paolo/arch/um/kernel/tt/tracer.c |   14 ++++++++++++++
 1 files changed, 14 insertions(+)

diff -puN arch/um/kernel/tt/tracer.c~uml-comment-fix-sysemu-tt arch/um/kernel/tt/tracer.c
--- linux-2.6.11/arch/um/kernel/tt/tracer.c~uml-comment-fix-sysemu-tt	2005-01-13 01:56:56.494835760 +0100
+++ linux-2.6.11-paolo/arch/um/kernel/tt/tracer.c	2005-01-13 01:56:56.498835152 +0100
@@ -313,6 +313,15 @@ int tracer(int (*init_proc)(void *), voi
 				sig = 0;
 				op = do_proc_op(task, proc_id);
 				switch(op){
+				/*
+				 * This is called when entering user mode; after
+				 * this, we start intercepting syscalls.
+				 *
+				 * In fact, a process is started in kernel mode,
+				 * so with is_tracing() == 0 (and that is reset
+				 * when executing syscalls, since UML kernel has
+				 * the right to do syscalls);
+				 */
 				case OP_TRACE_ON:
 					arch_leave_kernel(task, pid);
 					tracing = 1;
@@ -347,6 +356,11 @@ int tracer(int (*init_proc)(void *), voi
 					continue;
 				}
 				tracing = 0;
+				/* local_using_sysemu has been already set
+				 * below, since if we are here, is_tracing() on
+				 * the traced task was 1, i.e. the process had
+				 * already run through one iteration of the
+				 * loop which executed a OP_TRACE_ON request.*/
 				do_syscall(task, pid, local_using_sysemu);
 				sig = SIGUSR2;
 				break;
_


-------------------------------------------------------
The SF.Net email is sponsored by: Beat the post-holiday blues
Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek.
It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt
_______________________________________________
User-mode-linux-devel mailing list
User-mode-linux-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel

                 reply	other threads:[~2005-01-13 15:31 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20050113051330.097A36324D@zion \
    --to=blaisorblade_spam@yahoo.it \
    --cc=akpm@osdl.org \
    --cc=jdike@addtoit.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=user-mode-linux-devel@lists.sourceforge.net \
    /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