From: Minchan Kim <minchan@kernel.org>
To: Marek Szyprowski <m.szyprowski@samsung.com>
Cc: Rabin Vincent <rabin@rab.in>,
linux-mm@kvack.org, LKML <linux-kernel@vger.kernel.org>
Subject: Re: CMA and zone watermarks
Date: Tue, 9 Oct 2012 13:43:17 +0900 [thread overview]
Message-ID: <20121009044317.GG13817@bbox> (raw)
In-Reply-To: <50739615.9080205@samsung.com>
On Tue, Oct 09, 2012 at 05:12:21AM +0200, Marek Szyprowski wrote:
> Hello,
>
> On 10/9/2012 5:10 AM, Minchan Kim wrote:
>
> >On Mon, Oct 08, 2012 at 05:41:14PM +0200, Rabin Vincent wrote:
> >>It appears that when CMA is enabled, the zone watermarks are not properly
> >>respected, leading to for example GFP_NOWAIT allocations getting access to the
> >>high pools.
> >>
> >>I ran the following test code which simply allocates pages with GFP_NOWAIT
> >>until it fails, and then tries GFP_ATOMIC. Without CMA, the GFP_ATOMIC
> >>allocation succeeds, with CMA, it fails too.
> >
> >Good spot. By wrong zone_watermark_check, it can consume reserved memory pool.
>
> That was the main reason for the Bartek's research.
Okay. It shoud have written down for more good description at that time. :)
>
> >>Logs attached (includes my patch which prints the migration type in the failure
> >>message http://marc.info/?l=linux-mm&m=134971041701306&w=2), taken on 3.6
> >>kernel.
> >>
> >
> >Fortunately, recently, Bart sent a patch about that.
> >http://marc.info/?l=linux-mm&m=134763299016693&w=2
> >
> >Could you test above patches in your kernel?
> >You have to apply [2/4], [3/4], [4/4] and don't need [1/4].
>
> AFAIR without patch [1/4], free cma page counter will go below zero
> and weird thing will happen, so better apply the complete patchset.
I can't understand your point. [1/4] is just fix for correcting trace
No?
http://marc.info/?l=linux-mm&m=134763301216713&w=2
>
> Best regards
> --
> Marek Szyprowski
> Samsung Poland R&D Center
>
> --
> To unsubscribe, send a message with 'unsubscribe linux-mm' in
> the body to majordomo@kvack.org. For more info on Linux MM,
> see: http://www.linux-mm.org/ .
> Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
--
Kind regards,
Minchan Kim
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
WARNING: multiple messages have this Message-ID (diff)
From: Minchan Kim <minchan@kernel.org>
To: Marek Szyprowski <m.szyprowski@samsung.com>
Cc: Rabin Vincent <rabin@rab.in>,
linux-mm@kvack.org, LKML <linux-kernel@vger.kernel.org>
Subject: Re: CMA and zone watermarks
Date: Tue, 9 Oct 2012 13:43:17 +0900 [thread overview]
Message-ID: <20121009044317.GG13817@bbox> (raw)
In-Reply-To: <50739615.9080205@samsung.com>
On Tue, Oct 09, 2012 at 05:12:21AM +0200, Marek Szyprowski wrote:
> Hello,
>
> On 10/9/2012 5:10 AM, Minchan Kim wrote:
>
> >On Mon, Oct 08, 2012 at 05:41:14PM +0200, Rabin Vincent wrote:
> >>It appears that when CMA is enabled, the zone watermarks are not properly
> >>respected, leading to for example GFP_NOWAIT allocations getting access to the
> >>high pools.
> >>
> >>I ran the following test code which simply allocates pages with GFP_NOWAIT
> >>until it fails, and then tries GFP_ATOMIC. Without CMA, the GFP_ATOMIC
> >>allocation succeeds, with CMA, it fails too.
> >
> >Good spot. By wrong zone_watermark_check, it can consume reserved memory pool.
>
> That was the main reason for the Bartek's research.
Okay. It shoud have written down for more good description at that time. :)
>
> >>Logs attached (includes my patch which prints the migration type in the failure
> >>message http://marc.info/?l=linux-mm&m=134971041701306&w=2), taken on 3.6
> >>kernel.
> >>
> >
> >Fortunately, recently, Bart sent a patch about that.
> >http://marc.info/?l=linux-mm&m=134763299016693&w=2
> >
> >Could you test above patches in your kernel?
> >You have to apply [2/4], [3/4], [4/4] and don't need [1/4].
>
> AFAIR without patch [1/4], free cma page counter will go below zero
> and weird thing will happen, so better apply the complete patchset.
I can't understand your point. [1/4] is just fix for correcting trace
No?
http://marc.info/?l=linux-mm&m=134763301216713&w=2
>
> Best regards
> --
> Marek Szyprowski
> Samsung Poland R&D Center
>
> --
> To unsubscribe, send a message with 'unsubscribe linux-mm' in
> the body to majordomo@kvack.org. For more info on Linux MM,
> see: http://www.linux-mm.org/ .
> Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
--
Kind regards,
Minchan Kim
next prev parent reply other threads:[~2012-10-09 4:39 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-10-08 15:41 CMA and zone watermarks Rabin Vincent
2012-10-09 0:37 ` Marek Szyprowski
2012-10-09 0:37 ` Marek Szyprowski
2012-10-09 15:25 ` Rabin Vincent
2012-10-09 15:25 ` Rabin Vincent
2012-10-09 3:10 ` Minchan Kim
2012-10-09 3:10 ` Minchan Kim
2012-10-09 3:12 ` Marek Szyprowski
2012-10-09 3:12 ` Marek Szyprowski
2012-10-09 4:43 ` Minchan Kim [this message]
2012-10-09 4:43 ` Minchan Kim
2012-10-09 4:53 ` Marek Szyprowski
2012-10-09 4:53 ` Marek Szyprowski
2012-10-09 5:07 ` Minchan Kim
2012-10-09 5:07 ` Minchan Kim
2012-10-09 5:16 ` Marek Szyprowski
2012-10-09 5:16 ` Marek Szyprowski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20121009044317.GG13817@bbox \
--to=minchan@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=m.szyprowski@samsung.com \
--cc=rabin@rab.in \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.