From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751116AbdE2TNS (ORCPT ); Mon, 29 May 2017 15:13:18 -0400 Received: from ale.deltatee.com ([207.54.116.67]:52531 "EHLO ale.deltatee.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751009AbdE2TNQ (ORCPT ); Mon, 29 May 2017 15:13:16 -0400 From: Logan Gunthorpe To: linux-kernel@vger.kernel.org, linux-s390@vger.kernel.org Cc: Logan Gunthorpe , Martin Schwidefsky , Heiko Carstens , Sebastian Ott , Al Viro Date: Mon, 29 May 2017 13:13:08 -0600 Message-Id: <20170529191308.8499-1-logang@deltatee.com> X-Mailer: git-send-email 2.11.0 X-SA-Exim-Connect-IP: 172.16.1.31 X-SA-Exim-Rcpt-To: linux-kernel@vger.kernel.org, linux-s390@vger.kernel.org, logang@deltatee.com, schwidefsky@de.ibm.com, heiko.carstens@de.ibm.com, sebott@linux.vnet.ibm.com, viro@ZenIV.linux.org.uk X-SA-Exim-Mail-From: gunthorp@deltatee.com Subject: [PATCH v2] s390: provide default ioremap and iounmap declaration X-SA-Exim-Version: 4.2.1 (built Mon, 26 Dec 2011 16:24:06 +0000) X-SA-Exim-Scanned: Yes (on ale.deltatee.com) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Move the CONFIG_PCI device so that ioremap and iounmap are always available. This looks safe as there's nothing PCI specific in the implementation of these functions. I have designs to use these functions in scatterlist.c where they'd likely never be called without CONFIG_PCI set, but this is needed to compile such changes. Signed-off-by: Logan Gunthorpe Cc: Martin Schwidefsky Cc: Heiko Carstens cc: Sebastian Ott Cc: Al Viro --- v2 of this patch is changed to simply move the CONFIG_PCI #ifdef to expose only a single set of functions as suggested by Heiko Carstens. arch/s390/include/asm/io.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/s390/include/asm/io.h b/arch/s390/include/asm/io.h index 437e9af96688..904e4b3af95d 100644 --- a/arch/s390/include/asm/io.h +++ b/arch/s390/include/asm/io.h @@ -25,8 +25,6 @@ void unxlate_dev_mem_ptr(phys_addr_t phys, void *addr); #define IO_SPACE_LIMIT 0 -#ifdef CONFIG_PCI - #define ioremap_nocache(addr, size) ioremap(addr, size) #define ioremap_wc ioremap_nocache #define ioremap_wt ioremap_nocache @@ -49,6 +47,8 @@ static inline void ioport_unmap(void __iomem *p) { } +#ifdef CONFIG_PCI + /* * s390 needs a private implementation of pci_iomap since ioremap with its * offset parameter isn't sufficient. That's because BAR spaces are not -- 2.11.0