Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp2605444imm; Fri, 20 Jul 2018 01:24:38 -0700 (PDT) X-Google-Smtp-Source: AAOMgpc4tNlv6hpAF1fL0SNYC3EJldrbKKK53Rerp4dsJgSyO2riJEK5zeLwb9mLP5rBsgBDnsh0 X-Received: by 2002:a63:8848:: with SMTP id l69-v6mr1098289pgd.377.1532075077947; Fri, 20 Jul 2018 01:24:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532075077; cv=none; d=google.com; s=arc-20160816; b=hBZrRhoEx2pYVBhioWS1rxdbc9+c9KW/1F1ELrbkl9B3LoOqp5mCBR2TtJmn40rNKm 2arYg2fLt6FCxsINKmXDfSJ9w9QL1A7MTjlXaUQE+4Gx/Rx9tlFT2UWwLF6PCTABPINK G4wJzVQFMhym7pSDKyktHiguMblk1yXe4FBaF7rUS9mQjzKC9GpOJdGJkfAHy97nOqrf YUxPKD15uLCnNJtmWOXpxyZ59Q3a4f7B9kpyT3oiF/Ba+AMhGzWIcHB9nx8qlQEzLLmH UvwkjfT5wOVjkffa2gwhI/yDoYMfufE1MCypDY9955F12MLOs7DCCc42ikAWMPKo/lZM 6Seg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :arc-authentication-results; bh=k0BGYXLvqM5ZNx3G2DD9xUtav1JNElz4D6K0U/Rwm6U=; b=n87Qn91fE7AXTxQa4kYloDSjdUNg80irLkj07G68bYsgAksem3KsPxAIyzekyecQMx ex7yTWoVVTdc4jHUxKKOqDmjqBj+w9HdVWlTNPSReljS3wkwrI891ps7rTtX9Wpn1HBe +nCFV6rfJ1bf5Rtb91H9jxqSD3Sn8zhvLhtcWxCtjinnudnHgh1twvHEEm1WwYD+XTB5 5eFdGOX1Pomkc4Eb+xFfqxFD9ERrCYgagCT1wlb6ttgpt+wP4dL0n61xTIzGWRkUjcrw Z/zw60neKyWkumU0oBJD8A+5BbMl8GhkvQjEY4GFxa8XHzuXDzIeqHJrD/hdaz8CiW6m Z4Jg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t9-v6si1151458plq.324.2018.07.20.01.24.23; Fri, 20 Jul 2018 01:24:37 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728302AbeGTJKt (ORCPT + 99 others); Fri, 20 Jul 2018 05:10:49 -0400 Received: from mail.bootlin.com ([62.4.15.54]:38283 "EHLO mail.bootlin.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728236AbeGTJKt (ORCPT ); Fri, 20 Jul 2018 05:10:49 -0400 Received: by mail.bootlin.com (Postfix, from userid 110) id 831A8207AD; Fri, 20 Jul 2018 10:23:39 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mail.bootlin.com X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,SHORTCIRCUIT shortcircuit=ham autolearn=disabled version=3.4.0 Received: from bbrezillon (AAubervilliers-681-1-78-122.w90-88.abo.wanadoo.fr [90.88.20.122]) by mail.bootlin.com (Postfix) with ESMTPSA id 33EF420618; Fri, 20 Jul 2018 10:23:39 +0200 (CEST) Date: Fri, 20 Jul 2018 10:23:39 +0200 From: Boris Brezillon To: Arnd Bergmann Cc: "David S. Miller" , linux-ia64@vger.kernel.org, linux-alpha@vger.kernel.org, sparclinux@vger.kernel.org, linux-kernel@vger.kernel.org, Miquel Raynal , "linux-mtd@lists.infradead.org" Subject: Re: [PATCH 2/2] sparc64: add reads{b,w,l}/writes{b,w,l} Message-ID: <20180720102339.22c9aa57@bbrezillon> In-Reply-To: <20180711120824.3882108-2-arnd@arndb.de> References: <20180711120824.3882108-1-arnd@arndb.de> <20180711120824.3882108-2-arnd@arndb.de> X-Mailer: Claws Mail 3.15.0-dirty (GTK+ 2.24.31; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org +Miquel who's in charge of the NAND tree for this release On Wed, 11 Jul 2018 14:08:06 +0200 Arnd Bergmann wrote: > Some drivers need these for compile-testing. On most architectures > they come from asm-generic/io.h, but not on sparc64, which has its > own definitions. > > Since we already have ioread*_rep()/iowrite*_rep() that have the > same behavior on sparc64 (i.e. all PCI I/O space is memory mapped), > we can rename the existing helpers and add macros to define them > to the same implementation. > > Signed-off-by: Arnd Bergmann I tried to compile a sparc64 kernel with COMPILE_TEST=y plus the orion and s3c2410 NAND drivers enabled and it compiles fine (it does without this patch). So it seems to fix the compilation error reported by kbuild robots. Tested-by: Boris Brezillon (only compile-tested) Dave gave his A-b, so, if everyone is okay with that, I'd like this patch to go trough the NAND tree. Thanks, Boris > --- > arch/sparc/include/asm/io_64.h | 19 +++++++++++++------ > 1 file changed, 13 insertions(+), 6 deletions(-) > > diff --git a/arch/sparc/include/asm/io_64.h b/arch/sparc/include/asm/io_64.h > index 9a1e9cbc7e6d..b162c23ae8c2 100644 > --- a/arch/sparc/include/asm/io_64.h > +++ b/arch/sparc/include/asm/io_64.h > @@ -243,35 +243,42 @@ void insb(unsigned long, void *, unsigned long); > void insw(unsigned long, void *, unsigned long); > void insl(unsigned long, void *, unsigned long); > > -static inline void ioread8_rep(void __iomem *port, void *buf, unsigned long count) > +static inline void readsb(void __iomem *port, void *buf, unsigned long count) > { > insb((unsigned long __force)port, buf, count); > } > -static inline void ioread16_rep(void __iomem *port, void *buf, unsigned long count) > +static inline void readsw(void __iomem *port, void *buf, unsigned long count) > { > insw((unsigned long __force)port, buf, count); > } > > -static inline void ioread32_rep(void __iomem *port, void *buf, unsigned long count) > +static inline void readsl(void __iomem *port, void *buf, unsigned long count) > { > insl((unsigned long __force)port, buf, count); > } > > -static inline void iowrite8_rep(void __iomem *port, const void *buf, unsigned long count) > +static inline void writesb(void __iomem *port, const void *buf, unsigned long count) > { > outsb((unsigned long __force)port, buf, count); > } > > -static inline void iowrite16_rep(void __iomem *port, const void *buf, unsigned long count) > +static inline void writesw(void __iomem *port, const void *buf, unsigned long count) > { > outsw((unsigned long __force)port, buf, count); > } > > -static inline void iowrite32_rep(void __iomem *port, const void *buf, unsigned long count) > +static inline void writesl(void __iomem *port, const void *buf, unsigned long count) > { > outsl((unsigned long __force)port, buf, count); > } > > +#define ioread8_rep(p,d,l) readsb(p,d,l) > +#define ioread16_rep(p,d,l) readsw(p,d,l) > +#define ioread32_rep(p,d,l) readsl(p,d,l) > +#define iowrite8_rep(p,d,l) writesb(p,d,l) > +#define iowrite16_rep(p,d,l) writesw(p,d,l) > +#define iowrite32_rep(p,d,l) writesl(p,d,l) > + > /* Valid I/O Space regions are anywhere, because each PCI bus supported > * can live in an arbitrary area of the physical address range. > */