Re: [PATCH] mm/page_alloc: Wait for oom_lock before retrying.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On (12/12/16 12:49), Petr Mladek wrote:
[..]
> > OK, I see. This is not a new problem though and people are trying to
> > solve it in the printk proper. CCed some people, I do not have links
> > to those threads handy. And if this is really the problem here then we
> > definitely shouldn't put hacks into the page allocator path to handle
> > it because there might be other sources of the printk flood might be
> > arbitrary.
> 
> Yup, this is exactly the type of the problem that we want to solve
> by the async printk.

yes, I think async printk will help here.

> > > The introduction of uncontrolled
> > > 
> > >   warn_alloc(gfp_mask, "page allocation stalls for %ums, order:%u", ...);
> 
> I am just curious that there would be so many messages.
> If I get it correctly, this warning is printed
> once every 10 second. Or am I wrong?
> 
> Well, you might want to consider using
> 
> 		stall_timeout *= 2;
> 
> instead of adding the constant 10 * HZ.
> 
> Of course, a better would be some global throttling of
> this message.

yeah. rate limiting is still a good thing to have.

somewhat unrelated, but somehow related. just some thoughts.

with async printk, in some cases, I suspect (and I haven't thought
of it long enought), messages rate limiting can have an even bigger,
to some extent, necessity than with the current printk. the thing
is that in current scheme CPU that does printk-s can *sometimes*
go to console_unlock() and spins there printing the messages that
it appended to the logbuf. which naturally throttles that CPU and
it can't execte more printk-s for awhile. with async printk that
CPU is detached from console_unlock() printing loop, so the CPU is
free to append new messages to the logbuf as fast as it wants to.
it should not cause any lockups or something, but we can lost some
messages.

	-ss

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>



[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]