[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Could kernel copy memory between processes directly?
> >What you probably really want is a shared memory segment with mmap or
> Definitively no, everyone is saying that. If you haven't heard about
> synchronous messaging I encourage you to read:
> (section "Synchronous message passing")
Urgh. Too much to read. I have to try to catch up with work first.
> It's a bit similar to Mach messaging. The whole idea could be described
> like procedure call into another process.
"Procedure call into another process"? Sounds like Solaris doors. If you
want to implement something like that doors would be a very good thing.
> For shared memory processes must be trusted while for SRR the client
> (Sender) cannot break the server (Receiver), Important factor, isn't it :-)
Sure. doors solves that.
> I've grepped the sources a bit and looks like I'd need a mixture of copyin
> and copyout procedures. Too bad, hardware dependent... I should have known.
copyin and copyout only work on the currently running process.
procfs_domem does uvm_io that extracts a bunch of vm mappings
(_not_ mmu mappings) and maps them into kernel space, then it copies stuff
from kernel space into the process, faulting in as necessary (and since
there is no copying of mmu entries, the faulting will happen at least once).