All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Hildenbrand <david@redhat.com>
To: Oscar Salvador <osalvador@suse.de>,
	Andrew Morton <akpm@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org,
	Dave Hansen <dave.hansen@intel.com>
Subject: Re: [PATCH] arch/x86: Do not explicitly clear Reserved flag in free_pagetable
Date: Mon, 27 May 2024 09:46:05 +0200	[thread overview]
Message-ID: <ed45ef68-cb73-4e16-8a16-2e2008fe873a@redhat.com> (raw)
In-Reply-To: <20240527044523.29207-1-osalvador@suse.de>

Am 27.05.24 um 06:45 schrieb Oscar Salvador:
> In free_pagetable() we use the non-atomic version for clearing the
> PageReserved bit from the page.
> free_pagetable() will either call free_reserved_page() or
> put_page_bootmem(), which will eventually end up calling
> free_serverd_page(), and in there we already clear the PageReserved flag.
> 
> Signed-off-by: Oscar Salvador <osalvador@suse.de>
> ---
> This has been like this since commit ae9aae9eda2d ("memory-hotplug: common APIs to
> support page tables hot-remove"), so I might be missing something obvious, but
> I cannot explain why we would need that __ClearPageReserved upfront, when
> free_reserved_pages() already does that for us.

Especially, we only call it on the first page (in case we'd have order>0).

Acked-by: David Hildenbrand <david@redhat.com>

-- 
Thanks,

David / dhildenb



      reply	other threads:[~2024-05-27  7:46 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-27  4:45 [PATCH] arch/x86: Do not explicitly clear Reserved flag in free_pagetable Oscar Salvador
2024-05-27  7:46 ` David Hildenbrand [this message]

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=ed45ef68-cb73-4e16-8a16-2e2008fe873a@redhat.com \
    --to=david@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=dave.hansen@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=osalvador@suse.de \
    /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.