Displaying 3 results from an estimated 3 matches for "page_poisoning_get".
2018 Feb 07
2
[PATCH v27 3/4] mm/page_poison: expose page_poisoning_enabled to kernel modules
On Wed, Feb 07, 2018 at 02:54:30PM +0800, Wei Wang wrote:
> In some usages, e.g. virtio-balloon, a kernel module needs to know if
> page poisoning is in use. This patch exposes the page_poisoning_enabled
> function to kernel modules.
>
> Signed-off-by: Wei Wang <wei.w.wang at intel.com>
> Cc: Andrew Morton <akpm at linux-foundation.org>
> Cc: Michal Hocko
2018 Feb 07
2
[PATCH v27 3/4] mm/page_poison: expose page_poisoning_enabled to kernel modules
On Wed, Feb 07, 2018 at 02:54:30PM +0800, Wei Wang wrote:
> In some usages, e.g. virtio-balloon, a kernel module needs to know if
> page poisoning is in use. This patch exposes the page_poisoning_enabled
> function to kernel modules.
>
> Signed-off-by: Wei Wang <wei.w.wang at intel.com>
> Cc: Andrew Morton <akpm at linux-foundation.org>
> Cc: Michal Hocko
2018 Feb 08
0
[PATCH v27 3/4] mm/page_poison: expose page_poisoning_enabled to kernel modules
...porting that seems to be more of an accident
> as it's only used without page_poisoning.c - it might be
> better to have page_poisoning_enabled get u8 * and set it.
>
PAGE_POISON is a macro defined in the header, why would callers using it
be a concern?
Do you suggest to have:
bool page_poisoning_get(u8 *val)
{
if (page_poisoning_enabled()) {
*val = PAGE_POISON;
return true;
}
return false;
}
EXPORT_SYMBOL_GPL(page_poisoning_get);
Best,
Wei