LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Sasha Levin <sasha.levin@oracle.com>
To: Joonsoo Kim <iamjoonsoo.kim@lge.com>
Cc: linux-kernel@vger.kernel.org, m.szyprowski@samsung.com,
akpm@linux-foundation.org, lauraa@codeaurora.org
Subject: Re: [PATCH v2 3/3] mm: cma: release trigger
Date: Tue, 27 Jan 2015 15:13:52 -0500 [thread overview]
Message-ID: <54C7F180.1030505@oracle.com> (raw)
In-Reply-To: <54C7D801.3070502@oracle.com>
On 01/27/2015 01:25 PM, Sasha Levin wrote:
> On 01/27/2015 03:10 AM, Joonsoo Kim wrote:
>>> >> + if (mem->n <= count) {
>>>> >> > + cma_release(cma, mem->p, mem->n);
>>>> >> > + count -= mem->n;
>>>> >> > + kfree(mem);
>>>> >> > + } else {
>>>> >> > + cma_release(cma, mem->p, count);
>>>> >> > + mem->p += count;
>>>> >> > + mem->n -= count;
>>>> >> > + count = 0;
>>>> >> > + cma_add_to_cma_mem_list(mem);
>>>> >> > + }
>>>> >> > + }
>> > If order_per_bit is not 0 and count used in cma_release() is
>> > different with the count used in cma_alloc(), problem could
>> > occur since bitmap management code can't handle that situation.
>> >
>> > Could we just disable this case in this testing module?
> How should it behave then? Just free a max of 'count' pages and
> stop beforehand if we're going to go over it?
Actually, Can I just check for order_per_bit == 0 and execute it
then? I don't want to avoid testing these paths.
Thanks,
Sasha
next prev parent reply other threads:[~2015-01-27 20:14 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-26 14:26 [PATCH v2 0/3] mm: cma: debugfs access to CMA Sasha Levin
2015-01-26 14:26 ` [PATCH v2 1/3] mm: cma: debugfs interface Sasha Levin
2015-01-26 14:26 ` [PATCH v2 2/3] mm: cma: allocation trigger Sasha Levin
2015-01-27 8:06 ` Joonsoo Kim
2015-01-27 15:08 ` Sasha Levin
2015-01-28 1:34 ` Joonsoo Kim
2015-01-26 14:26 ` [PATCH v2 3/3] mm: cma: release trigger Sasha Levin
2015-01-27 8:10 ` Joonsoo Kim
2015-01-27 18:25 ` Sasha Levin
2015-01-27 20:13 ` Sasha Levin [this message]
2015-01-28 1:35 ` Joonsoo Kim
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=54C7F180.1030505@oracle.com \
--to=sasha.levin@oracle.com \
--cc=akpm@linux-foundation.org \
--cc=iamjoonsoo.kim@lge.com \
--cc=lauraa@codeaurora.org \
--cc=linux-kernel@vger.kernel.org \
--cc=m.szyprowski@samsung.com \
--subject='Re: [PATCH v2 3/3] mm: cma: release trigger' \
/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
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).