Re: Kernel-Crash when working with ubt0

From: Konstantin Belousov <kostikbel_at_gmail.com>
Date: Tue, 27 Aug 2019 16:38:11 +0300
On Tue, Aug 27, 2019 at 06:03:46AM -0700, Maksim Yevmenkin wrote:
> > > Hmm... interesting....
> > >
> > > I only took a brief look at it. I suppose I can ensure user space address is wired and then copyout() can be called with mutex held
> >
> > >No, you cannot do this, at least without making the kernel to panic.
> > User might unmap the wired mapping at any time still.
> 
> Kostik,
> 
> i was thinking along the lines of vslock/vsunlock and copyout_nofault.
> basically similar to the sysctl code. do you think this would not
> work?

This would probably work, but at least causes fragmentation of userspace
vm_map entries.  If it is supposed to be used on high-frequency data path,
then it would cause significant blow up of the VM structures used to keep
user data map.
Received on Tue Aug 27 2019 - 11:38:22 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:41:21 UTC