From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christoph Hellwig Date: Mon, 09 Dec 2019 20:43:45 +0000 Subject: Re: [PATCH 0/6] Allow setting caching mode in arch_add_memory() for P2PDMA Message-Id: <20191209204345.GA29265@lst.de> List-Id: References: <20191209191346.5197-1-logang@deltatee.com> In-Reply-To: <20191209191346.5197-1-logang@deltatee.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Logan Gunthorpe Cc: linux-s390@vger.kernel.org, linux-ia64@vger.kernel.org, Andrew Morton , Will Deacon , linux-sh@vger.kernel.org, Peter Zijlstra , Catalin Marinas , Dave Hansen , linux-kernel@vger.kernel.org, platform-driver-x86@vger.kernel.org, linux-mm@kvack.org, Ingo Molnar , Thomas Gleixner , Andy Lutomirski , Benjamin Herrenschmidt , Borislav Petkov , Dan Williams , linuxppc-dev@lists.ozlabs.org, Christoph Hellwig , linux-arm-kernel@lists.infradead.org On Mon, Dec 09, 2019 at 12:13:40PM -0700, Logan Gunthorpe wrote: > This changes is pretty routine for most of the arches: x86_64, s390, arm64 > and powerpc simply need to thread the pgprot through to where the page tables > are setup. x86_32 unfortunately sets up the page tables at boot so > must use _set_memory_prot() to change their caching mode. ia64 and sh > don't appear to have an easy way to change the page tables so, for now > at least, we just return -EINVAL on such mappings and thus they will > not support P2PDMA memory until the work for this is done. ia64 and sh don't support ZONE_DEVICE mappings anyway as far as I know. This generally looks fine to me.