[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180427124828.GW15462@8bytes.org>
Date: Fri, 27 Apr 2018 14:48:29 +0200
From: "joro@...tes.org" <joro@...tes.org>
To: Chintan Pandya <cpandya@...eaurora.org>
Cc: "Kani, Toshi" <toshi.kani@....com>,
"Hocko, Michal" <MHocko@...e.com>, "hpa@...or.com" <hpa@...or.com>,
"wxf.wang@...ilicon.com" <wxf.wang@...ilicon.com>,
"catalin.marinas@....com" <catalin.marinas@....com>,
"x86@...nel.org" <x86@...nel.org>,
"will.deacon@....com" <will.deacon@....com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"stable@...r.kernel.org" <stable@...r.kernel.org>,
"linux-mm@...ck.org" <linux-mm@...ck.org>,
"mingo@...hat.com" <mingo@...hat.com>,
"willy@...radead.org" <willy@...radead.org>,
"guohanjun@...wei.com" <guohanjun@...wei.com>,
"tglx@...utronix.de" <tglx@...utronix.de>,
"bp@...e.de" <bp@...e.de>,
"akpm@...ux-foundation.org" <akpm@...ux-foundation.org>,
"linux-arm-kernel@...ts.infradead.org"
<linux-arm-kernel@...ts.infradead.org>
Subject: Re: [PATCH v2 2/2] x86/mm: implement free pmd/pte page interfaces
On Fri, Apr 27, 2018 at 05:22:28PM +0530, Chintan Pandya wrote:
> I'm bit confused here. Are you pointing to race within ioremap/vmalloc
> framework while updating the page table or race during tlb ops. Since
> later is arch dependent, I would not comment. But if the race being
> discussed here while altering page tables, I'm not on the same page.
The race condition is between hardware and software. It is not
sufficient to just remove the software references to the page that is
about to be freed (by clearing the PMD/PUD), also the hardware
references in the page-walk cache need to be removed with a TLB flush.
Otherwise the hardware can use the freed (and possibly reused) page to
establish new TLB entries.
Joerg
Powered by blists - more mailing lists