From: David Hildenbrand <david@redhat.com>
To: Vlastimil Babka <vbabka@suse.cz>,
Andrew Morton <akpm@linux-foundation.org>
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
Alexander Potapenko <glider@google.com>,
Kees Cook <keescook@chromium.org>,
Michal Hocko <mhocko@kernel.org>,
Mateusz Nosek <mateusznosek0@gmail.com>,
Laura Abbott <labbott@kernel.org>
Subject: Re: [PATCH v2 5/5] mm, page_poison: remove CONFIG_PAGE_POISONING_ZERO
Date: Wed, 11 Nov 2020 16:45:53 +0100 [thread overview]
Message-ID: <74868d3b-1435-08be-a01e-00bf69099064@redhat.com> (raw)
In-Reply-To: <20201103152237.9853-6-vbabka@suse.cz>
On 03.11.20 16:22, Vlastimil Babka wrote:
> CONFIG_PAGE_POISONING_ZERO uses the zero pattern instead of 0xAA. It was
> introduced by commit 1414c7f4f7d7 ("mm/page_poisoning.c: allow for zero
> poisoning"), noting that using zeroes retains the benefit of sanitizing content
> of freed pages, with the benefit of not having to zero them again on alloc, and
> the downside of making some forms of corruption (stray writes of NULLs) harder
> to detect than with the 0xAA pattern. Together with
> CONFIG_PAGE_POISONING_NO_SANITY it made possible to sanitize the contents on
> free without checking it back on alloc.
>
> These days we have the init_on_free() option to achieve sanitization with
> zeroes and to save clearing on alloc (and without checking on alloc). Arguably
> if someone does choose to check the poison for corruption on alloc, the savings
> of not clearing the page are secondary, and it makes sense to always use the
> 0xAA poison pattern. Thus, remove the CONFIG_PAGE_POISONING_ZERO option for
> being redundant.
I agree, this simplifies things ... and I don't see a need to complicate
things to speed up corner-case debug mechanisms. Thanks!
Acked-by: David Hildenbrand <david@redhat.com>
--
Thanks,
David / dhildenb
prev parent reply other threads:[~2020-11-11 15:46 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-03 15:22 [PATCH v2 0/5] cleanup page poisoning Vlastimil Babka
2020-11-03 15:22 ` [PATCH v2 1/5] mm, page_alloc: do not rely on the order of page_poison and init_on_alloc/free parameters Vlastimil Babka
2020-11-03 15:22 ` [PATCH v2 2/5] mm, page_poison: use static key more efficiently Vlastimil Babka
2020-11-11 15:38 ` David Hildenbrand
2020-11-12 14:37 ` Vlastimil Babka
2020-11-12 16:06 ` David Hildenbrand
2020-11-03 15:22 ` [PATCH v2 3/5] kernel/power: allow hibernation with page_poison sanity checking Vlastimil Babka
2020-11-05 18:36 ` Rafael J. Wysocki
2020-11-11 15:42 ` David Hildenbrand
2020-11-12 14:39 ` Vlastimil Babka
2020-11-12 15:52 ` Rafael J. Wysocki
2020-11-12 16:07 ` David Hildenbrand
2020-11-03 15:22 ` [PATCH v2 4/5] mm, page_poison: remove CONFIG_PAGE_POISONING_NO_SANITY Vlastimil Babka
2020-11-11 15:43 ` David Hildenbrand
2020-11-03 15:22 ` [PATCH v2 5/5] mm, page_poison: remove CONFIG_PAGE_POISONING_ZERO Vlastimil Babka
2020-11-11 15:45 ` 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=74868d3b-1435-08be-a01e-00bf69099064@redhat.com \
--to=david@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=glider@google.com \
--cc=keescook@chromium.org \
--cc=labbott@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mateusznosek0@gmail.com \
--cc=mhocko@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox