All of lore.kernel.org
 help / color / mirror / Atom feed
From: Matthew Wilcox <willy@infradead.org>
To: Oscar Salvador <osalvador@suse.de>
Cc: Dave Hansen <dave.hansen@intel.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	David Hildenbrand <david@redhat.com>,
	Dave Hansen <dave.hansen@linux.intel.com>,
	Andy Lutomirski <luto@kernel.org>,
	Peter Zijlstra <peterz@infradead.org>,
	Thomas Gleixner <tglx@linutronix.de>,
	Ingo Molnar <mingo@redhat.com>, Borislav Petkov <bp@alien8.de>,
	x86@kernel.org, "H . Peter Anvin" <hpa@zytor.com>,
	Michal Hocko <mhocko@kernel.org>, Zi Yan <ziy@nvidia.com>,
	linux-mm@kvack.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v6 3/4] x86/vmemmap: Handle unpopulated sub-pmd ranges
Date: Tue, 30 Mar 2021 03:29:50 +0100	[thread overview]
Message-ID: <20210330022950.GL351017@casper.infradead.org> (raw)
In-Reply-To: <YEqQMm6+oQiQmwB0@localhost.localdomain>

[-- Attachment #1: Type: text/plain, Size: 1302 bytes --]

On Thu, Mar 11, 2021 at 10:48:34PM +0100, Oscar Salvador wrote:
> On Thu, Mar 11, 2021 at 01:29:39PM -0800, Dave Hansen wrote:
> > On 3/9/21 1:40 PM, Oscar Salvador wrote:
> > > +static void __meminit vmemmap_use_new_sub_pmd(unsigned long start, unsigned long end)
> > > +{
> > > +	/*
> > > +	 * Could be our memmap page is filled with PAGE_UNUSED already from a
> > > +	 * previous remove. Make sure to reset it.
> > > +	 */
> > > +	vmemmap_use_sub_pmd(start);
> > > +
> > > +	/*
> > > +	 * Mark with PAGE_UNUSED the unused parts of the new memmap range
> > > +	 */
> > > +	if (!IS_ALIGNED(start, PMD_SIZE))
> > > +		memset((void *)start, PAGE_UNUSED,
> > > +		        start - ALIGN_DOWN(start, PMD_SIZE));
> > > +	if (!IS_ALIGNED(end, PMD_SIZE))
> > > +		memset((void *)end, PAGE_UNUSED,
> > > +		        ALIGN(end, PMD_SIZE) - end);
> > > +}
> > > +#endif
> > 
> > This is apparently under both CONFIG_SPARSEMEM_VMEMMAP and
> > CONFIG_MEMORY_HOTPLUG #ifdefs.  It errors out at compile-time with this
> > config: https://sr71.net/~dave/intel/config-mmotm-20210311
> 
> It seems that mmotm still has v5.
> v6 (this one) fixed that up. I basically moved the code out of
> MEMORY_HOTPLUG #ifdefs.
> 
> I could not reproduce your error on v6.

I can reproduce this with next-20210329.

.config attached.

[-- Attachment #2: config-for-osal.xz --]
[-- Type: application/x-xz, Size: 24696 bytes --]

  reply	other threads:[~2021-03-30  2:34 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-09 21:40 [PATCH v6 0/4] Cleanup and fixups for vmemmap handling Oscar Salvador
2021-03-09 21:40 ` [PATCH v6 1/4] x86/vmemmap: Drop handling of 4K unaligned vmemmap range Oscar Salvador
2021-03-09 21:40 ` [PATCH v6 2/4] x86/vmemmap: Drop handling of 1GB vmemmap ranges Oscar Salvador
2021-03-09 21:40 ` [PATCH v6 3/4] x86/vmemmap: Handle unpopulated sub-pmd ranges Oscar Salvador
2021-03-10  6:07   ` Naresh Kamboju
2021-03-10  6:07     ` Naresh Kamboju
2021-03-10  7:24     ` Oscar Salvador
2021-03-11 21:29   ` Dave Hansen
2021-03-11 21:48     ` Oscar Salvador
2021-03-30  2:29       ` Matthew Wilcox [this message]
2021-04-02 17:58         ` Oscar Salvador
2021-03-09 21:40 ` [PATCH v6 4/4] x86/vmemmap: Optimize for consecutive sections in partial populated PMDs Oscar Salvador

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=20210330022950.GL351017@casper.infradead.org \
    --to=willy@infradead.org \
    --cc=akpm@linux-foundation.org \
    --cc=bp@alien8.de \
    --cc=dave.hansen@intel.com \
    --cc=dave.hansen@linux.intel.com \
    --cc=david@redhat.com \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=luto@kernel.org \
    --cc=mhocko@kernel.org \
    --cc=mingo@redhat.com \
    --cc=osalvador@suse.de \
    --cc=peterz@infradead.org \
    --cc=tglx@linutronix.de \
    --cc=x86@kernel.org \
    --cc=ziy@nvidia.com \
    --subject='Re: [PATCH v6 3/4] x86/vmemmap: Handle unpopulated sub-pmd ranges' \
    /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 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.