lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <YgUQmYy2Tl5oYkqz@casper.infradead.org>
Date:   Thu, 10 Feb 2022 13:18:17 +0000
From:   Matthew Wilcox <willy@...radead.org>
To:     Huangzhaoyang <huangzhaoyang@...il.com>
Cc:     Andrew Morton <akpm@...ux-foundation.org>,
        Zhaoyang Huang <zhaoyang.huang@...soc.com>, linux-mm@...ck.org,
        linux-kernel@...r.kernel.org
Subject: Re: [RFC PATCH] mm: record context on page->mapping

On Thu, Feb 10, 2022 at 05:01:55PM +0800, Huangzhaoyang wrote:
> From: Zhaoyang Huang <zhaoyang.huang@...soc.com>
> 
> Since page->mapping is vacant in the pages which used by kernel(drivers etc)
> Have it record current context to help tracking the page's owner in system
> memory dump.
> 
> Signed-off-by: Zhaoyang Huang <zhaoyang.huang@...soc.com>
> ---
>  mm/page_alloc.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/mm/page_alloc.c b/mm/page_alloc.c
> index c595274..2757d10 100644
> --- a/mm/page_alloc.c
> +++ b/mm/page_alloc.c
> @@ -2430,6 +2430,8 @@ static void prep_new_page(struct page *page, unsigned int order, gfp_t gfp_flags
>  		set_page_pfmemalloc(page);
>  	else
>  		clear_page_pfmemalloc(page);
> +
> +	page->mapping = (struct address_space *)current;
>  }

You didn't actually try this patch, did you?  See page_expected_state().
Or, I don't know, just boot it.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ