All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jeff Dike <jdike@addtoit.com>
To: Alex LIU <alex.liu@st.com>
Cc: user-mode-linux-devel@lists.sourceforge.net
Subject: Re: [uml-devel] Segmentation fault with kernel thread in UML-2.6.7 TT mode
Date: Sun, 17 Jul 2005 10:09:28 -0400	[thread overview]
Message-ID: <20050717140928.GA6519@ccure.user-mode-linux.org> (raw)
In-Reply-To: <000901c58aa4$86288800$9eb3c68a@SHZ.ST.COM>

On Sun, Jul 17, 2005 at 03:52:46PM +0800, Alex LIU wrote:
> In fact I want to port Bproc to UML. Now Bproc is based on i386. And
> a part of the main work Bproc does is about the kernel thread...Bproc
> create a new kernel thread function with the name bproc_kernel_thread
> in i386 and let the Bproc kernel thread go to the user space rather
> than exit. 

What does it run when it enters userspace?  The only other thing I can
think of which does this is the kernel thread that turns into init,
which it does by calling exec.

> In UML,I found in finish_fork_handler, set_user_mode is called at
> last. I think it's purpose is to let the new forked process go to
> the user space like ret_from_fork in i386. 

If you look at its implementation, you'll see that it is very tt-mode 
specific, and thus can't do something as basic as re-entering
userspace in a generic way.

If you are entering userspace, you need for there to be something
there to enter.

				Jeff


-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
_______________________________________________
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-07-17 15:00 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-15  9:59 [uml-devel] Segmentation fault with kernel thread in UML-2.6.7 TT mode Alex LIU
2005-07-15 18:25 ` Blaisorblade
2005-07-17  7:52   ` Alex LIU
2005-07-17 14:09     ` Jeff Dike [this message]
2005-08-12 18:38     ` Blaisorblade

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=20050717140928.GA6519@ccure.user-mode-linux.org \
    --to=jdike@addtoit.com \
    --cc=alex.liu@st.com \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.