openrisc.lists.librecores.org archive mirror
 help / color / mirror / Atom feed
From: Baolin Wang <baolin.wang@linux.alibaba.com>
To: Matthew Wilcox <willy@infradead.org>
Cc: linux-arch@vger.kernel.org, 0day robot <lkp@intel.com>,
	linux-mm@kvack.org, LKML <linux-kernel@vger.kernel.org>,
	linux-csky@vger.kernel.org, lkp@lists.01.org,
	openrisc@lists.librecores.org,
	kernel test robot <oliver.sang@intel.com>,
	akpm@linux-foundation.org
Subject: Re: [mm] 9b12e49e9b: BUG:Bad_page_state_in_process
Date: Fri, 10 Jun 2022 11:58:54 +0800	[thread overview]
Message-ID: <6351ead6-b4b8-dc43-2c1d-c099094cadc9@linux.alibaba.com> (raw)
In-Reply-To: <YqHlKj5LbmtYGWUy@casper.infradead.org>



On 6/9/2022 8:18 PM, Matthew Wilcox wrote:
> On Thu, Jun 09, 2022 at 12:42:16PM +0800, Baolin Wang wrote:
>> diff --git a/arch/x86/mm/pgtable.c b/arch/x86/mm/pgtable.c
>> index 6cccf52e156a..cae74e972426 100644
>> --- a/arch/x86/mm/pgtable.c
>> +++ b/arch/x86/mm/pgtable.c
>> @@ -858,6 +858,7 @@ int pmd_free_pte_page(pmd_t *pmd, unsigned long addr)
>>          /* INVLPG to clear all paging-structure caches */
>>          flush_tlb_kernel_range(addr, addr + PAGE_SIZE-1);
>>
>> +       pgtable_clear_and_dec(virt_to_page(pte));
>>          free_page((unsigned long)pte);
>>
>>          return 1;
> 
> If you're going to call virt_to_page() here, you may as well cache the
> result and call __free_page(page) to avoid calling virt_to_page() twice.

Right, will do in next version. Thanks.

      reply	other threads:[~2022-06-10  3:58 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <d35f42f7b598f629437940f941826e2cc49a97f6.1654271618.git.baolin.wang@linux.alibaba.com>
2022-06-08 14:38 ` [mm] 9b12e49e9b: BUG:Bad_page_state_in_process kernel test robot
2022-06-08 15:07   ` Matthew Wilcox
2022-06-09  4:45     ` Baolin Wang
2022-06-09  4:42   ` Baolin Wang
2022-06-09 12:18     ` Matthew Wilcox
2022-06-10  3:58       ` Baolin Wang [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=6351ead6-b4b8-dc43-2c1d-c099094cadc9@linux.alibaba.com \
    --to=baolin.wang@linux.alibaba.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-csky@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=lkp@intel.com \
    --cc=lkp@lists.01.org \
    --cc=oliver.sang@intel.com \
    --cc=openrisc@lists.librecores.org \
    --cc=willy@infradead.org \
    /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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).