> > I need to alloc as much memory as possible, *but not more*. I do not
> > want to OOM-kill anything. How do I do this? Tried GFP_KERNEL, will
> > oom-kill. GFP_USER will OOM-kill, too.
>
> Try GFP_ATOMIC; GFP_KERNEL sets the __GFP_WAIT flag and you don't
> want that.
No, I want other apps to be moved to swap, dirty data written out
etc. I really can't live with GFP_ATOMIC.
> But, if you're really asking how to know how large the current working set is,
> so that you don't grab more than your applications are going to need and
> eventually OOM, you'll need to set GFP_HAVE_CRYSTAL_BALL ;-)
I want to push just as much that I do not cause OOM. I'll stop
applications real soon after that.
Pavel
-- Causalities in World Trade Center: 6453 dead inside the building, cryptography in U.S.A. and free speech in Czech Republic. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/