From: Cedric A. <ad...@in...> - 2000-03-03 16:46:05
|
Jeff Dike writes: > [...] > I have a nice list of little nitty-gritty things I'm going to write up, and it didn't occur to me to write up something about how the whole thing is organized... > > The tracing thread oversees the whole operation, but actual system calls happen in the process that invokes them. That should have been clear in my system call write-up. It wasn't, so could you tell me why it wasn't? I'll see if I can make it more clear. Actually, it wasn't clear for me, because I didn't imagine that it could be done that way :-) A traditional kernel makes a context switch when a system call (or a fault) occurs, so I assumed that the tracing thread was the "kernel context" in which kernel code was executed. It did not occur to me that the tracing thread could pass the responsability back to the user-mode-linux processes, and run mmap-ed kernel code there... Now that I'm thinking of it, I guess the main reason for it might be the need to mmap(...) correctly the process memory. But this can make a port to NT more difficult: it would be necessary in a Linux process, to keep the NT thread/process data structures intact, along with the NT DLLs (for instance kernel32.dll, required for any NT system call). I'll investigate this. Anyway, thank you for the new overview ; things are getting more and more clear :-) -- Cedric |