From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1164081AbdDXBr6 (ORCPT ); Sun, 23 Apr 2017 21:47:58 -0400 Received: from host.buserror.net ([209.198.135.123]:41206 "EHLO host.buserror.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1164026AbdDXBrw (ORCPT ); Sun, 23 Apr 2017 21:47:52 -0400 Message-ID: <1492998461.25397.16.camel@buserror.net> From: Scott Wood To: roy.pledge@nxp.com, linuxppc-dev@lists.ozlabs.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, robin.murphy@arm.com Cc: madalin.bucur@nxp.com Date: Sun, 23 Apr 2017 20:47:41 -0500 In-Reply-To: <1492634930-10765-8-git-send-email-roy.pledge@nxp.com> References: <1492634930-10765-1-git-send-email-roy.pledge@nxp.com> <1492634930-10765-8-git-send-email-roy.pledge@nxp.com> Organization: NXP Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.22.6-1ubuntu1 Mime-Version: 1.0 Content-Transfer-Encoding: 8bit X-SA-Exim-Connect-IP: 50.171.225.118 X-SA-Exim-Rcpt-To: roy.pledge@nxp.com, linuxppc-dev@lists.ozlabs.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, robin.murphy@arm.com, madalin.bucur@nxp.com X-SA-Exim-Mail-From: oss@buserror.net X-Spam-Report: * -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP * -15 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] * 0.0 URIBL_BLOCKED ADMINISTRATOR NOTICE: The query to URIBL was blocked. * See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block * for more information. * [URIs: nxp.com] * -1.5 GREYLIST_ISWHITE The incoming server has been whitelisted for this * recipient and sender Subject: Re: [PATCH v2 07/11] soc/fsl/qbman: Rework ioremap() calls for ARM/PPC X-SA-Exim-Version: 4.2.1 (built Mon, 26 Dec 2011 16:57:07 +0000) X-SA-Exim-Scanned: Yes (on host.buserror.net) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 2017-04-19 at 16:48 -0400, Roy Pledge wrote: > Rework ioremap() for PPC and ARM. The PPC devices require a > non-coherent mapping while ARM will work with a non-cachable/write > combine mapping. > > Signed-off-by: Roy Pledge > --- >  drivers/soc/fsl/qbman/bman_portal.c | 16 +++++++++++++--- >  drivers/soc/fsl/qbman/qman_portal.c | 16 +++++++++++++--- >  2 files changed, 26 insertions(+), 6 deletions(-) > > diff --git a/drivers/soc/fsl/qbman/bman_portal.c > b/drivers/soc/fsl/qbman/bman_portal.c > index 8354d4d..a661f30 100644 > --- a/drivers/soc/fsl/qbman/bman_portal.c > +++ b/drivers/soc/fsl/qbman/bman_portal.c > @@ -125,7 +125,18 @@ static int bman_portal_probe(struct platform_device > *pdev) >   } >   pcfg->irq = irq; >   > - va = ioremap_prot(addr_phys[0]->start, resource_size(addr_phys[0]), > 0); > +#ifdef CONFIG_PPC > + /* PPC requires a cacheable/non-coherent mapping of the portal */ > + va = ioremap_prot(addr_phys[0]->start, resource_size(addr_phys[0]), > +   (pgprot_val(PAGE_KERNEL) & ~_PAGE_COHERENT)); > +#else > + /* > +  * For ARM we can use write combine mapping.  A cacheable/non > shareable > +  * mapping will perform better but equires additional platform > +  * support which is not currently available > +  */ s/equires/requires/ Would be nice to describe the platform support that is required. -Scott