All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com>
To: Pavel Tatashin <pasha.tatashin@oracle.com>
Cc: steven.sistare@oracle.com, daniel.m.jordan@oracle.com,
	m.mizuma@jp.fujitsu.com, akpm@linux-foundation.org,
	mhocko@suse.com, catalin.marinas@arm.com,
	takahiro.akashi@linaro.org, gi-oh.kim@profitbricks.com,
	heiko.carstens@de.ibm.com, baiyaowei@cmss.chinamobile.com,
	richard.weiyang@gmail.com, paul.burton@mips.com,
	miles.chen@mediatek.com, vbabka@suse.cz, mgorman@suse.de,
	hannes@cmpxchg.org, linux-kernel@vger.kernel.org,
	linux-mm@kvack.org
Subject: Re: [PATCH v3 1/1] mm: initialize pages on demand during boot
Date: Wed, 14 Feb 2018 14:08:43 +0900	[thread overview]
Message-ID: <20180214050843.GA2811@jagdpanzerIV> (raw)
In-Reply-To: <20180209192216.20509-2-pasha.tatashin@oracle.com>

On (02/09/18 14:22), Pavel Tatashin wrote:
[..]
> +/*
> + * If this zone has deferred pages, try to grow it by initializing enough
> + * deferred pages to satisfy the allocation specified by order, rounded up to
> + * the nearest PAGES_PER_SECTION boundary.  So we're adding memory in increments
> + * of SECTION_SIZE bytes by initializing struct pages in increments of
> + * PAGES_PER_SECTION * sizeof(struct page) bytes.
> + *
> + * Return true when zone was grown by at least number of pages specified by
> + * order. Otherwise return false.
> + *
> + * Note: We use noinline because this function is needed only during boot, and
> + * it is called from a __ref function _deferred_grow_zone. This way we are
> + * making sure that it is not inlined into permanent text section.
> + */
> +static noinline bool __init
> +deferred_grow_zone(struct zone *zone, unsigned int order)
> +{
> +	int zid = zone_idx(zone);
> +	int nid = zone->node;

		^^^^^^^^^

Should be CONFIG_NUMA dependent

struct zone {
...
#ifdef CONFIG_NUMA
	int node;
#endif
...

	-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>

WARNING: multiple messages have this Message-ID (diff)
From: Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com>
To: Pavel Tatashin <pasha.tatashin@oracle.com>
Cc: steven.sistare@oracle.com, daniel.m.jordan@oracle.com,
	m.mizuma@jp.fujitsu.com, akpm@linux-foundation.org,
	mhocko@suse.com, catalin.marinas@arm.com,
	takahiro.akashi@linaro.org, gi-oh.kim@profitbricks.com,
	heiko.carstens@de.ibm.com, baiyaowei@cmss.chinamobile.com,
	richard.weiyang@gmail.com, paul.burton@mips.com,
	miles.chen@mediatek.com, vbabka@suse.cz, mgorman@suse.de,
	hannes@cmpxchg.org, linux-kernel@vger.kernel.org,
	linux-mm@kvack.org
Subject: Re: [PATCH v3 1/1] mm: initialize pages on demand during boot
Date: Wed, 14 Feb 2018 14:08:43 +0900	[thread overview]
Message-ID: <20180214050843.GA2811@jagdpanzerIV> (raw)
In-Reply-To: <20180209192216.20509-2-pasha.tatashin@oracle.com>

On (02/09/18 14:22), Pavel Tatashin wrote:
[..]
> +/*
> + * If this zone has deferred pages, try to grow it by initializing enough
> + * deferred pages to satisfy the allocation specified by order, rounded up to
> + * the nearest PAGES_PER_SECTION boundary.  So we're adding memory in increments
> + * of SECTION_SIZE bytes by initializing struct pages in increments of
> + * PAGES_PER_SECTION * sizeof(struct page) bytes.
> + *
> + * Return true when zone was grown by at least number of pages specified by
> + * order. Otherwise return false.
> + *
> + * Note: We use noinline because this function is needed only during boot, and
> + * it is called from a __ref function _deferred_grow_zone. This way we are
> + * making sure that it is not inlined into permanent text section.
> + */
> +static noinline bool __init
> +deferred_grow_zone(struct zone *zone, unsigned int order)
> +{
> +	int zid = zone_idx(zone);
> +	int nid = zone->node;

		^^^^^^^^^

Should be CONFIG_NUMA dependent

struct zone {
...
#ifdef CONFIG_NUMA
	int node;
#endif
...

	-ss

  parent reply	other threads:[~2018-02-14  5:08 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-09 19:22 [PATCH v3 0/1] initialize pages on demand during boot Pavel Tatashin
2018-02-09 19:22 ` Pavel Tatashin
2018-02-09 19:22 ` [PATCH v3 1/1] mm: " Pavel Tatashin
2018-02-09 19:22   ` Pavel Tatashin
2018-02-09 20:36   ` Andrew Morton
2018-02-09 20:36     ` Andrew Morton
2018-02-14  5:08   ` Sergey Senozhatsky [this message]
2018-02-14  5:08     ` Sergey Senozhatsky
2018-02-14 14:16     ` Pavel Tatashin
2018-02-14 14:16       ` Pavel Tatashin
  -- strict thread matches above, loose matches on Subject: below --
2018-02-09 17:27 [PATCH v3 0/1] " Pavel Tatashin
2018-02-09 17:27 ` [PATCH v3 1/1] mm: " Pavel Tatashin
2018-02-09 17:27   ` Pavel Tatashin

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=20180214050843.GA2811@jagdpanzerIV \
    --to=sergey.senozhatsky.work@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=baiyaowei@cmss.chinamobile.com \
    --cc=catalin.marinas@arm.com \
    --cc=daniel.m.jordan@oracle.com \
    --cc=gi-oh.kim@profitbricks.com \
    --cc=hannes@cmpxchg.org \
    --cc=heiko.carstens@de.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=m.mizuma@jp.fujitsu.com \
    --cc=mgorman@suse.de \
    --cc=mhocko@suse.com \
    --cc=miles.chen@mediatek.com \
    --cc=pasha.tatashin@oracle.com \
    --cc=paul.burton@mips.com \
    --cc=richard.weiyang@gmail.com \
    --cc=steven.sistare@oracle.com \
    --cc=takahiro.akashi@linaro.org \
    --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 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.