user malloc from kernel

Pawel Jakub Dawidek nick at garage.freebsd.pl
Mon Sep 29 12:11:25 PDT 2003


On Mon, Sep 29, 2003 at 06:56:13PM +0300, Peter Pentchev wrote:
+> I mean, won't the application's memory manager attempt to allocate the
+> next chunk of memory right over the region that you have stolen with
+> this brk(2) invocation?  Thus, when the application tries to write into
+> its newly-allocated memory, it will overwrite the data that the kernel
+> has placed there, and any attempt to access the kernel's data later will
+> fail in wonderfully unpredictable ways :)

I'm not sure if newly allocated memory will overwrite memory allocated
in kernel, but for sure process is able to write to this memory.

Sometime ago I proposed model which will allow to remove all copyin(9)
calls and many copyout(9), but I'm not so skilled in VM to implement it.

-- 
Pawel Jakub Dawidek                       pawel at dawidek.net
UNIX Systems Programmer/Administrator     http://garage.freebsd.pl
Am I Evil? Yes, I Am!                     http://cerber.sourceforge.net
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 305 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-hackers/attachments/20030929/03e1ea74/attachment.bin


More information about the freebsd-hackers mailing list