From: Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com>
To: Joonsoo Kim <iamjoonsoo.kim@lge.com>
Cc: Sergey Senozhatsky <sergey.senozhatsky@gmail.com>,
Andrew Morton <akpm@linux-foundation.org>,
Vlastimil Babka <vbabka@suse.cz>,
linux-mm@kvack.org, linux-kernel@vger.kernel.org,
Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com>
Subject: Re: [RFC][PATCH v2 3/3] mm/page_owner: track page free call chain
Date: Mon, 11 Jul 2016 16:24:17 +0900 [thread overview]
Message-ID: <20160711072417.GA524@swordfish> (raw)
In-Reply-To: <20160711062115.GC14107@js1304-P5Q-DELUXE>
On (07/11/16 15:21), Joonsoo Kim wrote:
[..]
> > +void __page_owner_free_pages(struct page *page, unsigned int order)
> > +{
> > + int i;
> > + depot_stack_handle_t handle = save_stack(0);
> > +
> > + for (i = 0; i < (1 << order); i++) {
> > + struct page_ext *page_ext = lookup_page_ext(page + i);
> > +
> > + if (unlikely(!page_ext))
> > + continue;
> > +
> > + page_ext->handles[PAGE_OWNER_HANDLE_FREE] = handle;
> > + __set_bit(PAGE_EXT_OWNER_FREE, &page_ext->flags);
> > + __clear_bit(PAGE_EXT_OWNER_ALLOC, &page_ext->flags);
> > + }
> > +}
>
> I can't find any clear function to PAGE_EXT_OWNER_FREE. Isn't it
> intended? If so, why?
the PAGE_EXT_OWNER_FREE bit is not heavily used now. the
only place is this test in __dump_page_owner()
if (!test_bit(PAGE_EXT_OWNER_ALLOC, &page_ext->flags) &&
!test_bit(PAGE_EXT_OWNER_FREE, &page_ext->flags)) {
pr_alert("page_owner info is not active (free page?)\n");
return;
}
other than that it's for symmetry/future use.
[..]
> > @@ -1073,6 +1073,9 @@ static void pagetypeinfo_showmixedcount_print(struct seq_file *m,
> > if (!test_bit(PAGE_EXT_OWNER_ALLOC, &page_ext->flags))
> > continue;
> >
> > + if (!test_bit(PAGE_EXT_OWNER_FREE, &page_ext->flags))
> > + continue;
> > +
>
> I don't think this line is correct. Above PAGE_EXT_OWNER_ALLOC
> check is to find allocated page.
you are right. that PAGE_EXT_OWNER_FREE test is wrong, indeed.
thanks for spotting.
-ss
--
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>
next prev parent reply other threads:[~2016-07-11 7:26 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-08 12:11 [RFC][PATCH v2 0/3] mm/page:_owner: track page free call chain Sergey Senozhatsky
2016-07-08 12:11 ` [RFC][PATCH v2 1/3] mm/page_owner: rename page_owner functions Sergey Senozhatsky
2016-07-08 12:11 ` [RFC][PATCH v2 2/3] mm/page_owner: rename PAGE_EXT_OWNER flag Sergey Senozhatsky
2016-07-08 12:11 ` [RFC][PATCH v2 3/3] mm/page_owner: track page free call chain Sergey Senozhatsky
2016-07-11 6:21 ` Joonsoo Kim
2016-07-11 7:24 ` Sergey Senozhatsky [this message]
2016-07-11 14:27 ` [PATCH " Sergey Senozhatsky
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=20160711072417.GA524@swordfish \
--to=sergey.senozhatsky.work@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=iamjoonsoo.kim@lge.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=sergey.senozhatsky@gmail.com \
--cc=vbabka@suse.cz \
/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 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).