This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Re: double fault -> PAGE_KERNEL flagged memory
* Roland McGrath (roland@redhat.com) wrote:
> > Then this is analogous to the problem of calling printk from within an
> > inconveniently placed kprobe. What can we do to eliminate this
> > vulnerability? Can we somehow arrange to "fault in" all probe-related
> > kernel-space vmalloc areas into new process' address spaces, so we don't
> > encounter this unintentional and undesirable reentrancy?
>
> What's the reason for using vmalloc then? Why not use kmalloc that doesn't
> need page table changes?
>
kmalloc needs contiguous pages of memory. It can be problematic in a system
where the memory is fragmented and the requested allocation size is big.
Mathieu
OpenPGP public key: http://krystal.dyndns.org:8080/key/compudj.gpg
Key fingerprint: 8CD5 52C3 8E3C 4140 715F BA06 3F25 A8FE 3BAE 9A68