- To: KOSAKI Motohiro <kosaki.motohiro@xxxxxxxxx>
- Subject: Re: [RFC PATCH] do_try_to_free_pages() might enter infinite loop
- From: Ying Han <yinghan@xxxxxxxxxx>
- Date: Tue, 24 Apr 2012 10:22:29 -0700
- Cc: Rik van Riel <riel@xxxxxxxxxx>, Minchan Kim <minchan@xxxxxxxxxx>, KOSAKI Motohiro <kosaki.motohiro@xxxxxxxxxxxxxx>, Michal Hocko <mhocko@xxxxxxx>, Johannes Weiner <hannes@xxxxxxxxxxx>, Mel Gorman <mel@xxxxxxxxx>, KAMEZAWA Hiroyuki <kamezawa.hiroyu@xxxxxxxxxxxxxx>, Minchan Kim <minchan.kim@xxxxxxxxx>, Hugh Dickins <hughd@xxxxxxxxxx>, Nick Piggin <npiggin@xxxxxxxxx>, Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>, linux-mm@xxxxxxxxx
- Delivered-to: linux-mm-outgoing@xxxxxxxxx
- Delivered-to: int-list-linux-mm@xxxxxxxxx
- Delivered-to: linux-mm@xxxxxxxxx
- In-reply-to: <4F96D8C1.2060705@gmail.com>
On Tue, Apr 24, 2012 at 9:45 AM, KOSAKI Motohiro
<kosaki.motohiro@xxxxxxxxx> wrote:
> (4/24/12 12:38 PM), Rik van Riel wrote:
>>
>> On 04/24/2012 12:36 PM, Ying Han wrote:
>>
>>> However, what if B frees a pages everytime before pages_scanned
>>> reaches the point, then we won't set zone->all_unreclaimable at all.
>>> If so, we reaches a livelock here...
>>
>>
>> If B keeps freeing pages, surely A will get a successful
>> allocation and there will not be a livelock?
>
>
> And, I hope we distinguish true livelock and pseudo livelock at first.
> Nick's patch definitely makes kernel slowdown when OOM situation. It is
> intentional. We thought slowdown is better than false positive OOM even
> though the slowdown is extream slow and similar to livelock.
I get the false positive OOM part from Minchan's reply, but I am
wondering if the current code covers some of the problem?
__alloc_pages_may_oom() {
>-------/*
>------- * Go through the zonelist yet one more time, keep very high watermark
>------- * here, this is only to catch a parallel oom killing, we must fail if
>------- * we're still under heavy pressure.
>------- */
>-------page = get_page_from_freelist(gfp_mask|__GFP_HARDWALL, nodemask,
>------->-------order, zonelist, high_zoneidx,
>------->-------ALLOC_WMARK_HIGH|ALLOC_CPUSET,
>------->-------preferred_zone, migratetype);
}
>
> Ying, Which problem do you want to discuss? a) current kernrel has true
> live lock b) current oom detection is too slow and livelock like and it
> is not acceptable to you.
The first one, however I don't have test program to reproduce it yet.
Everything by far is based on the watchdog_timeout core dump and
that's why I prefer to understand the code first before jumping to a
fix :)
--Ying
--
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/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@xxxxxxxxx"> email@xxxxxxxxx </a>
[Site Home]
[Linux ARM Kernel]
[Linux ARM]
[Linux Omap]
[Fedora ARM]
[IETF Annouce]
[Security]
[Bugtraq]
[Linux]
[Linux OMAP]
[Linux MIPS]
[ECOS]
[Tools]
[DDR & Rambus]
[Asterisk Internet PBX]
[Linux API]
[Monitors]